Detection rules › Elastic

Potential DLL Hollowing from a Writable Image

Source
github.com/elastic/protections-artifacts

Identifies attempts to stealthily execute malicious code using DLL hollowing technique from a writable image.

MITRE ATT&CK coverage

Rule body

[rule]
description = "Identifies attempts to stealthily execute malicious code using DLL hollowing technique from a writable image."
id = "9d0b29fc-df7a-4ebb-b082-3d6579193beb"
license = "Elastic License v2"
name = "Potential DLL Hollowing from a Writable Image"
os_list = ["windows"]
reference = ["https://www.elastic.co/blog/process-ghosting-a-new-executable-image-tampering-attack"]
version = "1.0.4"

query = '''
library where
  dll.Ext.defense_evasions : "Process Tampering: Image is writable" and
  dll.Ext.defense_evasions : "Process Tampering: Image has write sharing" and
  dll.Ext.defense_evasions : "Process Tampering: Image has been accessed before mapping"
'''

min_endpoint_version = "8.7.0"
[[actions]]
action = "kill_process"
field = "process.entity_id"
state = 0
tree = true

[[optional_actions]]
action = "rollback"
field = "process.entity_id"
state = 0

[[threat]]
framework = "MITRE ATT&CK"
[[threat.technique]]
id = "T1055"
name = "Process Injection"
reference = "https://attack.mitre.org/techniques/T1055/"

[[threat.technique]]
id = "T1211"
name = "Exploitation for Defense Evasion"
reference = "https://attack.mitre.org/techniques/T1211/"

[[threat.technique]]
id = "T1574"
name = "Hijack Execution Flow"
reference = "https://attack.mitre.org/techniques/T1574/"


[threat.tactic]
id = "TA0005"
name = "Defense Evasion"
reference = "https://attack.mitre.org/tactics/TA0005/"

[internal]
min_endpoint_version = "8.7.0"

Stages and Predicates

Stage 1: library

library where
  dll.Ext.defense_evasions : "Process Tampering: Image is writable" and
  dll.Ext.defense_evasions : "Process Tampering: Image has write sharing" and
  dll.Ext.defense_evasions : "Process Tampering: Image has been accessed before mapping"

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
dll.Ext.defense_evasionswildcard
  • Process Tampering: Image has been accessed before mapping corpus 2 (elastic 2)
  • Process Tampering: Image has write sharing
  • Process Tampering: Image is writable corpus 2 (elastic 2)
field:"dll.Ext.defense_evasions" kind:wildcard