CVE-2012-1854 Sumo Logic CSE · Sumo

Detect CVE-2012-1854 - Microsoft VBA Insecure Library Loading (DLL Hijacking) in Sumo Logic CSE

Detects exploitation of CVE-2012-1854, a DLL hijacking vulnerability in Microsoft Visual Basic for Applications (VBA). Attackers can place a malicious DLL in a directory searched before the legitimate library path, causing Office applications loading VBA to execute attacker-controlled code. This vulnerability is listed in CISA's Known Exploited Vulnerabilities catalog.

MITRE ATT&CK

Tactic
Execution Persistence Privilege Escalation

Sumo Detection Query

Sumo Logic CSE (Sumo)
sql
_sourceCategory=windows/sysmon EventCode=7
| where ProcessImage matches /(?i)(WINWORD|EXCEL|POWERPNT|OUTLOOK|MSACCESS|MSPUB|VISIO)\.EXE$/
| where ImageLoaded matches /(?i)(vbe7|vba7|vbe6|vba6|msvbvm60|msvbvm50)\.dll$/
| where ImageLoaded matches /(?i)\\(Users|AppData|Temp|Downloads|Desktop)\\/
| fields _messageTime, Computer, User, ProcessImage, ImageLoaded, Hashes
| sort by _messageTime desc
high severity medium confidence

Sumo Logic query detecting suspicious VBA DLL loads by Office applications from user-accessible directories, indicative of CVE-2012-1854 DLL hijacking.

Data Sources

Sumo Logic Cloud SIEMWindows Sysmon

Required Tables

windows/sysmon

False Positives & Tuning

  • Software testing pipelines deploying Office libraries to custom paths
  • Roaming profile users whose AppData resolves to network shares
  • Third-party Office add-ins installing VBA runtime libraries in non-standard locations
  • Virtualized Office deployments with redirected DLL paths

Other platforms for CVE-2012-1854


Testing Methodology

Validate this detection against 3 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.

  1. Test 1VBA DLL Hijack - Place Malicious DLL in Temp Directory

    Expected signal: Sysmon Event ID 7 showing WINWORD.EXE loading vbe7.dll from %TEMP% path; DeviceImageLoadEvents in MDE showing FolderPath containing \Temp\

  2. Test 2VBA DLL Hijack - Place Malicious DLL in Downloads Directory

    Expected signal: Sysmon ImageLoad event with ImageLoaded path in \Downloads\; Windows Security log showing file creation event in Downloads directory followed by Office process DLL load

  3. Test 3VBA DLL Hijack - Simulate Document-Triggered DLL Load via PowerShell

    Expected signal: Sysmon Event ID 7 with POWERPNT.EXE as initiating process and vba7.dll loaded from TEMP\vba_hijack_test path; process creation event showing PowerShell as parent of POWERPNT

Unlock Pro Content

Get the full detection package for CVE-2012-1854 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections