Skip to content

Commit 4e22f53

Browse files
committed
feat: add 2 additional analytics related to auditing option modification
1 parent c952f7b commit 4e22f53

File tree

2 files changed

+121
-0
lines changed

2 files changed

+121
-0
lines changed
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: Windows Audit Policy Auditing Option Disabled via Auditpol
2+
id: 663a7a50-b752-4c84-975b-8325ca3f6f9e
3+
version: 1
4+
date: '2025-01-27'
5+
author: Nasreddine Bencherchali, Splunk
6+
status: production
7+
type: TTP
8+
description: The following analytic identifies the execution of `auditpol.exe` with the "/set", "/option" and "/value:disable" command-line arguments used to disable specific auditing options of the audit policy. It leverages data from Endpoint Detection and Response (EDR) agents, focusing on process names and command-line executions. This activity can be significant as it indicates potential defense evasion by adversaries or Red Teams, aiming to limit data that can be leveraged for detections and audits. If confirmed malicious, this behavior could allow attackers to bypass defenses, and plan further attacks, potentially leading to full machine compromise or lateral movement.
9+
data_source:
10+
- Sysmon EventID 1
11+
- Windows Event Log Security 4688
12+
- CrowdStrike ProcessRollup2
13+
search: '| tstats `security_content_summariesonly` values(Processes.process) as process min(_time) as firstTime max(_time) as lastTime from datamodel=Endpoint.Processes where `process_auditpol` Processes.process="*/set*" Processes.process="*/option:*" Processes.process="*/value:disable*" Processes.process IN ("*FullPrivilegeAuditing*", "*AuditBaseObjects*", "*AuditBaseDirectories*") by Processes.dest Processes.user Processes.parent_process Processes.parent_process_name Processes.process_name Processes.original_file_name Processes.process Processes.process_id Processes.parent_process_id | `drop_dm_object_name(Processes)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_audit_policy_auditing_option_disabled_via_auditpol_filter`'
14+
how_to_implement: The detection is based on data that originates from Endpoint Detection and Response (EDR) agents. These agents are designed to provide security-related telemetry from the endpoints where the agent is installed. To implement this search, you must ingest logs that contain the process name, and process original file name. Additionally, you must ingest complete command-line executions. These logs must be processed using the appropriate Splunk Technology Add-ons that are specific to the EDR product. The logs must also be mapped to the `Processes` node of the `Endpoint` data model. Use the Splunk Common Information Model (CIM) to normalize the field names and speed up the data modeling process.
15+
known_false_positives: None identified. Attempts to disable logging should be identified and understood.
16+
references:
17+
- https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-gpac/262a2bed-93d4-4c04-abec-cf06e9ec72fd
18+
- https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/auditpol-set
19+
drilldown_searches:
20+
- name: View the detection results for - "$user$" and "$dest$"
21+
search: '%original_detection_search% | search user = "$user$" dest = "$dest$"'
22+
earliest_offset: $info_min_time$
23+
latest_offset: $info_max_time$
24+
- name: View risk events for the last 7 days for - "$user$" and "$dest$"
25+
search: '| from datamodel Risk.All_Risk | search normalized_risk_object IN ("$user$",
26+
"$dest$") starthoursago=168 | stats count min(_time) as firstTime max(_time)
27+
as lastTime values(search_name) as "Search Name" values(risk_message) as "Risk
28+
Message" values(analyticstories) as "Analytic Stories" values(annotations._all)
29+
as "Annotations" values(annotations.mitre_attack.mitre_tactic) as "ATT&CK Tactics"
30+
by normalized_risk_object | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)`'
31+
earliest_offset: $info_min_time$
32+
latest_offset: $info_max_time$
33+
rba:
34+
message: An instance of $parent_process_name$ spawning $process_name$ was identified attempting to disable an audit policy auditing option on endpoint $dest$ by user $user$.
35+
risk_objects:
36+
- field: user
37+
type: user
38+
score: 60
39+
- field: dest
40+
type: system
41+
score: 60
42+
threat_objects:
43+
- field: process_name
44+
type: process_name
45+
tags:
46+
analytic_story:
47+
- Windows Audit Policy Tampering
48+
asset_type: Endpoint
49+
mitre_attack_id:
50+
- T1562.002
51+
product:
52+
- Splunk Enterprise
53+
- Splunk Enterprise Security
54+
- Splunk Cloud
55+
security_domain: endpoint
56+
tests:
57+
- name: True Positive Test - Sysmon
58+
attack_data:
59+
- data:
60+
https://media.githubusercontent.com/media/splunk/attack_data/master/datasets/attack_techniques/T1562.002/auditpol_tampering/auditpol_tampering_sysmon.log
61+
source: XmlWinEventLog:Microsoft-Windows-Sysmon/Operational
62+
sourcetype: XmlWinEventLog
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: Windows Audit Policy Auditing Option Modified - Registry
2+
id: 27914692-9c62-44ea-9129-ceb429b61bd0
3+
version: 1
4+
date: '2025-01-27'
5+
author: Nasreddine Bencherchali, Splunk
6+
status: production
7+
type: Anomaly
8+
description: The following analytic detects potentially suspicious modifications to the Audit Policy auditing options registry values. It leverages data from the Endpoint.Registry data model, focusing on changes to one of the following auditing option values "CrashOnAuditFail", "FullPrivilegeAuditing", "AuditBaseObjects" and "AuditBaseDirectories" within the "HKLM\\System\\CurrentControlSet\\Control\\Lsa\\" registry key. This activity is significant as it could be a sign of a threat actor trying to tamper with the audit policy configuration, and disabling SACLs configuration. If confirmed malicious, this behavior could allow attackers to bypass defenses, and plan further attacks, potentially leading to full machine compromise or lateral movement.
9+
data_source:
10+
- Sysmon EventID 13
11+
search: '| tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry WHERE Registry.registry_key_name="*\\Control\\Lsa" Registry.registry_value_name IN ("CrashOnAuditFail", "FullPrivilegeAuditing", "AuditBaseObjects", "AuditBaseDirectories") BY Registry.registry_path Registry.registry_key_name Registry.registry_value_name Registry.registry_value_data Registry.process_guid Registry.dest Registry.user | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_audit_policy_auditing_option_modified__registry_filter`'
12+
how_to_implement: To successfully implement this search, you need to be ingesting logs with the registry value name, registry path, and registry value data from your endpoints. If you are using Sysmon, you must have at least version 2.0 of the official Sysmon TA. https://splunkbase.splunk.com/app/5709
13+
known_false_positives: Active setup installer may add or modify this registry.
14+
references:
15+
- https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-gpac/262a2bed-93d4-4c04-abec-cf06e9ec72fd
16+
- https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/auditpol-set
17+
drilldown_searches:
18+
- name: View the detection results for - "$dest$" and "$user$"
19+
search: '%original_detection_search% | search dest = "$dest$" user = "$user$"'
20+
earliest_offset: $info_min_time$
21+
latest_offset: $info_max_time$
22+
- name: View risk events for the last 7 days for - "$dest$" and "$user$"
23+
search: '| from datamodel Risk.All_Risk | search normalized_risk_object IN ("$dest$",
24+
"$user$") starthoursago=168 | stats count min(_time) as firstTime max(_time)
25+
as lastTime values(search_name) as "Search Name" values(risk_message) as "Risk
26+
Message" values(analyticstories) as "Analytic Stories" values(annotations._all)
27+
as "Annotations" values(annotations.mitre_attack.mitre_tactic) as "ATT&CK Tactics"
28+
by normalized_risk_object | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)`'
29+
earliest_offset: $info_min_time$
30+
latest_offset: $info_max_time$
31+
rba:
32+
message: The auditing option $registry_value_name$ from the configured Audit Policy was modified on $dest$.
33+
risk_objects:
34+
- field: dest
35+
type: system
36+
score: 64
37+
- field: user
38+
type: user
39+
score: 64
40+
threat_objects: []
41+
tags:
42+
analytic_story:
43+
- Windows Audit Policy Tampering
44+
asset_type: Endpoint
45+
mitre_attack_id:
46+
- T1547.014
47+
- T1547
48+
product:
49+
- Splunk Enterprise
50+
- Splunk Enterprise Security
51+
- Splunk Cloud
52+
security_domain: endpoint
53+
tests:
54+
- name: True Positive Test - Sysmon
55+
attack_data:
56+
- data:
57+
https://media.githubusercontent.com/media/splunk/attack_data/master/datasets/attack_techniques/T1562.002/auditpol_tampering/auditpol_tampering_sysmon.log
58+
source: XmlWinEventLog:Microsoft-Windows-Sysmon/Operational
59+
sourcetype: XmlWinEventLog

0 commit comments

Comments
 (0)