Potential DLL SideLoading via Trusted Microsoft Programs

Identifies an instance of a Windows trusted program that is known to be vulnerable to DLL Search Order Hijacking starting after being renamed or from a non-standard path. This is uncommon behavior and may indicate an attempt to evade defenses via side loading a malicious DLL within the memory space of one of those processes.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2020/09/03"
 3integration = ["endpoint", "windows"]
 4maturity = "production"
 5min_stack_comments = "New fields added: required_fields, related_integrations, setup"
 6min_stack_version = "8.3.0"
 7updated_date = "2023/06/22"
 8
 9[rule]
10author = ["Elastic"]
11description = """
12Identifies an instance of a Windows trusted program that is known to be vulnerable to DLL Search Order Hijacking
13starting after being renamed or from a non-standard path. This is uncommon behavior and may indicate an attempt to evade
14defenses via side loading a malicious DLL within the memory space of one of those processes.
15"""
16from = "now-9m"
17index = ["winlogbeat-*", "logs-endpoint.events.*", "logs-windows.*", "endgame-*"]
18language = "eql"
19license = "Elastic License v2"
20name = "Potential DLL SideLoading via Trusted Microsoft Programs"
21note = """## Setup
22
23If enabling an EQL rule on a non-elastic-agent index (such as beats) for versions <8.2, events will not define `event.ingested` and default fallback for EQL rules was not added until 8.2, so you will need to add a custom pipeline to populate `event.ingested` to @timestamp for this rule to work.
24"""
25risk_score = 73
26rule_id = "1160dcdb-0a0a-4a79-91d8-9b84616edebd"
27severity = "high"
28tags = ["Domain: Endpoint", "OS: Windows", "Use Case: Threat Detection", "Tactic: Defense Evasion", "Data Source: Elastic Endgame", "Data Source: Elastic Defend"]
29timestamp_override = "event.ingested"
30type = "eql"
31
32query = '''
33process where host.os.type == "windows" and event.type == "start" and
34  process.pe.original_file_name in ("WinWord.exe", "EXPLORER.EXE", "w3wp.exe", "DISM.EXE") and
35  not (process.name : ("winword.exe", "explorer.exe", "w3wp.exe", "Dism.exe") or
36         process.executable : ("?:\\Windows\\explorer.exe",
37                               "?:\\Program Files\\Microsoft Office\\root\\Office*\\WINWORD.EXE",
38                               "?:\\Program Files?(x86)\\Microsoft Office\\root\\Office*\\WINWORD.EXE",
39                               "?:\\Windows\\System32\\Dism.exe",
40                               "?:\\Windows\\SysWOW64\\Dism.exe",
41                               "?:\\Windows\\System32\\inetsrv\\w3wp.exe")
42         )
43'''
44
45
46[[rule.threat]]
47framework = "MITRE ATT&CK"
48[[rule.threat.technique]]
49id = "T1036"
50name = "Masquerading"
51reference = "https://attack.mitre.org/techniques/T1036/"
52
53
54[rule.threat.tactic]
55id = "TA0005"
56name = "Defense Evasion"
57reference = "https://attack.mitre.org/tactics/TA0005/"

Setup

If enabling an EQL rule on a non-elastic-agent index (such as beats) for versions <8.2, events will not define event.ingested and default fallback for EQL rules was not added until 8.2, so you will need to add a custom pipeline to populate event.ingested to @timestamp for this rule to work.

Related rules

to-top