Detection rules › Sigma
WMI spwaning PowerShell process - WMImplant
Detects scenarios where an attacker WMIimplant
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Execution |
Telemetry coverage
| Provider | Record / event type |
|---|---|
| Sysmon | Event ID 1: Process creation |
| Security-Auditing | Event ID 4688: A new process has been created. |
Rule body
title: WMI spwaning PowerShell process - WMImplant
description: Detects scenarios where an attacker WMIimplant
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0002-Execution/T1047-Windows%20Management%20Instrumentation
- https://github.com/FortyNorthSecurity/WMImplant/
- https://www.darkoperator.com/blog/2017/10/14/basics-of-tracking-wmi-activity
- Inspired from https://github.com/SigmaHQ/sigma/blob/7bca85e40618126643b9712b80bd663c21908e26/rules/windows/process_creation/win_wmi_spwns_powershell.yml
tags:
- attack.execution
- attack.t1047
author: Markus Neis/@Karneades, adapted by mdecrevoisier
status: experimental
logsource:
product: windows
category: process_creation
detection:
selection_basic:
EventID: 4688
Version: 2
ParentProcessName|endswith: \WmiPrvSE.exe
NewProcessName|endswith:
- \powershell.exe
- \pwsh.exe # PowerShell v6
- \powershell_ise.exe # Development GUI
selection_sysmon:
EventID: 1
ParentImage|endswith: \WmiPrvSE.exe
Image|endswith|endswith:
- \powershell.exe
- \pwsh.exe # PowerShell v6
- \powershell_ise.exe # Development GUI
filter:
CommandLine: "-" # Exclude empty command line
condition: (selection_basic or selection_sysmon) and not filter
falsepositives:
- Unknown
level: high
Stages and Predicates
Stage 0: condition
(selection_basic or selection_sysmon) and not filterStage 1: selection_basic
selection_basic:
EventID: 4688
Version: 2
ParentProcessName|endswith: \WmiPrvSE.exe
NewProcessName|endswith:
- \powershell.exe
- \pwsh.exe
- \powershell_ise.exe
Stage 2: selection_sysmon
selection_sysmon:
EventID: 1
ParentImage|endswith: \WmiPrvSE.exe
Image|endswith|endswith:
- \powershell.exe
- \pwsh.exe
- \powershell_ise.exe
Stage 3: not filter
filter:
CommandLine: "-"
Exclusions
The rule actively suppresses these predicates.
| Field | Kind | Excluded values | Search |
|---|---|---|---|
CommandLine | eq | - | excludes:CommandLine field:"CommandLine" value:"-" |
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
Image | ends_with |
| field:"Image" kind:ends_with |
NewProcessName | ends_with |
| field:"Image" kind:ends_with |
ParentImage | ends_with |
| field:"ParentImage" kind:ends_with value:"\WmiPrvSE.exe" |
ParentProcessName | ends_with |
| field:"parent_process_name" kind:ends_with value:"\WmiPrvSE.exe" |
Version | eq |
| field:"Version" kind:eq value:"2" |