Enumerate

Nmap -sS -p-

Pasted image 20240609135540

80 - HTTP

Directory Enumeration

Gobuster

Common.txt:

  • aspnet_client

Directory list medium: Pasted image 20240609063141

  • http://$ip/aspnet_client
    • Response:
      • Pasted image 20240609061649

135/139/445 - SMB

  • Listing shares with no password failed

9998 - “distinct32”

  • http://$ip:9998 forwards to http://192.168.203.65:9998/interface/root#/login
    • SmarterMail
    • Pasted image 20240609070135
    • Source code shows build number as 6919
      • Pasted image 20240609080654
    • Searchsploit has an RCE exploit for builds before 6985
      • Running the exploit results in not standard out (seemingly does nothing)
      • (After hints) I edited the exploit to catch the reverse shell on local port 80 (so that it gets passed the firewall, and sent the connection request to port 17001 on the victim (not found in my initial Nmap scan as I didn’t scan all ports)).

Foothold

  • After executing the exploit we gain a shell as nt authority\system:
    • Pasted image 20240609140408

Proof

Pasted image 20240609142759