Hack The Box is an online platform allowing you to test your penetration testing skills and exchange ideas and methodologies with other members of similar interests. It contains several challenges that are constantly updated.
Many people asked me about the methodology I use to root machines in Hack The Box, so today I will explain in detail how I play Hack The Box machine.
I create a separate dirctory for every single machine, so that I can save the files, tools and scripts I used in each box sepatately and note-down the important things like password, hash, custom scripts/payloads etc.
Now you can use IP or URL in the commands or scripts as per your need.
AUTOMATE RECON / ENUM :
WEB ENUMERATION / DIRECTORY AND FILES BRUTE-FORCING :
if Port 80 or 443 is Open, you can use Nikto to collect more information.
Use Seclists for More Wordlists : https://github.com/danielmiessler/SecLists
EXPLOIT DB / SEARCHEXPLOIT :
SMB ENUMERATION :
If you’re on a windows box and port 139 or 445 is open, Enumerate SMB.
Enumerate information from Windows and Samba systems : https://kali.org/tools/enum4linux/
FILE TRANSFER IN LINUX
PYTHON HTTP SERVER :
Transfer the file test.file to the other server use the following command :
FILE TRANSFER IN WINDOWS
HTTP SERVER :
Local System :
Target System :
CHAT SERVER :
Now, type anything and it will show on the listener's shell.
FILE TRANSFER :
REVERSE SHELL :
Netcat is rarely present on production systems and even if it is there are several version of netcat, some of which don’t support the -e option.
If you have the wrong version of netcat installed, Jeff Price points out here that you might still be able to get your reverse shell back like this :
CREATE SSH KEYS :
SSH PASSWORD CRAKING USING KEY :
CRACK SSH PASSWORD USING HYDRA :
Impacket is a collection of Python classes for working with network protocols.
Pentestmonkey : http://pentestmonkey.net/cheat-sheet/shells/reverse-shell-cheat-sheet
Reverse Shell Cheatsheet.md : https://github.com/swisskyrepo/PayloadsAllTheThings/
Reverse Shell Cheat Sheet : https://oscp.infosecsanyam.in/shells/reverse-shell-cheat-sheet
Interactive tty-shell : https://github.com/cornerpirate/socat-shell
PayloadsAllTheThings : https://github.com/swisskyrepo/PayloadsAllTheThings
Evil-WinRM : https://github.com/Hackplayers/evil-winrm
- Basic Linux Privilege Escalation
- Linux elevation of privileges ToC
- Linux Smart Enumeration
- Linux - Privilege Escalation.md
- Linux Exploit Suggester
- Windows elevation of privileges ToC
- Windows Kernel Exploits
- Windows Privilege Escalation Fundamentals
- Just Another Windows (Enum) Script
- Windows PrivEsc Methods for Pentesters
- Windows Privilege Escalation
- Windows Privilege Escalation Guide
- Windows OS Enumurations
- Windows Privilege Escalation Techniques and Scripts
That's It.. ✌🏾 If You Like This Post, Please Share This With Your Friends.