Detection rules › Splunk

Windows Explorer.exe Spawning PowerShell or Cmd

Author
Michael Haag, AJ King, Splunk, Jesse Hunter, Splunk Community Contributor
Source
upstream

This detection identifies instances where Windows Explorer.exe spawns PowerShell or cmd.exe processes, particularly focusing on executions initiated by LNK files. This behavior is associated with the ZDI-CAN-25373 Windows shortcut zero-day vulnerability, where specially crafted LNK files are used to trigger malicious code execution through cmd.exe or powershell.exe. This technique has been actively exploited by multiple APT groups in targeted attacks through both HTTP and SMB delivery methods.

MITRE ATT&CK coverage

TacticTechniques
ExecutionT1059.001 Command and Scripting Interpreter: PowerShell, T1204.002 User Execution: Malicious File

Event coverage

ProviderEvent IDTitle
Sysmon1Process creation
Security-Auditing4688A new process has been created.

Stages and Predicates

Stage 1: tstats

tstats WHERE (Processes.original_file_name="Cmd.Exe" OR Processes.original_file_name="PowerShell.EXE" OR Processes.original_file_name="powershell_ise.EXE" OR Processes.original_file_name="pwsh.dll" OR Processes.process_name="cmd.exe" OR Processes.process_name="powershell.exe" OR Processes.process_name="powershell_ise.exe" OR Processes.process_name="pwsh.exe") Processes.parent_process_path="*\\explorer.exe" BY Processes.dest, Processes.process_current_directory, Processes.process_path, Processes.process, Processes.original_file_name, Processes.parent_process, Processes.parent_process_name, Processes.parent_process_path, Processes.parent_process_guid, Processes.parent_process_id, Processes.process_guid, Processes.process_id, Processes.user

Stage 2: search

search

Stage 3: search

search

Stage 4: search

search

Stage 5: search

search `macro`

Indicators

Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.

FieldKindValues
Processes.original_file_nameeq
  • Cmd.Exe corpus 32 (sigma 30, splunk 2)
  • PowerShell.EXE corpus 64 (sigma 60, splunk 4)
  • powershell_ise.EXE corpus 8 (sigma 4, splunk 4)
  • pwsh.dll corpus 72 (sigma 68, splunk 4)
Processes.parent_process_patheq
  • "*\\explorer.exe" corpus 2 (splunk 2)
Processes.process_nameeq
  • cmd.exe corpus 2 (splunk 2)
  • powershell.exe corpus 3 (splunk 3)
  • powershell_ise.exe corpus 3 (splunk 3)
  • pwsh.exe corpus 3 (splunk 3)