⌖ Nmap — scanning reference

Hackbydoing Academy cheat sheet · nmap · recon · scanning

Core scans

nmap -sn 192.168.1.0/24Host discovery only (ping sweep) — who is alive
nmap <ip>Top-1000 TCP ports on one host
nmap -sV <ip>Version detection — grab banners, name the services
nmap -O <ip>OS fingerprinting (needs root for full effect)
nmap -p- <ip>ALL 65,535 ports (slow, thorough)
nmap -p 22,80,443 <ip>Specific ports only
nmap -sU <ip>UDP scan (DNS, SNMP, DHCP live here — often forgotten)
nmap -A <ip>Aggressive: versions + OS + scripts + traceroute

Reading the output

openSomething is listening and answering — this is attack surface
closedThe host answered "nothing here" — the host is alive
filteredA firewall ate the probe — no answer at all
The banner is the prizeProduct + version → search it against known CVEs (vulnerability analysis)
Defender's noteScan yourself before someone else does; close or firewall anything you can't explain

Free from the Hackbydoing Academy — the game that teaches real cybersecurity, attack and defense, on simulated networks. Play free at hackbydoing.com · Print this page (Ctrl/Cmd+P) for a clean paper copy.