Detection rules › Elastic

Suspicious Microsoft Office Embedded Object

Source
github.com/elastic/protections-artifacts

Identifies suspicious file extensions written by a Microsoft Office process from an embedded OLE stream, this is frequently used by malicious documents to drop malicious content for initial access.

MITRE ATT&CK coverage

Rule body

[rule]
description = """
Identifies suspicious file extensions written by a Microsoft Office process from an embedded OLE stream, this is
frequently used by malicious documents to drop malicious content for initial access.
"""
id = "a3afbd2f-e9e6-41d9-ad24-aecb6a4b6906"
license = "Elastic License v2"
name = "Suspicious Microsoft Office Embedded Object"
os_list = ["windows"]
version = "1.0.9"

query = '''
file where event.action != "deletion" and process.name : ("winword.exe", "excel.exe", "powerpnt.exe") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info: ("*!OleSaveToStream*", "*!OleLoad*")) and
 (
  file.extension : ("exe", "dll", "js", "vbs", "vbe", "jse", "url", "chm", "bat", "mht", "hta", "search-ms") or

  /* PE & HelpFile */
  file.Ext.header_bytes : ("4d5a*", "49545346*")
  )
'''

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

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

[[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 = "T1203"
name = "Exploitation for Client Execution"
reference = "https://attack.mitre.org/techniques/T1203/"


[threat.tactic]
id = "TA0002"
name = "Execution"
reference = "https://attack.mitre.org/tactics/TA0002/"

[internal]
min_endpoint_version = "8.7.0"

Stages and Predicates

Stage 1: file

file where event.action != "deletion" and process.name : ("winword.exe", "excel.exe", "powerpnt.exe") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info: ("*!OleSaveToStream*", "*!OleLoad*")) and
 (
  file.extension : ("exe", "dll", "js", "vbs", "vbe", "jse", "url", "chm", "bat", "mht", "hta", "search-ms") or
  file.Ext.header_bytes : ("4d5a*", "49545346*")
  )

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
event.actionne
  • deletion corpus 86 (elastic 86)
field:"EventType" kind:ne value:"deletion"
file.Ext.header_byteswildcard
  • 49545346*
  • 4d5a* corpus 46 (elastic 46)
field:"file.Ext.header_bytes" kind:wildcard
file.extensionwildcard
  • bat corpus 13 (elastic 13)
  • chm
  • dll corpus 33 (elastic 33)
  • exe corpus 32 (elastic 32)
  • hta corpus 20 (elastic 20)
  • js corpus 23 (elastic 23)
  • jse corpus 18 (elastic 18)
  • mht
  • search-ms corpus 2 (elastic 2)
  • url corpus 5 (elastic 5)
  • vbe corpus 18 (elastic 18)
  • vbs corpus 19 (elastic 19)
field:"file.extension" kind:wildcard
process.namewildcard
  • excel.exe corpus 34 (elastic 34)
  • powerpnt.exe corpus 31 (elastic 31)
  • winword.exe corpus 35 (elastic 35)
field:"process_name" kind:wildcard