Detection rules › Splunk

WMI subscription execution (Sysmon)

Group by
_time, host
Source
github.com/anvilogic-forge/armory

Adversaries may establish persistence and elevate privileges by executing malicious content triggered by a Windows Management Instrumentation (WMI) event subscription

MITRE ATT&CK coverage

References

Event coverage

ProviderEventTitle
SysmonEvent ID 1Process creation

Rule body yaml

id: '5975.18225'
title: WMI subscription execution
description: 'Adversaries may establish persistence and elevate privileges by executing
  malicious content triggered by a Windows Management Instrumentation (WMI) event
  subscription. -- Threat Actor Association: APT29, Metador, Mustang Panda (aka. Stately
  Taurus//Earth Preta/BRONZE PRESIDENT/TA416/RedDelta), TA551 - Software Association:
  BumbleBee, TargetCompany, TrailBlazer, Trickbot -- Atomics T1047 Test#7 Atomics
  T1047 Test#8 Atomics T1047 Test#9 -- While this use case can detect the above atomics,
  it is not mapped to its MITRE execution techniques due to adversaries utilizing
  this method of WMI for Privilege-Escalation and Persistence.'
logic_format: Splunk
logic: '`get_endpoint_data` `get_endpoint_data_sysmon` ("EventCode=1" OR "<EventID>1<")
  TERM(WmiPrvSE) | regex parent_process_name="(?i)(WmiPrvSE)" | table _time, host,
  user parent_*, process, process_*, signature_id | bin span=1s | stats values(*)
  as * by _time, host '
techniques:
- persistence:event triggered execution:windows management instrumentation event subscription
- execution:windows management instrumentation
- privilege-escalation:event triggered execution:windows management instrumentation
  event subscription
technique_id:
- T1546.003
- T1047
data_category:
- Windows Sysmon
references:
- https://pentestlab.blog/2020/01/21/persistence-wmi-event-subscription/

Stages and Predicates

Stage 1: search

`get_endpoint_data` `get_endpoint_data_sysmon` ("EventCode=1" OR "<EventID>1<") TERM(WmiPrvSE)

Stage 2: regex

| regex parent_process_name="(?i)(WmiPrvSE)"

Stage 3: table

| table _time, host, user parent_*, process, process_*, signature_id

Stage 4: bucket

| bin span=1s

Stage 5: stats

| stats values(*) as * by _time, host

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
parent_process_nameregex_match
  • "(?i)(WmiPrvSE)" corpus 2 (splunk 2)

Search terms

Bare-string tokens in the SPL search body. Splunk matches each token against _raw (the untyped raw event text) anywhere it appears, not against a specific field. These don't surface in the Indicators table because they aren't predicates on a known field.

StageTerm
1"EventCode=1"
1"<EventID>1<"
1TERM
1WmiPrvSE