Detection rules › Splunk
Certificate Abuse - Windows (Sysmon)
Threat actors may use tools such as Certipy or Certify.exe to enumerate misconfigurations in certificate services, allowing them to gather information on potential vulnerabilities that could be exploited for privilege escalation or lateral movement within a network. This use case identifies potential abuse of Active Directory Certificate Services by monitoring Certificate Services events (4886 and 4887) or process creation events (event ID 4688) involving tools commonly used to exploit vulnerable configurations in AD CS such as certify.exe, accounting for instances where the binary has been renamed.
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Credential Access | T1649 Steal or Forge Authentication Certificates |
References
Event coverage
| Provider | Event | Title |
|---|---|---|
| Sysmon | Event ID 1 | Process creation |
Rule body yaml
id: '38494.69242'
title: Certificate Abuse - Windows
description: Threat actors may use tools such as Certipy or Certify.exe to enumerate
misconfigurations in certificate services, allowing them to gather information on
potential vulnerabilities that could be exploited for privilege escalation or lateral
movement within a network. This use case identifies potential abuse of Active Directory
Certificate Services by monitoring Certificate Services events (4886 and 4887) or
process creation events (event ID 4688) involving tools commonly used to exploit
vulnerable configurations in AD CS such as certify.exe, accounting for instances
where the binary has been renamed.
logic_format: Splunk
logic: '`get_endpoint_data` `get_endpoint_data_sysmon` (TERM(EventCode=1) OR "<EventID>1<")
("certify.exe" OR "request " OR "/ca:" OR "/template:" OR "/altname:") | where match(process,
"(?i)request\s.+/ca:.+/(template|altname):") | table _time, host, user user, process,
process_*, parent_* | bin span=1s | stats values(*) as * by _time, host '
techniques:
- credential-access:steal or forge authentication certificates
technique_id:
- T1649
data_category:
- Windows Sysmon
references:
- https://github.com/ly4k/Certipy
- https://www.kali.org/tools/certipy-ad/
- https://book.hacktricks.xyz/windows-hardening/active-directory-methodology/ad-certificates/domain-escalation
Stages and Predicates
Stage 1: search
`get_endpoint_data` `get_endpoint_data_sysmon` (TERM(EventCode=1) OR "<EventID>1<") ("certify.exe" OR "request " OR "/ca:" OR "/template:" OR "/altname:")
Stage 2: where
| where match(process, "(?i)request\s.+/ca:.+/(template|altname):")
Stage 3: table
| table _time, host, user user, process, process_*, parent_*
Stage 4: bucket
| bin span=1s
Stage 5: stats
| stats values(*) as * by _time, host
Indicators
Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.
Search terms
Bare-string tokens in the SPL search body. Splunk matches each token against _raw (the untyped raw event text) anywhere it appears, not against a specific field. These don't surface in the Indicators table because they aren't predicates on a known field.
| Stage | Term |
|---|---|
| 1 | TERM |
| 1 | "<EventID>1<" |
| 1 | "certify.exe" |
| 1 | "request " |
| 1 | "/ca:" |
| 1 | "/template:" |
| 1 | "/altname:" |