Skip to content

Commit be932e4

Browse files
authored
Merge pull request #680 from splunk/zerologon_CVE-2020-1472
Detect Zerologon Attack CVE-2020-1472 Story and detections
2 parents 784a0bb + 4f8b5cd commit be932e4

9 files changed

+116
-2
lines changed

bin/generate.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,6 @@ def generate_workbench_panels(response_tasks, stories):
300300
output = template.render(response_tasks=workbench_panel_objects, stories=stories)
301301
with open(output_path, 'w') as f:
302302
f.write(output)
303-
304303
j2_env = Environment(loader=FileSystemLoader(TEMPLATE_PATH),
305304
trim_blocks=True)
306305
template = j2_env.get_template('workflow_actions.j2')
@@ -402,7 +401,7 @@ def map_response_tasks_to_stories(response_tasks):
402401
for story in response_task['tags']['analytics_story']:
403402
if 'type' in response_task.keys():
404403
task_name = str(response_task['type'] + ' - ' + response_task['name'])
405-
else:
404+
else:
406405
task_name = str('ESCU - ' + response_task['name'])
407406
if not (story in sto_res):
408407
sto_res[story] = {task_name}

bin/jinja2_templates/es_investigations.j2

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,12 @@
44
label = {{ story.name }}
55
description = {{ story.description }}
66
disabled = 0
7+
8+
{% if story.workbench_panels is defined %}
79
panels = {{ story.workbench_panels | tojson }}
10+
{% else %}
11+
panels =
12+
{% endif %}
813

914
{% endfor %}
1015

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Detect Computer Changed with Anonymous Account
2+
id: 1400624a-d42d-484d-8843-e6753e6e3645
3+
version: 1
4+
date: '2020-09-18'
5+
description: This search looks for Event Code 4742 (Computer Change) or EventCode 4624 (An account was successfully logged on) with an anonymous account.
6+
how_to_implement: This search requires audit computer account management to be enabled on the system in order to generate Event ID 4742.
7+
We strongly recommend that you specify your environment-specific configurations
8+
(index, source, sourcetype, etc.) for Windows Event Logs. Replace the macro definition
9+
with configurations for your Splunk environment. The search also uses a post-filter
10+
macro designed to filter out known false positives.
11+
type: ESCU
12+
references:
13+
- https://www.lares.com/blog/from-lares-labs-defensive-guidance-for-zerologon-cve-2020-1472/
14+
author: Rod Soto, Jose Hernandez, Splunk
15+
search: '`wineventlog_security` EventCode=4624 OR EventCode=4742 TargetUserName="ANONYMOUS LOGON" LogonType=3
16+
| stats count values(host) as host, values(TargetDomainName) as Domain, values(user) as user
17+
| `detect_computer_changed_with_anonymous_account_filter`'
18+
known_false_positives: None thus far found
19+
tags:
20+
analytics_story:
21+
- Detect Zerologon Attack
22+
mitre_attack_id:
23+
- T1210
24+
kill_chain_phases:
25+
- Actions on Objectives
26+
cis20:
27+
- CIS 6
28+
- CIS 8
29+
nist:
30+
- DE.AE
31+
- DE.CM
32+
security_domain: endpoint
33+
asset_type: Windows

detections/detect_credential_dumping_through_lsass_access.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ known_false_positives: The activity may be legitimate. Other tools can access ls
2525
tags:
2626
analytics_story:
2727
- Credential Dumping
28+
- Detect Zerologon Attack
2829
mitre_attack_id:
2930
- T1003.001
3031
kill_chain_phases:

detections/detect_mimikatz_using_loaded_images.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ known_false_positives: Other tools can import the same DLLs. These tools should
2424
tags:
2525
analytics_story:
2626
- Credential Dumping
27+
- Detect Zerologon Attack
2728
mitre_attack_id:
2829
- T1003.001
2930
kill_chain_phases:
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Detect Zerologon via Zeek
2+
id: bf7a06ec-f703-11ea-adc1-0242ac120002
3+
version: 1
4+
date: '2020-09-15'
5+
description: This search detects Zerologon attempts via Zeek DCE-RPC data.
6+
how_to_implement: You must be ingesting Zeek DCE-RPC data into Splunk.
7+
Zeek data should also be getting ingested in JSON format. We are detecting
8+
when all three RPC operations (NetrServerReqChallenge, NetrServerAuthenticate3, NetrServerPasswordSet2) are splunk_security_essentials_app
9+
via bro:rpc:json. These three operations are then correlated on the Zeek UID field.
10+
description: This search detects attempts to run exploits for the Zerologon CVE-2020-1472 vulnerability via Zeek RPC
11+
type: ESCU
12+
references:
13+
- https://www.secura.com/blog/zero-logon
14+
- https://github.com/SecuraBV/CVE-2020-1472
15+
- https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2020-1472
16+
author: Shannon Davis, Splunk
17+
search: '`zeek_rpc` operation IN (NetrServerPasswordSet2,NetrServerReqChallenge,NetrServerAuthenticate3)
18+
| bin span=5m _time
19+
| stats values(operation) dc(operation) as opscount count(eval(operation=="NetrServerReqChallenge")) as challenge
20+
count(eval(operation=="NetrServerAuthenticate3")) as authcount count(eval(operation=="NetrServerPasswordSet2")) as passcount
21+
count as totalcount by _time,src_ip,dest_ip
22+
| search opscount=3 authcount>4 passcount>0
23+
| search `detect_zerologon_via_zeek_filter`'
24+
known_false_positives: unknown
25+
tags:
26+
analytics_story:
27+
- Detect Zerologon Attack
28+
mitre_attack_id:
29+
- T1190
30+
kill_chain_phases:
31+
- Exploitation
32+
cis20:
33+
- CIS 8
34+
- CIS 11
35+
nist:
36+
- DE.CM
37+
security_domain: network
38+
asset_type: Network
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
definition: search *
2+
description: Use this macro to add additional filters
3+
name: detect_zerologon_via_zeek_filter
4+

macros/zeek_rpc.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
definition: index=zeek sourcetype="zeek:rpc:json"
2+
description: customer specific splunk configurations(eg- index, source, sourcetype).
3+
Replace the macro definition with configurations for your Splunk Environmnent.
4+
name: zeek_rpc
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Detect Zerologon Attack
2+
id: 5d14a962-569e-4578-939f-f386feb63ce4
3+
version: 1
4+
date: '2020-09-18'
5+
description: 'Uncover activity related to the execution of Zerologon CVE-2020-11472, a technique wherein
6+
attackers target a Microsoft Windows Domain Controller to reset its computer account password. The result from this attack
7+
is attackers can now provide themselves high privileges and take over Domain Controller. The included searches in this Analytic Story
8+
are designed to identify attempts to reset Domain Controller Computer Account via exploit code remotely or via the use of tool Mimikatz
9+
as payload carrier.'
10+
narrative: 'This attack is a privilege escalation technique, where attacker targets a Netlogon secure channel connection to a domain controller,
11+
using Netlogon Remote Protocol (MS-NRPC).
12+
This vulnerability exposes vulnerable Windows Domain Controllers to be targeted via unaunthenticated RPC calls which eventually
13+
reset Domain Contoller computer account ($) providing the attacker the opportunity to exfil domain controller credential secrets and
14+
assign themselve high privileges that can lead to domain controller and potentially complete network takeover.
15+
The detection searches in this Analytic Story use Windows Event viewer events and Sysmon events to detect attack execution, these
16+
searches monitor access to the Local Security Authority Subsystem Service (LSASS) process which is an indicator of the use of Mimikatz
17+
tool which has bee updated to carry this attack payload.'
18+
author: 'Rod Soto, Jose Hernandez, Stan Miskowicz, David Dorsey, Shannon Davis Splunk'
19+
type: ESCU
20+
references:
21+
- https://attack.mitre.org/wiki/Technique/T1003
22+
- https://github.com/SecuraBV/CVE-2020-1472
23+
- https://www.secura.com/blog/zero-logon
24+
- https://nvd.nist.gov/vuln/detail/CVE-2020-1472
25+
tags:
26+
analytics_story: Detect Zerologon Attack
27+
usecase: Advanced Threat Detection
28+
category:
29+
- Adversary Tactics

0 commit comments

Comments
 (0)