Cyborg
Last updated
Was this helpful?
Last updated
Was this helpful?
room contains:
Service Discovery
Web Content Discovery
Hash Cracking
Data Decompression
Privilege Escalation
IP: 10.10.230.194
Scan for open ports with nmap
Services Discovered
HTTP
80
Apache 2.4.18
SSH
22
OpenSSH 7.2p2
OS: Ubuntu
from service description
Answer Task 2 first three questions
Scan for directories using gobuster
Directories Discovered
/admin
homepage
from archive dropdown found archive.tar file
/etc
squid proxy
squid password and configuration files
From /etc
found /etc/squid/passwd
which contains password hash and squid config file /etc/squid/squid.conf
Store hash into a file passwd_hash.txt
Crack the hash using hashcat
squidward (music_archive)
We've successfully found the password from the hash
extract tar file
Found readme file which leads us to the borg documentation page
We need to install borg to extract the files from the compressed format
Install borg
decompress extracted files from archive.tar
using borg
After files are decompressed successfully, it data turns out to the home directory backup for alex's account
Found Password from /home/alex/Documents/note.txt
Login using alex's
We got access to Alex Account
Check for sudo exectuables
We can run file
/etc/mp3backups/backup.sh
as with root privileges
Check whether file is writable
We cannot write file, but user is alex, so we can change file permissions using chmod
Allow all permissions to the files
Note: Allowing all users rwx permissions isn't a good practice, but for ease, I've provided them rights
Overwrite file with Bash Reverse Shell on alex's machine
Reverse shell will connect to attacker's machine on port 4444
Start netcat on attacker's machine
Execute bash script from target machine
Now, we've successfully rooted the machine
For debian based For other distribution refer