Detection rules › Elastic
File Execution via Microsoft HTML Help
Identifies when the Microsoft HTML Help Executable (hh.exe) creates a portable executable (PE) file and the file is subsequently executed. Adversaries may conceal malicious code in a CHM file and deliver it to a victim for execution.
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Initial Access | |
| Stealth |
Rule body
[rule]
description = """
Identifies when the Microsoft HTML Help Executable (hh.exe) creates a portable executable (PE) file and the file is
subsequently executed. Adversaries may conceal malicious code in a CHM file and deliver it to a victim for execution.
"""
id = "9c3b13f6-bc26-4397-9721-4ba23ddd1014"
license = "Elastic License v2"
name = "File Execution via Microsoft HTML Help"
os_list = ["windows"]
reference = [
"https://www.ptsecurity.com/ww-en/analytics/pt-esc-threat-intelligence/higaisa-or-winnti-apt-41-backdoors-old-and-new/",
]
version = "1.0.30"
query = '''
sequence with maxspan=2m
[file where event.action != "deletion" and process.name : "hh.exe"] by file.path
[process where event.action == "start"] by process.executable
'''
min_endpoint_version = "7.15.0"
optional_actions = []
[[actions]]
action = "kill_process"
field = "process.entity_id"
state = 1
[[threat]]
framework = "MITRE ATT&CK"
[[threat.technique]]
id = "T1566"
name = "Phishing"
reference = "https://attack.mitre.org/techniques/T1566/"
[[threat.technique.subtechnique]]
id = "T1566.001"
name = "Spearphishing Attachment"
reference = "https://attack.mitre.org/techniques/T1566/001/"
[threat.tactic]
id = "TA0001"
name = "Initial Access"
reference = "https://attack.mitre.org/tactics/TA0001/"
[[threat]]
framework = "MITRE ATT&CK"
[[threat.technique]]
id = "T1218"
name = "System Binary Proxy Execution"
reference = "https://attack.mitre.org/techniques/T1218/"
[[threat.technique.subtechnique]]
id = "T1218.001"
name = "Compiled HTML File"
reference = "https://attack.mitre.org/techniques/T1218/001/"
[threat.tactic]
id = "TA0005"
name = "Defense Evasion"
reference = "https://attack.mitre.org/tactics/TA0005/"
[internal]
min_endpoint_version = "7.15.0"
Stages and Predicates
Ordered sequence: each step below must occur in order within 2m, correlated by file.path, process.executable.
Stage 1: file
[file where event.action != "deletion" and process.name : "hh.exe"] by file.path
Stage 2: process
[process where event.action == "start"] by process.executable
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
event.action | eq |
| field:"EventType" kind:eq value:"start" |
event.action | ne |
| field:"EventType" kind:ne value:"deletion" |
process.name | wildcard |
| field:"process_name" kind:wildcard value:"hh.exe" |