Nmap: reading a map of hosts and ports
Nmap answers which machines respond and which services are willing to talk. This lesson is how to read that answer and what a defender does with it.
Diagram
From a scoped map to a reachability change
Step 1 of 4
Question
Which hosts answered, from this vantage point, inside the written range?
# Question # Which hosts answered, from this vantage point, inside # the written range?
The example on the open step is one illustration, or the fix you can paste into an application you own.
The question the tool is for
Nmap is a network mapper. You point it at an address range you are allowed to examine, and it reports hosts that answer, ports that accept a connection, and often a guess at the service and version listening there. That is reconnaissance. On a network you administer or were hired to assess, it is how you find the administration page that was never meant to be reachable, or the database that is listening on a routable address.
On a network you do not own, the same activity is an unsolicited probe. The lab rule does not change because the tool is famous. The scope names the ranges. If the range is not written down, you do not map it.
What the states mean
Nmap prints six port states, not four. Open means something accepted the conversation. Closed means the host answered and refused. Filtered means a filter dropped or rejected the probe, so you cannot tell whether a service is listening. Unfiltered means the host was reachable but this scan did not decide between open and closed. The report writes the undecided pairs as open|filtered and closed|filtered. Open, closed, and filtered are the three you will explain most often. A long list of open ports on a laptop is a different story from a single filtered result on a hardened server.
Service and version guesses are guesses. They come from how the service spoke, not from a signed manifest. Treat them as a lead. Confirm with the owner’s inventory before you write “this host runs that exact build” in a finding.
Host 10.10.10.20 22/tcp open ssh 80/tcp open http 443/tcp open https 3306/tcp open mysql 5432/tcp filtered postgresql
How to read a result like this
The sample above is a single lab host. SSH, web, and a database are reachable from the machine that ran the map. Postgres is hidden behind a filter. The interesting line for most assessments is the database: a data store that accepts connections from the same network as the web tier is a trust decision. It may be correct inside a private subnet and a serious mistake on a public address.
Write the finding in those terms. Asset, who can reach the port, what data sits behind it, and whether that exposure matches the design. “Port 3306 is open” is an observation. “Customer records are reachable from the office network without a second hop or a private link” is a finding, if that is what the owner confirmed.
What changes because of the map
Defenders run the same class of discovery on a schedule and diff it against last week. A new open port is a change-control event. Management interfaces belong on a network that is not the public internet, with the same identity you would require for a cloud console. Databases accept connections from the application tier, not from the world.
The browser lab does not run Nmap against anything. When you practice the tool, use a range whose rules allow mapping, or hosts you own. Bring the output back to this way of reading it: states, reachability, and the data behind the port.
Check yourself
Recognition and the fix. Nothing here is a procedure.
The report says open|filtered. What do you write?
Go deeper
Specific techniques, exercises, and glossary cards for this topic.