T1559.002 Elastic Security · Elastic

Detect Dynamic Data Exchange in Elastic Security

Adversaries may use Windows Dynamic Data Exchange (DDE) to execute arbitrary commands without relying on VBA macros. DDE is a legacy client-server IPC protocol supported in Microsoft Office applications that allows documents to request command execution from a server process. Attackers poison Word documents, Excel spreadsheets, Outlook emails, and CSV files with DDE fields (e.g., DDEAUTO cmd) that execute shell commands when the document is opened and field updates are accepted. DDE is also delivered via OLE-embedded Equation Editor objects (EQNEDT32.EXE) exploiting CVE-2017-11882. Threat actors including APT28, FIN7, MuddyWater, Cobalt Group, Gallmaker, APT37, Leviathan, and BITTER have leveraged DDE in targeted spearphishing campaigns to achieve initial code execution.

MITRE ATT&CK

Tactic
Execution
Technique
T1559 Inter-Process Communication
Sub-technique
T1559.002 Dynamic Data Exchange
Canonical reference
https://attack.mitre.org/techniques/T1559/002/

Elastic Detection Query

Elastic Security (Elastic)
eql
sequence by host.id with maxspan=30s
  [process where event.type == "start" and
   process.parent.name : ("winword.exe", "excel.exe", "outlook.exe", "onenote.exe", "powerpnt.exe", "msaccess.exe", "mspub.exe", "EQNEDT32.EXE") and
   process.name : ("cmd.exe", "powershell.exe", "pwsh.exe", "wscript.exe", "cscript.exe", "mshta.exe", "rundll32.exe", "regsvr32.exe", "certutil.exe", "bitsadmin.exe", "msiexec.exe", "wmic.exe", "schtasks.exe", "net.exe", "net1.exe", "curl.exe", "wget.exe", "forfiles.exe", "pcalua.exe")]
| where process.parent.name : ("winword.exe", "excel.exe", "outlook.exe", "onenote.exe", "powerpnt.exe", "msaccess.exe", "mspub.exe", "EQNEDT32.EXE")

also:
process where event.type == "start" and
  process.parent.name : ("winword.exe", "excel.exe", "outlook.exe", "onenote.exe", "powerpnt.exe", "msaccess.exe", "mspub.exe") and
  process.name : ("cmd.exe", "powershell.exe", "pwsh.exe", "wscript.exe", "cscript.exe", "mshta.exe", "rundll32.exe", "regsvr32.exe", "certutil.exe", "bitsadmin.exe", "msiexec.exe", "wmic.exe", "schtasks.exe", "net.exe", "net1.exe", "curl.exe", "wget.exe", "forfiles.exe", "pcalua.exe")
or
process where event.type == "start" and
  process.parent.name : "EQNEDT32.EXE"
high severity high confidence

Detects DDE-based command execution by identifying suspicious child processes spawned from Microsoft Office applications or EQNEDT32.EXE (Equation Editor, CVE-2017-11882). Covers DDEAUTO field abuse across Word, Excel, Outlook, and OLE-embedded equation objects.

Data Sources

Elastic Endpoint SecurityWinlogbeat with SysmonElastic Agent

Required Tables

logs-endpoint.events.process-*winlogbeat-*

False Positives & Tuning

  • Legitimate macro-free Office automation tools that spawn cmd.exe or PowerShell for administrative tasks in managed enterprise environments
  • IT helpdesk tools that open Office documents and launch scripts for document processing pipelines
  • EQNEDT32.EXE spawning child processes in environments still running legacy Office 2007/2010 with Equation Editor enabled for legitimate scientific document workflows
Download portable Sigma rule (.yml)

Other platforms for T1559.002


Testing Methodology

Validate this detection against 4 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 1CSV DDE Injection via Excel

    Expected signal: Sysmon Event ID 1: Process Create for excel.exe with the CSV path as argument. If the DDE prompt is accepted: Sysmon Event ID 1 for cmd.exe with ParentImage=excel.exe and CommandLine='/c whoami > %TEMP%\dde_csv_out.txt'. Sysmon Event ID 11: File Create for dde_csv_out.txt in %TEMP%. Security Event ID 4688 (if command line auditing enabled) for the cmd.exe spawn.

  2. Test 2Word DDEAUTO Field Execution via RTF

    Expected signal: Sysmon Event ID 1: Process Create for winword.exe with the RTF file as argument. If DDE executes: Sysmon Event ID 1 for cmd.exe with ParentImage=winword.exe, CommandLine='/c whoami > %TEMP%\dde_word_out.txt'. Sysmon Event ID 11: File Create for dde_word_out.txt. Office telemetry logs the DDEAUTO field activation attempt. Security Event ID 4688 for the spawned cmd.exe.

  3. Test 3DDE via Outlook Email with Embedded OLE Object

    Expected signal: Sysmon Event ID 1: Process Create for outlook.exe with the .msg file path as argument. Outlook COM instantiation visible in Sysmon Event ID 1 for the PowerShell parent spawning outlook.exe. If OLE DDE executes: Sysmon Event ID 1 for cmd.exe with ParentImage=outlook.exe. Security Event ID 4688 for the spawned process.

  4. Test 4Equation Editor (EQNEDT32.EXE) Presence and Execution Check

    Expected signal: If EQNEDT32.EXE is found and executed: Sysmon Event ID 1 for EQNEDT32.EXE with Image=<office_path>\EQNEDT32.EXE. Prefetch file created at C:\Windows\Prefetch\EQNEDT32.EXE-*.pf. Security Event ID 4688 for EQNEDT32.EXE execution. In a real exploitation scenario: Sysmon Event ID 1 for a child process (cmd.exe, powershell.exe) with ParentImage=EQNEDT32.EXE would additionally fire.

Unlock Pro Content

Get the full detection package for T1559.002 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections