WDAC Policy File by an Unusual Process
Identifies the creation of a Windows Defender Application Control (WDAC) policy file by an unusual process. Adversaries may use a secially crafted WDAC policy to restrict the execution of security products.
Elastic rule (View on GitHub)
1[metadata]
2creation_date = "2025/02/28"
3integration = ["endpoint", "windows", "m365_defender", "sentinel_one_cloud_funnel"]
4maturity = "production"
5updated_date = "2025/03/20"
6
7[rule]
8author = ["Elastic"]
9description = """
10Identifies the creation of a Windows Defender Application Control (WDAC) policy file by an unusual process. Adversaries
11may use a secially crafted WDAC policy to restrict the execution of security products.
12"""
13from = "now-9m"
14index = [
15 "winlogbeat-*",
16 "logs-endpoint.events.file-*",
17 "logs-windows.sysmon_operational-*",
18 "endgame-*",
19 "logs-m365_defender.event-*",
20 "logs-sentinel_one_cloud_funnel.*",
21]
22language = "eql"
23license = "Elastic License v2"
24name = "WDAC Policy File by an Unusual Process"
25note = """## Triage and analysis
26
27### Investigating WDAC Policy File by an Unusual Process
28
29#### Possible investigation steps
30
31- Investigate the process execution chain (parent process tree) for unknown processes. Examine their executable files for prevalence, whether they are located in expected locations, and if they are signed with valid digital signatures.
32- Identify the user account that performed the action and whether it should perform this kind of action.
33- Contact the account owner and confirm whether they are aware of this activity.
34- Investigate other alerts associated with the user/host during the past 48 hours.
35 - Verify if any other anti-forensics behaviors were observed.
36- Investigate the event logs prior to the action for suspicious behaviors that an attacker may be trying to cover up.
37
38### False positive analysis
39
40- This activity is unlikely to happen legitimately. Benign true positives (B-TPs) can be added as exceptions if necessary.
41
42### Response and remediation
43
44- Initiate the incident response process based on the outcome of the triage.
45- Isolate the involved host to prevent further post-compromise behavior.
46- Re-enable affected logging components, services, and security monitoring.
47- Investigate credential exposure on systems compromised or used by the attacker to ensure all compromised accounts are identified. Reset passwords for these accounts and other potentially compromised credentials, such as email, business systems, and web services.
48- Run a full antimalware scan. This may reveal additional artifacts left in the system, persistence mechanisms, and malware components.
49- Determine the initial vector abused by the attacker and take action to prevent reinfection through the same vector.
50- Using the incident response data, update logging and audit policies to improve the mean time to detect (MTTD) and the mean time to respond (MTTR).
51"""
52references = [
53 "https://github.com/logangoins/Krueger/tree/main",
54 "https://beierle.win/2024-12-20-Weaponizing-WDAC-Killing-the-Dreams-of-EDR/",
55]
56risk_score = 73
57rule_id = "3aaf37f3-05a1-40a5-bb6e-e380c4f92c52"
58severity = "high"
59tags = [
60 "Domain: Endpoint",
61 "OS: Windows",
62 "Use Case: Threat Detection",
63 "Tactic: Defense Evasion",
64 "Data Source: Elastic Endgame",
65 "Resources: Investigation Guide",
66 "Data Source: Elastic Defend",
67 "Data Source: Sysmon",
68 "Data Source: Microsoft Defender for Endpoint",
69 "Data Source: SentinelOne",
70]
71timestamp_override = "event.ingested"
72type = "eql"
73
74query = '''
75file where host.os.type == "windows" and event.action != "deletion" and
76 file.path : ("?:\\Windows\\System32\\CodeIntegrity\\*.p7b", "?:\\Windows\\System32\\CodeIntegrity\\CiPolicies\\Active\\*.cip") and
77 not process.executable : "C:\\Windows\\System32\\poqexec.exe"
78'''
79
80
81[[rule.threat]]
82framework = "MITRE ATT&CK"
83[[rule.threat.technique]]
84id = "T1562"
85name = "Impair Defenses"
86reference = "https://attack.mitre.org/techniques/T1562/"
87
88
89[rule.threat.tactic]
90id = "TA0005"
91name = "Defense Evasion"
92reference = "https://attack.mitre.org/tactics/TA0005/"
toml
Triage and analysis
Investigating WDAC Policy File by an Unusual Process
Possible investigation steps
- Investigate the process execution chain (parent process tree) for unknown processes. Examine their executable files for prevalence, whether they are located in expected locations, and if they are signed with valid digital signatures.
- Identify the user account that performed the action and whether it should perform this kind of action.
- Contact the account owner and confirm whether they are aware of this activity.
- Investigate other alerts associated with the user/host during the past 48 hours.
- Verify if any other anti-forensics behaviors were observed.
- Investigate the event logs prior to the action for suspicious behaviors that an attacker may be trying to cover up.
False positive analysis
- This activity is unlikely to happen legitimately. Benign true positives (B-TPs) can be added as exceptions if necessary.
Response and remediation
- Initiate the incident response process based on the outcome of the triage.
- Isolate the involved host to prevent further post-compromise behavior.
- Re-enable affected logging components, services, and security monitoring.
- Investigate credential exposure on systems compromised or used by the attacker to ensure all compromised accounts are identified. Reset passwords for these accounts and other potentially compromised credentials, such as email, business systems, and web services.
- Run a full antimalware scan. This may reveal additional artifacts left in the system, persistence mechanisms, and malware components.
- Determine the initial vector abused by the attacker and take action to prevent reinfection through the same vector.
- Using the incident response data, update logging and audit policies to improve the mean time to detect (MTTD) and the mean time to respond (MTTR).
References
Related rules
- Adding Hidden File Attribute via Attrib
- Alternate Data Stream Creation/Execution at Volume Root Directory
- Attempt to Install Kali Linux via WSL
- Bypass UAC via Event Viewer
- Clearing Windows Console History