Suspicious WMI Event Subscription Created

Detects the creation of a WMI Event Subscription. Attackers can abuse this mechanism for persistence or to elevate to SYSTEM privileges.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2023/02/02"
 3integration = ["windows"]
 4maturity = "production"
 5min_stack_comments = "Related integrations field type changes in 8.8.0"
 6min_stack_version = "8.8.0"
 7updated_date = "2024/03/08"
 8
 9[rule]
10author = ["Elastic"]
11description = """
12Detects the creation of a WMI Event Subscription. Attackers can abuse this mechanism for persistence or to elevate to
13SYSTEM privileges.
14"""
15from = "now-9m"
16index = ["winlogbeat-*", "logs-windows.sysmon_operational-*"]
17language = "eql"
18license = "Elastic License v2"
19name = "Suspicious WMI Event Subscription Created"
20references = [
21  "https://www.blackhat.com/docs/us-15/materials/us-15-Graeber-Abusing-Windows-Management-Instrumentation-WMI-To-Build-A-Persistent%20Asynchronous-And-Fileless-Backdoor-wp.pdf",
22  "https://medium.com/threatpunter/detecting-removing-wmi-persistence-60ccbb7dff96",
23]
24risk_score = 47
25rule_id = "e72f87d0-a70e-4f8d-8443-a6407bc34643"
26severity = "medium"
27tags = ["Domain: Endpoint", "OS: Windows", "Use Case: Threat Detection", "Tactic: Persistence", "Data Source: Sysmon"]
28timestamp_override = "event.ingested"
29type = "eql"
30
31query = '''
32any where event.dataset == "windows.sysmon_operational" and event.code == "21" and
33    winlog.event_data.Operation : "Created" and winlog.event_data.Consumer : ("*subscription:CommandLineEventConsumer*", "*subscription:ActiveScriptEventConsumer*")
34'''
35
36[[rule.threat]]
37framework = "MITRE ATT&CK"
38
39[[rule.threat.technique]]
40id = "T1546"
41name = "Event Triggered Execution"
42reference = "https://attack.mitre.org/techniques/T1546/"
43
44    [[rule.threat.technique.subtechnique]]
45    id = "T1546.003"
46    name = "Windows Management Instrumentation Event Subscription"
47    reference = "https://attack.mitre.org/techniques/T1546/003/"
48
49[rule.threat.tactic]
50id = "TA0003"
51name = "Persistence"
52reference = "https://attack.mitre.org/tactics/TA0003/"

References

Related rules

to-top