Hack the Box (HTB) Machines Walkthrough Series — “Haircut”

Continuing once again with our series on Hack the Box (HTB) machines, this article contains the walkthrough of another HTB machine named “Haircut.”

HTB is an excellent platform that hosts machines belonging to multiple OSes. It also has some other interesting challenges as well. Individuals have to solve the puzzle (simple enumeration and pentest) in order to log into the platform and download the VPN pack to connect to the machines hosted on the HTB platform.

DevOps Connect:DevSecOps @ RSAC 2022

Note: Only writeups of retired HTB machines are allowed. The machine in this article, named “Haircut,” is retired.

Let’s start with this machine.

1. Download the VPN pack for the individual user and use the guidelines to log into the HTB VPN.

2. The “Haircut” machine IP is

3. We will adopt the same methodology of performing penetration testing. Let’s start with enumeration in order to gain as much information for the machine as possible.

4. We start the enumeration process with an nmap scan. Below is the output of the nmap scan. [CLICK ALL IMAGES TO ENLARGE FOR DETAIL]
<<nmap -sC -sV -oA haircut>>

5. Since there are no more leads for now, let’s try a brute-force directory traversal with the help of gobuster.

6. Let’s start to enumerate the finding from gobuster with exposed.php.
<<gobuster -u -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt -x php -t 20>>

 7. As you can see below, the page has a text box and looks like a requester. Click on Go.

8. Below we can see that the page test.html has been retrieved from the localhost.

9. Let’s try to see if we can make a request to our attacking box, Below, we can see that the request has (Read more...)

*** This is a Security Bloggers Network syndicated blog from InfoSec Resources authored by Security Ninja. Read the original post at: