Creation or Modification of Domain Backup DPAPI private key
Identifies the creation or modification of Domain Backup private keys. Adversaries may extract the Data Protection API (DPAPI) domain backup key from a Domain Controller (DC) to be able to decrypt any domain user master key file.
Elastic rule (View on GitHub)
1[metadata]
2creation_date = "2020/08/13"
3integration = ["endpoint", "windows", "sentinel_one_cloud_funnel", "m365_defender", "crowdstrike"]
4maturity = "production"
5min_stack_comments = "Breaking change at 8.14.0 for the Windows Integration."
6min_stack_version = "8.14.0"
7updated_date = "2024/10/31"
8
9[rule]
10author = ["Elastic"]
11description = """
12Identifies the creation or modification of Domain Backup private keys. Adversaries may extract the Data Protection API
13(DPAPI) domain backup key from a Domain Controller (DC) to be able to decrypt any domain user master key file.
14"""
15from = "now-9m"
16index = ["winlogbeat-*", "logs-endpoint.events.file-*", "logs-windows.sysmon_operational-*", "endgame-*", "logs-sentinel_one_cloud_funnel.*", "logs-m365_defender.event-*", "logs-crowdstrike.fdr*"]
17language = "eql"
18license = "Elastic License v2"
19name = "Creation or Modification of Domain Backup DPAPI private key"
20note = """## Triage and analysis
21
22Domain DPAPI Backup keys are stored on domain controllers and can be dumped remotely with tools such as Mimikatz. The resulting .pvk private key can be used to decrypt ANY domain user masterkeys, which then can be used to decrypt any secrets protected by those keys.
23"""
24references = [
25 "https://www.dsinternals.com/en/retrieving-dpapi-backup-keys-from-active-directory/",
26 "https://posts.specterops.io/operational-guidance-for-offensive-user-dpapi-abuse-1fb7fac8b107",
27]
28risk_score = 73
29rule_id = "b83a7e96-2eb3-4edf-8346-427b6858d3bd"
30severity = "high"
31tags = ["Domain: Endpoint", "OS: Windows", "Use Case: Threat Detection", "Tactic: Credential Access", "Data Source: Elastic Endgame", "Data Source: Elastic Defend", "Data Source: Sysmon", "Data Source: SentinelOne", "Data Source: Microsoft Defender for Endpoint", "Data Source: Crowdstrike"]
32timestamp_override = "event.ingested"
33type = "eql"
34
35query = '''
36file where host.os.type == "windows" and event.type != "deletion" and file.name : ("ntds_capi_*.pfx", "ntds_capi_*.pvk")
37'''
38
39
40[[rule.threat]]
41framework = "MITRE ATT&CK"
42[[rule.threat.technique]]
43id = "T1552"
44name = "Unsecured Credentials"
45reference = "https://attack.mitre.org/techniques/T1552/"
46[[rule.threat.technique.subtechnique]]
47id = "T1552.004"
48name = "Private Keys"
49reference = "https://attack.mitre.org/techniques/T1552/004/"
50
51
52[[rule.threat.technique]]
53id = "T1555"
54name = "Credentials from Password Stores"
55reference = "https://attack.mitre.org/techniques/T1555/"
56
57
58[rule.threat.tactic]
59id = "TA0006"
60name = "Credential Access"
61reference = "https://attack.mitre.org/tactics/TA0006/"
Triage and analysis
Domain DPAPI Backup keys are stored on domain controllers and can be dumped remotely with tools such as Mimikatz. The resulting .pvk private key can be used to decrypt ANY domain user masterkeys, which then can be used to decrypt any secrets protected by those keys.
References
Related rules
- Kirbi File Creation
- Potential Local NTLM Relay via HTTP
- Attempt to Establish VScode Remote Tunnel
- Disable Windows Firewall Rules via Netsh
- Potential File Download via a Headless Browser