Welcome to another Hack the Box walkthrough. In this blog post, I have documented how to pwn the TombWatcher machine on Hack the Box. If you are new to this channel, please don’t forget to like, comment, and subscribe to my YouTube channel for more awesome content.
About the Machine
TombWatcher is a medium-difficulty Windows Active Directory machine that challenges players to exploit misconfigurations in Active Directory Certificate Services (AD CS). The initial foothold is gained through enumeration of vulnerable certificate templates, specifically one that allows low-privileged users to enroll certificates with the Certificate Request Agent application policy. This enables an ESC1-style attack, where a user (cert_admin) can request a certificate on behalf of a high-privileged account like Administrator, ultimately leading to domain compromise. Additionally, players must explore deleted AD objects, leveraging PowerShell to enumerate tombstoned users via Get-ADObject, restore accounts with Restore-ADObject, and regain access by resetting passwords using Set-ADAccountPassword. TombWatcher combines certificate abuse, account recovery, and AD enumeration to simulate realistic attack paths often encountered in enterprise environments.
The first step in solving this machine is to connect my Kali Linux terminal with Hack the Box server. To set up this connection, I ran the following command in my terminal:
After the connection has been set up, I started the target machine, and I was assigned an IP address of 10.10.11.72. Then I performed reconnaissance using Nmap to find all the open port and services associated with the target machine. Using the following command, I found all the services and port running at 10.10.11.72:
After the nmap scan was completed, it displayed all the open ports associated with the target machine.
I noticed an error “Clock skew too great” in the nmap scan. This error is caused due to the time difference between the target machine (10.10.11.72) and our machine. To rectified this, I ran the following command in my terminal:
This command disables automatic time synchronization via NTP (Network Time Protocol) on Linux systems that use systemd. When you turn this off, your system clock will no longer update automatically using internet time servers. You'll need to manually set the time using timedatectl set-time or another method if needed.
This command will manually synchronizes your system clock with the time server at IP address 10.10.11.72.
- Local Name Resolution Without DNS: The /etc/hosts file allows your system to resolve hostnames without querying a DNS server. It is useful when DNS is unavailable or misconfigured and when you're in an isolated or internal network.
- Testing and Development: You can point a domain (like myapp.local) to a local or test server (e.g., 127.0.0.1 or a staging IP). For example: 127.0.0.1 myapp.local This allows testing websites or apps locally using human-readable names.
- Security and Control: It can prevent connections to known malicious domains by redirecting them: 127.0.0.1 malicious-site.com
After trying few other methods, then I remembered that the TombWatcher is a Windows machine and I immediately thought of using bloodhound. Bloodhound is primarily used in Active Directory (AD) environments to analyze and visualize relationships and permissions for identifying privilege escalation paths and attack vectors. It is widely used by red teamers and penetration testers to gain a foothold inside a Windows network (e.g., via phishing or exploitation). It is also used to escalate privileges, move laterally, or eventually gain Domain Admin rights. To use bloodhound, I ran the following command in my terminal:
I copied the hash and created a file called hash.txt and pasted the hash.
I got basketball after cracking the hash.
After cracking the hash and obtaining the plaintext basketball, I used bloodyAD to check if the account had the ability to modify AD objects. I discovered that I could add users to the INFRASTRUCTURE group:
The operation succeeded, and alfred was now a member of INFRASTRUCTURE. I suspected this group had elevated permissions in the domain, so I proceeded to investigate how that could be leveraged for privilege escalation or lateral movement.
After adding alfred to the Infrastructure group, I used gMSADumper.py to check for group-managed service accounts (gMSAs) with readable credentials:
The script revealed that ansible_dev$ was a gMSA account whose password could be read by members of the Infrastructure group. Since I was already part of this group, I was able to retrieve the AES keys and NT hash for the account. These credentials could now be used to authenticate as ansible_dev$ - potentially granting me further access to the domain.
After identifying valid credentials for the john account (Test1234.), I used Evil-WinRM to establish an interactive shell on the target:
This gave me PowerShell access as the john user, which I then used to enumerate Active Directory, search for misconfigurations, and perform privilege escalation techniques. After successfully connecting to the target using Evil-WinRM as john, I navigated to the user’s desktop and retrieved the user flag: type ../desktop/user.txt.
To investigate the domain history and potential tampering, I queried deleted objects in Active Directory using:
This revealed multiple deleted instances of a user account named cert_admin, all residing in the Deleted Objects container. Each deletion instance had a unique objectSid, indicating the user was deleted and recreated multiple times, possibly as part of a privilege escalation or account abuse chain.
After discovering several deleted instances of the cert_admin account using Get-ADObject, I restored the most recent one using:
After restoring the deleted cert_admin user using Restore-ADObject, I reset its password to a known value using:
- It allows EnrolleeSuppliesSubject
- It uses Schema Version 1
I issued a certificate to cert_admin with CRA permissions:
I leveraged this misconfiguration to request a certificate on behalf of the domain administrator using:
This gave me a certificate and private key (administrator.pfx) that I used to authenticate as the Administrator:
After obtaining the evil-winrm shell, I ran the following script to obtain the root flag (Explanation: type was used to display the contents of the file named root.txt located in the Desktop directory one level above the current working directory, which is similar to cat in Linux):
Hurray, I got the root flag!!!
Keywords
eighteen htb writeup
eighteen htb walkthrough
eighteen htb
htb eighteen writeup
eighteen writeup
htb eighteen
htb eighteen walkthrough
hackthebox eighteen writeup
eighteen walkthrough
gavel htb
eighteen hackthebox writeup
eighteen writeup htb
eighteen hackthebox
gavel htb writeup
eighteen hack the box
hack the box eighteen
gavel writeup
hackthebox eighteen
htb gavel writeup
eighteen walkthrough htb
eighteen hack the box walkthrough
eighteen.htb writeup
hackthebox eighteen walkthrough
hack the box eighteen walkthrough
eighteen.htb
eighteen hackthebox walkthrough
hack the box eighteen writeup
dc01.eighteen.htb
eighteen write up
eighteen hack the box writeup
eighteen htb machine
htb "eighteen" writeup
"overwatch.htb"
htb gavel
htb gavel walkthrough
"eighteen.htb"
eighteen htb write up
pterodactyl htb walkthrough
hackthebox gavel writeup
"eighteen" hackthebox writeup
htb eighteen write up
eighteen machine htb
gavel htb walkthrough
"eighteen" htb writeup
gavel walkthrough
signed htb
facts walkthrough
gavel hackthebox writeup
eighteen.htb walkthrough
gavel htb write up
"eighteen" htb walkthrough
htb "eighteen"
htb signed
facts hackthebox writeup
cctv hackthebox walkthrough
gavel.htb
overwatch htb walkthrough
gavel hack the box
nanocorp walkthrough
hackthebox gavel
eighteen writeup hackthebox
gavel hackthebox
"overwatch" htb writeup
gavel writeup htb
writeup eighteen
hackthebox "eighteen"
"eighteen.htb" writeup
gavel hackthebox walkthrough
wingdata htb
facts htb writeup
hack the box cctv
cctv hack the box
overwatch walkthrough htb
signed.htb
htb wingdata write up
"giveback" htb writeup
"monitorsfour"
"browsed" htb writeup
htb eighteen admin password iloveyou1
gavel.htb/rules
overwatch.htb:5985
htb eighteen privilege escalation walkthrough
htb walkthrough
eighteen.htb hackthebox
hack the box gavel
"pirate.htb"
hercules htb
overwatch hack the box writeup
pterodactyl hack the box walkthrough
nanocorp writeup
overwatch.htb writeup
htb monitorsfour
pterodactyl hackthebox walkthrough
fluffy htb
pterodactyl walkthrough htb
hackthebox hercules
htb browsed
"dc01.eighteen.htb"
32940defd3c3ef70a2dd44a5301ff984c4742f0baae76ff5b8783994f8a503ca
ina2we6harj2gaw!
cctv hackthebox
hackthebox "eighteen" writeup
cctv hackthebox writeup
hack the box gavel sql injection payload inventory.php sort
"eighteen" hack the box writeup
gavel writeup hackthebox
gavel.htb/.git
htb 18
giveback walkthrough
hackthebox cctv
hackthebox gavel walkthrough
hackthebox eighteen machine
htb guardian writeup
htb cctv walkthrough
htb editor writeup
hackthebox facts writeup
nanocorp htb walkthrough
cctv htb
overwatch hack the box walkthrough
pterodactyl hack the box
pterodactyl hack the box writeup
htb cctv
hackthebox nanocorp writeup
overwatch writeup hackthebox
giveback htb writeup
hackthebox airtouch writeup
htb pterodactyl walkthrough
hackthebox overwatch walkthrough
htb overwatch
htb nanocorp writeup
browsed htb writeup
overwatch htb
pterodactyl htb
htb pterodactyl
browsed htb walkthrough
htb artificial
htb topology writeup
topology htb writeup
"0673ad90a0b4afb19d662336f0fce3a9edd0b7b19193717be28ce4d66c887133"
989c5a8ee87a0e9521ec81a79187d162109282f0
securevision cctv exploit
$2y$10$cmytvwfrnt1xfqsitsjrve/apxwxcifqcurnm5n.rhlulwm0jrtbm
hackthebox facts walkthrough
hack the box wingdata
signed walkthrough
writeup wingdata
htb gavel write up
"giveback.htb"
cctv.htb
cctv htb walkthrough
cctv.htb writeup
editor.htb:8080
htb cctv writeup
giveback htb
htb interpreter walkthrough
hercules writeup
monitorsfour.htb/controllers
wiki.editor.htb
monitorsfour.htb/robots.txt
monitorsfour htb writeup
facts hack the box writeup
editor.htb
nanocorp.htb
conversor walkthrough
hackthebox pterodactyl walkthrough
htb edit
hack the box eighteen machine
giveback htb walkthrough
browsed htb
htb hercules writeup
pterodactyl.htb walkthrough
browsed.htb writeup
planning htb
monitorsfour htb walkthrough
overwatch htb write up
htb fluffy
overwatch hackthebox
hackthebox monitorsfour
htb nanocorp
htb nanocorp walkthrough
nanocorp hackthebox
facts hackthebox walkthrough
pterodactyl writeup htb
"facts.htb"
overwatch htb machine
artificial htb
browsed htb write up
hackthebox pterodactyl
pterodactyl hackthebox writeup
htb pterodactyl writeup
hackthebox nanocorp
htb browsed walkthrough
htb planning
browsed walkthrough
htb gavel sql injection payload inventory.php
hack the box gavel sql injection payload inventory.php
htb gavel walkthrough sql injection payload inventory.php
hack the box gavel sql injection payload inventory.php 2025
overwatch htb writeup
htb gavel walkthrough pdo injection sort parameter
hack the box gavel sql injection payload 2025
htb gavel admin password or hash
htb gavel sql injection payload inventory.php sort
htb gavel walkthrough sql injection inventory.php payload
hack the box gavel sql injection inventory.php payload 2025
htb gavel machine walkthrough pdo injection sort parameter
htb gavel walkthrough sql injection inventory.php
htb machine editor xwiki simplistcode pro
hack the box gavel walkthrough sql injection payload
hack the box gavel walkthrough sql injection payload inventory.php
hackthebox eighteen machine walkthrough
htb gavel walkthrough sql injection payload
nanocorp htb
hackthebox gavel sql injection payload inventory.php
gavel.htb/admin.php
hack the box gavel sql injection inventory.php payload
htb eighteen machine walkthrough
htb overwatch walkthrough
"gavel.htb"
hack the box gavel walkthrough pdo injection
facts htb walkthrough
hack the box eighteen machine walkthrough
htb gavel exact sql injection payload inventory.php
facts.htb:54321
eighteen.htb:5985
htb overwatch writeup
"browsed.htb"
gavel 2.0 exploit
nanocorp htb writeup
hackthebox overwatch writeup
"0673ad90a0b4afb19d662336f0fce3a9edd0b7b19193717be28ce4d66c887133" password
gavel.htb/includes
overwatch hackthebox writeup
hercules htb writeup
editor htb
gavel-util
signed htb walkthrough
overwatch writeup htb
guardian htb writeup
overwatch hackthebox walkthrough
gavel htb admin password or hash
"hack the box" "eighteen" writeup
monitorsfour.htb:5985
eighteen htb github
cctv htb writeup
editor htb walkthrough
"eighteen" htb
hercules htb walkthrough
conversor htb walkthrough
pterodactyl htb writeup




























0 Comments