Detection rules › Elastic
UAC Bypass via Hijacking WinMgmt MMC
Identifies attempts to bypass User Account Control by sideloading a rouge ATL.dll from unusual folder into MMC. Attackers may attempt to hijack DLL search order and stealthily execute code with elevated permissions.
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Privilege Escalation | |
| Stealth |
Rule body
[rule]
description = """
Identifies attempts to bypass User Account Control by sideloading a rouge ATL.dll from unusual folder into MMC.
Attackers may attempt to hijack DLL search order and stealthily execute code with elevated permissions.
"""
id = "0723b937-2ca6-4fda-9da6-3de0026f4802"
license = "Elastic License v2"
name = "UAC Bypass via Hijacking WinMgmt MMC"
os_list = ["windows"]
reference = ["https://github.com/azAgarampur/byeintegrity9-uac"]
version = "1.0.17"
query = '''
sequence by process.entity_id with maxspan=1m
[process where event.action == "start" and
process.name : "mmc.exe" and process.command_line : "*WmiMgmt.msc*"]
[library where
dll.path : "?:\\Windows\\System32\\wbem\\ATL.dll" and
not (dll.code_signature.subject_name : "Microsoft *" and dll.code_signature.trusted == true)]
'''
min_endpoint_version = "7.16.0"
[[actions]]
action = "kill_process"
field = "process.entity_id"
state = 1
[[actions]]
action = "kill_process"
field = "process.parent.entity_id"
state = 0
[[optional_actions]]
action = "rollback"
field = "process.entity_id"
state = 1
[[threat]]
framework = "MITRE ATT&CK"
[[threat.technique]]
id = "T1548"
name = "Abuse Elevation Control Mechanism"
reference = "https://attack.mitre.org/techniques/T1548/"
[[threat.technique.subtechnique]]
id = "T1548.002"
name = "Bypass User Account Control"
reference = "https://attack.mitre.org/techniques/T1548/002/"
[threat.tactic]
id = "TA0004"
name = "Privilege Escalation"
reference = "https://attack.mitre.org/tactics/TA0004/"
[[threat]]
framework = "MITRE ATT&CK"
[[threat.technique]]
id = "T1574"
name = "Hijack Execution Flow"
reference = "https://attack.mitre.org/techniques/T1574/"
[[threat.technique.subtechnique]]
id = "T1574.001"
name = "DLL"
reference = "https://attack.mitre.org/techniques/T1574/001/"
[threat.tactic]
id = "TA0005"
name = "Defense Evasion"
reference = "https://attack.mitre.org/tactics/TA0005/"
[internal]
min_endpoint_version = "7.16.0"
Stages and Predicates
Ordered sequence: each step below must occur in order within 1m, correlated by process.entity_id.
Stage 1: process
[process where event.action == "start" and
process.name : "mmc.exe" and process.command_line : "*WmiMgmt.msc*"]
Stage 2: library
[library where
dll.path : "?:\\Windows\\System32\\wbem\\ATL.dll" and
not (dll.code_signature.subject_name : "Microsoft *" and dll.code_signature.trusted == true)]
Exclusions
The rule actively suppresses these predicates.
| Field | Kind | Excluded values | Search |
|---|---|---|---|
dll.code_signature.subject_name | starts_with | Microsoft | excludes:dll.code_signature.subject_name field:"dll.code_signature.subject_name" value:"Microsoft " |
dll.code_signature.trusted | eq | true | excludes:dll.code_signature.trusted field:"dll.code_signature.trusted" value:"true" |
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
dll.path | wildcard |
| field:"ImageLoaded" kind:wildcard value:"?:\Windows\System32\wbem\ATL.dll" |
event.action | eq |
| field:"EventType" kind:eq value:"start" |
process.command_line | wildcard |
| field:"CommandLine" kind:wildcard value:"*WmiMgmt.msc*" |
process.name | wildcard |
| field:"process_name" kind:wildcard value:"mmc.exe" |