Nmap Scanning Basics
Host Discovery
-sL nmap 192.168.1.1-3 -sL # Lists targets without scanning (useful for planning)
-sn nmap 192.168.1.1/24 -sn # Ping scan, disables port scanning (quick host check)
-Pn nmap 192.168.1.1-5 -Pn # Skips host discovery, assumes hosts are up (use for firewalled networks)
-PS nmap 192.168.1.1-5 -PS22-25,80 # TCP SYN discovery on specified ports (e.g., 22, 23, 24, 25, 80)
-PA nmap 192.168.1.1-5 -PA22-25,80 # TCP ACK discovery (bypasses some firewalls)
-PU nmap 192.168.1.1-5 -PU53 # UDP discovery on port 53 (common for DNS servers)
-PR nmap 192.168.1.0/24 -PR # ARP discovery for local networks (fast and reliable)
-n nmap 192.168.1.1 -n # Disables DNS resolution (speeds up scans)Target Specification
Scan Techniques
Port Specification
Timing and Performance
Service and Version Detection
OS Detection
Firewall / IDS Evasion and Spoofing
NSE (Nmap Scripting Engine) Scripts
Output Options
Scan Output Analysis & Tips
Best Practices
Last updated