A Comprehensive Tutorial of NMAP

A Comprehensive Tutorial of NMAP: An Open-Source Linux Command-Line Tool

What is Nmap?

Nmap is short for Network Mapper. It is an open-source Linux command-line tool that is used to scan IP addresses and ports in a network and to detect installed applications.

Nmap allows network admins to find which devices are running on their network, discover open ports and services, and detect vulnerabilities.

Why use Nmap?

There are a number of reasons why security pros prefer Nmap over other scanning tools.

First, Nmap helps you to quickly map out a network without sophisticated commands or configurations. It also supports simple commands (for example, to check if a host is up) and complex scripting through the Nmap scripting engine.


Basic scans

Scanning the list of active devices on a network is the first step in network mapping. There are two types of scans you can use for that:

  • Ping scan — Scans the list of devices up and running on a given subn > nmap -sp
  • Scan a single host — Scans a single host for 1000 well-known ports. These ports are the ones used by popular services like SQL, SNTP, apache, and others. > nmap scanme.nmap.org

Port scan commands

Stealth scan

  • Stealth scanning is performed by sending an SYN packet and analyzing the response. If SYN/ACK is received, it means the port is open, and you can open a TCP connection.

nmap -sS scanme.nmap.org

TCP Connect Scan

TCP scan in nmap is a technique to discover open TCP ports on a target system or network.

nmap -sT -p-/ -p0-65535 -vv ( target ip)

  • Using the -p param to scan for a single port

> nmap -p 973

  • A range of ports can be scanned by separating them with a hyphen.

> nmap -p 76–973

Verbose Output

The verbose output provides additional information about the scan being performed. It is useful to monitor step-by-step actions Nmap performs on a network, especially if you are an outsider scanning a client’s network.

nmap -v scanme.nmap.org

Version scanning

To do a version scan, use the ‘-sV’ command. Nmap will provide a list of services with their versions. Do keep in mind that version scans are not always 100% accurate, but it does take you one step closer to successfully getting into a system > nmap -sV scanme.nmap.org

OS Scanning

In addition to the services and their versions, Nmap can provide information about the underlying operating system using TCP/IP fingerprinting. Nmap will also try to find the system uptime during an OS scan. > nmap -sV scanme.nmap.org

Aggressive Scanning

Nmap has an aggressive mode that enables OS detection, version detection, script scanning, and traceroute. You can use the -A argument to perform an aggressive scan.

Aggressive scans provide far better information than regular scans. > nmap -A scanme.nmap.org

Scanning Multiple Hosts

You can scan multiple hosts through numerous approaches:

Write all the IP addresses in a single row to scan all of the hosts at the same time.

> nmap

Nmap Scripting Engine

NSE also has attack scripts that are used in attacking the network and various networking protocols.

Zen map

Zenmap is a graphical user interface for Nmap. It is a free and open-source software that helps you get up and running with Nmap.

How News4Hackers Can Help?

News4Hackers is a global news organization dedicated to providing informative and actionable articles on topics related to cybersecurity.  Furthermore, News4Hackers is dedicated to delivering current information to our audience regarding the latest advancements, methodologies, technologies, and cyber threats that aim to compromise organizations on a global scale.  In order to ensure that you are promptly informed of the latest technological advancements, our news organizers conscientiously monitor the market on a daily basis.

Additionally, it is critical to emphasize that Craw Security maintains a collaboration with News4Hackers, a reputable cybersecurity-focused organization, to offer enlightening analysis and perspectives on a multitude of significant countries, including India.  For additional information regarding their highly effective cybersecurity education programs or any other pertinent topic, please feel at liberty to reach out to them at the provided telephone number: +91-9513805401.


Top 10 VPNs to Use in 2024

Catch All Details Regarding Nessus: The Famous Cybersecurity Tool

Netcat — All You About This Exciting Cyber Security Tool

About Author

Leave a Reply

Your email address will not be published. Required fields are marked *

Open chat
Can we help you?