exploiting-adcs-with-certipy
Was er macht
Dieses Tool hilft dabei, Sicherheitslücken in den Active Directory Certificate Services (AD CS) zu finden und auszunutzen. Angreifer mit eingeschränktem Zugriff können damit zu vollwertigen Administratoren werden.
Wann du ihn nutzt
- ✓Bei autorisierten Sicherheitstests in Unternehmensnetzwerken.
- ✓Wenn du nur eingeschränkten Zugriff hast und Administrator werden willst.
- ✓Um zu prüfen, ob die Einstellungen für Zertifikate korrekt sind.
Link zum Skill
https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/exploiting-adcs-with-certipy/SKILL.mdKopiere ihn und füge ihn in deine KI ein (Claude, ChatGPT oder Cursor) mit der Bitte, den Anweisungen zu folgen.
So nutzt du ihn
Am einfachsten: Kopiere die Nachricht und füge sie in deine KI ein. Sie liest den Skill und folgt den Anweisungen.
Fertige Nachricht zum Einfügen
Für Claude Code, Codex oder Cursor: Führe den Befehl in deinem Projektordner aus, dann wird der Skill installiert.
Lade die SKILL.md herunter und lege sie in den Skills-Ordner deines Agenten.
Beispielanfrage an deine KI
“Finde Sicherheitslücken in AD CS und erkläre mir, wie ich Administrator werden kann.”
5 neue Skills pro Woche. 1 Minute Lesezeit.
So funktioniert es
Das Tool sucht nach Fehlkonfigurationen in AD CS, die das Erstellen gefälschter Zertifikate erlauben. Mit diesen Zertifikaten lassen sich Benutzer mit hohen Rechten, etwa Administratoren, nachahmen, ohne ihr Passwort zu kennen.
Technischer Inhalt (originale SKILL.md)
Originaltext des Autors, auf Englisch, direkt von GitHub.
Exploiting AD CS with Certipy
Legal Notice: This skill is for authorized security testing and educational purposes only. Active Directory Certificate Services attacks can result in full domain compromise. Run these techniques only against systems you own or have explicit written authorization to test. Unauthorized use is illegal under computer fraud statutes.
Overview
Active Directory Certificate Services (AD CS) is Microsoft's public-key infrastructure role used to issue certificates for authentication, encryption, and signing inside a Windows domain. SpecterOps researchers Will Schroeder and Lee Christensen documented a family of privilege-escalation primitives in their 2021 whitepaper Certified Pre-Owned, naming them ESC1 through ESC8. The community has since extended the catalog through ESC16. Because a certificate that maps to a privileged principal can be used for PKINIT Kerberos authentication, an attacker who obtains such a certificate can authenticate as a Domain Admin or Domain Controller without ever knowing the password — and the certificate remains valid even after a password reset.
Certipy (package certipy-ad, maintained by Oliver Lyak / ly4k) is the de-facto offensive toolkit for AD CS. It is a pure-Python tool that enumerates certificate authorities and templates over LDAP/RPC, requests and forges certificates, performs PKINIT/Schannel authentication, runs Shadow Credentials attacks, and relays coerced NTLM authentication into AD CS HTTP and RPC enrollment endpoints. Certipy supports detection and exploitation across the full ESC1-ESC16 range, making it the primary tool for AD CS assessment. Source: ly4k/Certipy and SpecterOps "Certified Pre-Owned".
When to Use
- During internal penetration tests and red-team engagements where AD CS is in scope
- When a low-privileged domain foothold needs a path to Domain Admin / Domain Controller
- To validate that certificate template ACLs and CA configuration are hardened
- When testing detection coverage for certificate-based privilege escalation
- During purple-team exercises to generate ESC1/ESC8 telemetry for blue-team tuning
Prerequisites
- Authorized engagement scope that explicitly includes AD CS exploitation
- A foothold: valid domain credentials (password, NT hash, or Kerberos ticket) for any low-privileged user
- Network reachability to a Domain Controller (LDAP/389, LDAPS/636) and the CA host
- Python 3.10+ (Certipy 5.x requires Python 3.12+) and a Linux attack host
- Install Certipy:
# Recommended isolated install pipx install certipy-ad # Or with pip pip install certipy-ad # Verify certipy --version - For ESC8 relay you also need a coercion tool (Coercer/PetitPotam) and reachable victim machine accounts
Objectives
- Enumerate every CA, template, and enrollment endpoint in the forest
- Identify which ESC1-ESC16 misconfigurations are exploitable from the current principal
- Request a certificate impersonating a privileged target (ESC1 SAN abuse)
- Relay coerced authentication into AD CS web enrollment to obtain a DC certificate (ESC8)
- Authenticate with a forged/issued certificate to recover a TGT and NT hash
- Document each finding with evidence and remediation guidance
MITRE ATT&CK Mapping
| ID | Technique | Application in this skill |
|---|---|---|
| T1649 | Steal or Forge Authentication Certificates | Requesting, forging, and abusing AD CS certificates (ESC1-ESC16) to authenticate as privileged principals |
Workflow
Step 1: Enumerate AD CS with certipy find
Collect CA and template configuration and flag vulnerable templates. find runs LDAP and RPC queries and produces JSON, a BloodHound-compatible ZIP, and a human-readable text report.
# Full enumeration, only enabled templates, hide built-in admin ACEs
certipy find \
-u 'attacker@corp.local' -p 'Passw0rd!' \
-dc-ip 10.0.0.100 -text -enabled -hide-admins
# Output only templates Certipy considers vulnerable
certipy find \
-u 'attacker@corp.local' -p 'Passw0rd!' \
-dc-ip 10.0.0.100 -vulnerable -stdout
# Authenticate with an NT hash instead of a password
certipy find -u 'attacker@corp.local' -hashes ':fc525c9683e8fe067095ba2ddc971889' \
-dc-ip 10.0.0.100 -vulnerable -stdout
…
Häufige Fragen
Was sind die Active Directory Certificate Services (AD CS)?
AD CS ist ein Microsoft-Dienst, der digitale Zertifikate für Authentifizierung und Sicherheit in Windows-Netzwerken ausstellt.
Was sind die Lücken ESC1 bis ESC16?
Das sind bestimmte Arten von Fehlkonfigurationen in AD CS, die ausgenutzt werden können, um höhere Rechte zu erlangen.
Brauche ich eine Erlaubnis, um dieses Tool zu verwenden?
Ja, das Tool darf nur in autorisierten Sicherheitstests mit ausdrücklicher schriftlicher Genehmigung eingesetzt werden.
Details
Originalbeschreibung des Autors
Use Certipy to enumerate AD CS certificate authorities and templates over LDAP/RPC, then exploit ESC1-ESC16 misconfigurations - SAN abuse, NTLM relay to web enrollment (ESC8), Shadow Credentials, golden certificate forgery, and PKINIT/Schannel auth. Use during authorized penetration tests to escalate a domain foothold to Domain Admin, or to validate that certificate template ACLs and CA hardening
Beliebtheit
- GitHub-Sterne
- 35k
- Platz im Ranking
- #7899
- Lizenz
- Apache-2.0
- Aktualisiert
- 31.8.2026
Kommentare
- …
Weitere Skills aus diesem Repository
abusing-dpapi-for-credential-access
35kGibt deinem KI-Agenten fertige Anweisungen für eine bestimmte Aufgabe, damit er sie besser und schneller erledigt.
abusing-shadow-credentials-for-privesc
35kBringt deinem KI-Agenten bei, klare und gut strukturierte Texte zu schreiben.
achieving-cmmc-level-2-compliance
35kHilft deinem Agenten, eine Umgebung für CMMC-Level-2-Konformität vorzubereiten. Setzt Sicherheitsanforderungen um und verwaltet nötige Dokumentation.
acquiring-disk-image-with-dd-and-dcfldd
35kHilft deinem Agenten, exakte Festplattenkopien zu erstellen. Wichtig, damit bei Ermittlungen keine Informationen verloren gehen oder verändert werden.
Ähnliche Skills
reverse-engineer-anything
422kHilft deinem Agenten, fertige Apps und Pakete zu untersuchen, um Funktionen zu erklären, Versionen zu vergleichen oder einen Nachbau zu leiten, mit dem REA-Tool.
1password
394kHilft deinem Agenten, die 1Password-Kommandozeile einzurichten, sich anzumelden und Geheimnisse zu lesen oder einzufügen, ohne deren Werte im Chat auszugeben.
healthcheck
394kHilft deinem Agenten, den Computer oder Server, auf dem OpenClaw läuft, auf Sicherheitsrisiken wie SSH, Firewall, Updates und Backups zu prüfen und sichere Korrekturen vorzuschlagen.