21. Module Boxes - Medium

nmap (quick -F)

Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-07-17 11:43 EDT
Nmap scan report for 10.129.208.22
Host is up (0.047s latency).
Not shown: 94 closed tcp ports (reset)
PORT     STATE SERVICE
111/tcp  open  rpcbind
135/tcp  open  msrpc
139/tcp  open  netbios-ssn
445/tcp  open  microsoft-ds
2049/tcp open  nfs
3389/tcp open  ms-wbt-server

second more complete scan:

┌──(root㉿kali)-[~/…/module-enum/easy/10.129.175.225:2121/.ssh]
└─# nmap -sC -sV -Pn 10.129.208.22
Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-07-17 12:02 EDT
Nmap scan report for 10.129.208.22
Host is up (0.046s latency).
Not shown: 994 closed tcp ports (reset)
PORT     STATE SERVICE       VERSION
111/tcp  open  rpcbind       2-4 (RPC #100000)
| rpcinfo:
|   program version    port/proto  service
|   100000  2,3,4        111/tcp   rpcbind
|   100000  2,3,4        111/tcp6  rpcbind
|   100000  2,3,4        111/udp   rpcbind
|   100000  2,3,4        111/udp6  rpcbind
|   100003  2,3         2049/udp   nfs
|   100003  2,3         2049/udp6  nfs
|   100003  2,3,4       2049/tcp   nfs
|   100003  2,3,4       2049/tcp6  nfs
|   100005  1,2,3       2049/tcp   mountd
|   100005  1,2,3       2049/tcp6  mountd
|   100005  1,2,3       2049/udp   mountd
|   100005  1,2,3       2049/udp6  mountd
|   100021  1,2,3,4     2049/tcp   nlockmgr
|   100021  1,2,3,4     2049/tcp6  nlockmgr
|   100021  1,2,3,4     2049/udp   nlockmgr
|   100021  1,2,3,4     2049/udp6  nlockmgr
|   100024  1           2049/tcp   status
|   100024  1           2049/tcp6  status
|   100024  1           2049/udp   status
|_  100024  1           2049/udp6  status
135/tcp  open  msrpc         Microsoft Windows RPC
139/tcp  open  netbios-ssn   Microsoft Windows netbios-ssn
445/tcp  open  microsoft-ds?
2049/tcp open  nlockmgr      1-4 (RPC #100021)
3389/tcp open  ms-wbt-server Microsoft Terminal Services
|_ssl-date: 2024-07-17T16:03:52+00:00; +1s from scanner time.
| rdp-ntlm-info:
|   Target_Name: WINMEDIUM
|   NetBIOS_Domain_Name: WINMEDIUM
|   NetBIOS_Computer_Name: WINMEDIUM
|   DNS_Domain_Name: WINMEDIUM
|   DNS_Computer_Name: WINMEDIUM
|   Product_Version: 10.0.17763
|_  System_Time: 2024-07-17T16:03:41+00:00
| ssl-cert: Subject: commonName=WINMEDIUM
| Not valid before: 2024-03-17T13:59:32
|_Not valid after:  2024-09-16T13:59:32
Service Info: OS: Windows; CPE: cpe:/o:microsoft:windows

Host script results:
| smb2-security-mode:
|   3:1:1:
|_    Message signing enabled but not required
| smb2-time:
|   date: 2024-07-17T16:03:44
|_  start_date: N/A
┌──(root㉿kali)-[~/cpts/module-enum/med]
└─# showmount -e 10.129.208.22
Export list for 10.129.208.22:
/TechSupport (everyone)

found in ticket in nfs share:

 1smtp {
 2    host=smtp.web.dev.inlanefreight.htb
 3    #port=25
 4    ssl=true
 5    user="alex"
 6    password="lol123!mD"
 7    from="alex.g@web.dev.inlanefreight.htb"
 8}

we can use these credentials to login with RDP

enumerating a bit we find sqlserver creds on the windows box: ![](/img/Pasted image 20240717113016.png)

i got stuck here trying to login and I didn't do the common sense thing of, yknow, trying to login with this password as administrator using RDP;

lesson learned, as usual: try passing around credentials whenever you find them whenever possible.