NMAP  Cheat Sheet

A Quick Guide to mastering NMAP with Essential Tips and Commands

Say Hello to NMAP

An open-source tool for network discovery, port scanning, & vulnerability assessment, enabling users to identify open ports, & detect potential weaknesses in servers or networks.

1. -iL : Scans a target from a file. Example: nmap -iL text.txt          2. –exclude : Exclude the listed hosts.  Example: nmap -exclude 192.168.1.2

Target Specification

Scan Techniques

1. -sT : TCP Connect Scan  Example: nmap 192.168.1.1 -sT           2. -sW : TCP Window scan  Example: nmap 192.168.1.1 -sW

1. -Pn : Disables host discovery and allows port scan only.  Example: nmap 192.168.1.2-5 -Pn     2. -n : Disables DNS resolution.  Example: nmap 192.168.1.2 -n

Host Discovery

1. -p- : Scan all ports.          Example: nmap 192.168.1.9 -p-           2. –top-ports : Scans the top “x” ports. Example: nmap 192.168.1.9 -top-ports 1015

Port Specification

1. -sV : Helps in determining the version of the service.  Example: nmap 192.168.1.9 -sV   2. -A : Enables OS detection, version detection, & script scanning.  Example: nmap 192.168.1.8 -A

Service and Version Detection

1. –script : Wildcard scanning. Example: nmap 192.168.1.9 -script=http*           2. –script : Default scanning without intrusive scripts  Example: nmap 192.168.1.9 -script "not intrusive"

NSE Scripts

1. –mtu : Set the offset size yourself. Example: nmap 192.168.1.9 -mtu 32   2. –data-length : This adds random data to the sent packets. Example: nmap -data-length 200 192.168.1.9

Firewall / IDS Evasion and Spoofing

Dive into the world of NMAP and Improve your skills

Discover all tips, tricks, & shortcuts you need to boost your productivity & efficiency. Get access to the full Cheat Sheet & start learning today!

Step Up Your Game with InterviewBit Web Stories

Don't miss out on the chance to upskill yourself with IntervewBit's engaging web stories.