Back

Lesson 10: Output and Reporting

Master output formats and create professional scan reports

1 / 3

NMAP Output Formats and Options

NMAP provides multiple output formats to suit different needs, from human-readable reports to machine-parseable data for automated processing and integration with other tools.

Standard Output Formats

-oN
Normal Output
Human-readable format, same as terminal output
Best for: Reports, documentation, manual review
nmap -oN scan_results.txt target
-oX
XML Output
Structured XML format for parsing and automation
Best for: Tool integration, databases, web applications
nmap -oX scan_results.xml target
-oG
Greppable Output
One line per host, easy to parse with grep/awk
Best for: Shell scripting, quick analysis, filtering
nmap -oG scan_results.gnmap target
-oS
Script Kiddie
Deprecated "leet" format (rarely used)
Best for: Legacy support only
nmap -oS scan_results.leet target
All Formats Output (-oA):
nmap -oA comprehensive_scan target
Creates three files: comprehensive_scan.nmap, comprehensive_scan.xml, comprehensive_scan.gnmap
Most convenient option for comprehensive documentation

Sample Normal Output

Starting Nmap 7.94
Nmap scan report for 192.168.1.100
Host is up (0.00045s latency).
PORT STATE SERVICE VERSION
22/tcp open ssh OpenSSH 8.2p1
80/tcp open http Apache 2.4.41
443/tcp open ssl/http Apache 2.4.41
Nmap done: 1 IP (1 host up) scanned

Sample Greppable Output

# Nmap 7.94 scan initiated
Host: 192.168.1.100 () Status: Up
Host: 192.168.1.100 () Ports:
22/open/tcp//ssh//OpenSSH 8.2p1/,
80/open/tcp//http//Apache 2.4.41/,
443/open/tcp//ssl|http//Apache/
# Nmap done - 1 IP scanned