nmap Network Reconnaissance

Full service and OS detection scan against Metasploitable2 (192.168.100.20) from Kali (192.168.100.10)

Summary

From the Kali attacker VM at 192.168.100.10, a full nmap service version and OS detection scan was run against the Metasploitable2 target at 192.168.100.20 on an isolated KVM homelab network. The scan completed in roughly half a minute and identified 23 open TCP ports exposing a wide attack surface of outdated, misconfigured, and intentionally vulnerable services.

Attack Technique Used

The attack technique here is classic network reconnaissance using nmap with service version detection (-sV), default script scanning (-sC), and OS fingerprinting (-O). This is the first phase of nearly every penetration test: systematically mapping reachable ports, identifying running services and versions, and inferring the underlying operating system in order to prioritize exploitation paths.

Steps to Reproduce

Terminal: Kali SSH (ssh owokali@192.168.100.10)

sudo nmap -sV -sC -O 192.168.100.20 -oN scan_results.txt
cat scan_results.txt

Complete findings from scan:

Detection (Wazuh)

Network scanning generates a large volume of short-lived connection attempts across many ports in a very small time window. In a monitored environment, Wazuh can flag this behavior: rule 5712 (or equivalent) triggers on repeated connection attempts and clear port-scanning patterns. In this lab the Kali host at 192.168.100.10 connected to every port on 192.168.100.20 within approximately 34 seconds, which is a textbook nmap scan signature that would also be visible to a network IDS such as Snort or Suricata.

Remediation

MITRE ATT&CK Mapping

TA0043 Reconnaissance, T1046 Network Service Discovery, T1595 Active Scanning.

Screenshots with captions

Full nmap scan output showing 23 open ports on Metasploitable2
Full nmap scan output showing 23 open ports on Metasploitable2.
nmap service detection on port 21 showing vsftpd 2.3.4 with anonymous FTP login allowed
Port 21 vsftpd 2.3.4 with anonymous FTP login allowed.
nmap output on port 23 showing Linux telnetd running an unencrypted remote access service
Port 23 Telnet — unencrypted remote access protocol.
nmap output for ports 1099 and 1524 showing Java RMI registry and Metasploitable root bindshell
Port 1099 Java RMI and Port 1524 open root bindshell.
nmap output for ports 3306 and 5432 showing MySQL and PostgreSQL databases exposed to the network
Ports 3306 MySQL and 5432 PostgreSQL exposed directly to network.