Nmap is Linux command-line tool for network exploration and security auditing. This tool is generally used by hackers and cybersecurity enthusiasts and even by network and system administrators. It is used for the following purposes:
- Real time information of a network
- Detailed information of all the IPs activated on your network
- Number of ports open in a network
- Provide the list of live hosts
- Port, OS and Host scanning
The “-sn” flag is used with nmap to perform a ping scan, which sends ICMP requests to a target host or network to determine hosts is up or not.
nmap -sn
The "-sS" flag is used for TCP SYN Scan, Which is a stealthy and efficient method of scanning for open ports on a target system.
The “-sU” flag is used with nmap to perform a UDP scan, which allows the user to discover open UDP ports and services on a target system.
The “-p” flag is used with nmap to perform scan on a specific port or range of ports. ( In below case it will scan port 80,443 and 21 )
nmap -p 80 443 21