Scan Types
-sI <zombie host[:probeport]> Idel Scan
-sL List/DNS Scan
-sO IP Protocol Scan
-sP Ping Scan
-sR RPC Scan
-sU UDP Scan
-b<ftp relay host>: FTP bounce Scan
TCP Scan
-sT TCP Connect(default) Scan
-sM TCP Maimon Scan FIN/ACK
-sW TCP Window Scan
-sA TCP ACK Scan
-sS TCP SYN Scan
-sN TCP Null Scan
-sF TCP FIN Scan
-sX TCP XMAS Scan
Scan Options
-p <port range>
--scanflags <TCP flags>
-F Fast Scan
-r Ports Consecutively
-e <interface>
Ping Options (主机发现)
-R DNS resolution for all targets
-n No DNS resolution
--system-dns
-PN No Ping
-PO IP Protocol Ping
-PU [port list] UDP discovery probes to give ports
-PR ARP Ping
ICMP Ping
-PE ICMP echo request discovery probes
-PM ICMP Netmask request discovery probes
-PP ICMP timestamp request discovery probes
TCP Ping
-PS [port list] TCP SYN discovery probes to given ports (default: port 80)
-PA [port list] TCP ACK discovery probes to given ports (default: port 80)
MISC
Other Options
-6 Enable IPv6
--datadir custom NMAP data dir
--send-eth Use raw ethernet sending
--send-ip Send at raw IP level
--privilieged User is full privilieged(root/admin)
--interactive
-V Print version number
-h Help
Evade firewall/IDS/IPS
-f Use fragmented IP packages --mtu <VAL> Using the specified MTU
-D decoy1[,decoy2][,ME][,...]
-S <Spoof Source IP>
--data-length <val> Append random data to sent packets
-g/--source-port <port number>
--ttl <val> Set IPv4 TTL field in send packets
--randomize_hosts
--spoof_mac <MAC/prefix/vendor>
Timing
-T <Paranoid|Sneaky|Polite|Normal|Aggressive|Insane>
-T0 Paranoid, serial 300 sec wait (Avoiding IDS alerts)
-T1 Sneaky serial 15 sec wait (Avoiding IDS alerts)
-T2 Polite (serial 0.4 sec wait)
-T3 Parallel scan
-T4 Aggressive 300 sec timeout, 1.25sec/probe
-T5 Insane(Parallel, 75 sec timeout and 0.3 sec/probe)
--scan-delay <msec> Adjust delay between probes (evade IDS/IPS) --max-scan-delay <msec> Ajust delay between probes (evade IDS/IPS)
--initial_rtt_timeout (6000 msec default) --min_rtt_timeout (6000 msec default) --max_rtt_timeout (9000 msec default)
--host-timeout <milliseconds> Give up on target after this long
--min-hostgroup <numhosts> --max-hostgroup <numhosts>
--min-parallelism <numprobes> --max-parallelism <numprobes>
Input Options
--execludefile <filename>
--execlude <host1 [,host2]...>
-iR <num hosts> Choose random targets in NUM hosts
-iL [filename] Input from list
OS detection
-A OS version Detection
-O OS scan
--osscan-guess/--fuzzy
--osscan-limit
Service/Version Detection
-sV Version/Service Info Scanning
--version-intensity <level> set from 0(light) to 9(try all probes)
--version-light Limit to most likely probes (intensity 2)
--version_all Try every single probe (intensity 9)
--version_trace Show detailed version scan activity (for debugging)
--allports
Output Options
Output Layout
-oS Script kiddies
-oX XML
-oN Normal
-oA On three major formats
-oG Grepable
Detail and Debug
-d debug 1-9
--packet_trace
--iflist interface list
-v verbose output
Other
--stylesheet <path URL>
--resume
--append_output
--no_stylesheet
NMAP识别的6个端口状态
open(开放的)
closed(关闭的)
filtered(被过滤的)
unfiltered(未被过滤的)
open|filtered(开放或者被过滤的)
closed|filtered(关闭或者被过滤的)