SMB


Nmap discovered a Windows Directory service on the target ports 139 and 445

┌──(kali㉿kali)-[~/PEN-200/PG_PRACTICE/nagoya]
└─$ nmap --script smb-enum-shares -sV -p139,445 $IP
Starting Nmap 7.95 ( https://nmap.org ) at 2025-04-23 14:22 CEST
Nmap scan report for nagoya.nagoya-industries.com (192.168.158.21)
Host is up (0.027s latency).
 
PORT    STATE SERVICE       VERSION
139/tcp open  netbios-ssn   Microsoft Windows netbios-ssn
445/tcp open  microsoft-ds?
Service Info: OS: Windows; CPE: cpe:/o:microsoft:windows
 
Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
Nmap done: 1 IP address (1 host up) scanned in 11.41 seconds

Share mapping failed

Null Session


┌──(kali㉿kali)-[~/PEN-200/PG_PRACTICE/nagoya]
└─$ nxc smb $IP -u '' -p '' --shares --interfaces
SMB         192.168.158.21  445    NAGOYA           [*] Windows 10 / Server 2019 Build 17763 x64 (name:NAGOYA) (domain:nagoya-industries.com) (signing:True) (SMBv1:False)
SMB         192.168.158.21  445    NAGOYA           [+] nagoya-industries.com\: 
SMB         192.168.158.21  445    NAGOYA           [-] Error enumerating shares: STATUS_ACCESS_DENIED

The target SMB server allows guest access but lack of privileges prevents enumerating it

┌──(kali㉿kali)-[~/PEN-200/PG_PRACTICE/nagoya]
└─$ smbclient -L //$IP/                           
Password for [WORKGROUP\kali]:
Anonymous login successful
 
	Sharename       Type      Comment
	---------       ----      -------
Reconnecting with SMB1 for workgroup listing.
do_connect: Connection to 192.168.158.21 failed (Error NT_STATUS_RESOURCE_NAME_NOT_FOUND)
Unable to connect with SMB1 -- no workgroup available

The target SMB server also allows anonymous access but lack of privileges prevents enumerating it