ArticleslgStudy

computer science

Nmap

Nmap is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Nmap rather than just read about it. In short: Nmap (Network Mapper) is a network scanner created by Gordon Lyon (also known by his pseudonym Fyodor Vaskovich). Nmap is used to discover hosts and services on a computer network by sending packets and analyzing the responses.

Nmap — main illustration
Nmap — illustration

Key takeaways

  • Nmap belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Nmap to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Nmap from memory before moving on to harder problems.

Reference excerpt

Nmap (Network Mapper) is a network scanner created by Gordon Lyon (also known by his pseudonym Fyodor Vaskovich). Nmap is used to discover hosts and services on a computer network by sending packets and analyzing the responses. Nmap provides a number of features for probing computer networks, including host discovery and service and operating system detection. These features are extensible by scripts that provide more advanced service detection, vulnerability detection, and other features. Nmap can adapt to network conditions including latency and congestion during a scan. Nmap started as a Linux utility and was ported to other systems including Windows, macOS, and BSD. It is most popular on Linux, followed by Windows.

Features Nmap features include:

Fast scan (nmap -F [target]) – Performing a basic port scan for fast result. Host discovery – Identifying hosts on a network. For example, listing the hosts that respond to TCP and/or ICMP requests or have a particular port open. Port scanning – Enumerating the open ports on target hosts. Version detection – Interrogating network services on remote devices to determine application name and version number. Ping Scan – Check host by sending ping requests. TCP/IP stack fingerprinting – Determining the operating system and hardware characteristics of network devices based on observations of network activity of said devices. Scriptable interaction with the target – using Nmap Scripting Engine (NSE) and Lua programming language. Nmap can provide further information on targets, including reverse DNS names, device types, and MAC addresses. Typical uses of Nmap:

Auditing the security of a device or firewall by identifying the network connections which can be made to, or through it. Identifying open ports on a target host in preparation for auditing. Network inventory, network mapping, maintenance and asset management. Auditing the security of a network by identifying new servers. Generating traffic to hosts on a network, response analysis and response time measurement. Finding and exploiting vulnerabilities in a network. DNS queries and subdomain search It has been cited in academic surveys as a foundational tool for network security reconnaissance.

User interfaces NmapFE, originally written by Kanchan, was Nmap's official GUI for Nmap versions 2.2 to 4.22. For Nmap 4.50 (originally in the 4.22SOC development series) NmapFE was replaced with Zenmap, a new official graphical user interface based on UMIT, developed by Adriano Monteiro Marques. Web-based interfaces exist that allow either controlling Nmap or analysing Nmap results from a web browser, such as IVRE.

Output Four different output formats are offered by Nmap. Everything is saved to a file except the interactive output. Text processing software can be used to modify Nmap output, allowing the user to customize reports.

Interactive presented and updated real time when a user runs Nmap from the command line. Various options can be entered during the scan to facilitate monitoring. XML a format that can be further processed by XML tools. It can be converted into a HTML report using XSLT. Grepable output that is tailored to line-oriented processing tools such as grep, sed, or awk. Normal the output as seen while running Nmap from the command line, but saved to a file. Script kiddie meant to be an amusing way to format the interactive output replacing letters with their visually alike number representations. For example, Interesting ports becomes Int3rest1ng p0rtz. This is known as Leet.

History Nmap was first published in September 1997, as an article in Phrack Magazine with source-code included. With help and contributions of the computer security community, development continued. Enhancements included operating system fingerprinting, service fingerprinting, code rewrites (C to C++), additional scan types, protocol support (e.g. IPv6, SCTP) and new programs that complement Nmap's core features. Major releases include:

Legal issues Nmap is a tool that can be used to discover services running on Internet connected systems. Like any tool, it could potentially be used for black hat hacking, as a precursor to attempts to gain unauthorized access to computer systems. However, Nmap is also used by security and systems administrators to assess their own networks for vulnerabilities (i.e. white hat hacking). System administrators can use Nmap to search for unauthorized servers, or for computers that do not conform to security standards.

In 2003 Supreme Court of Finland ruled that port scanning amounted to an attempted computer break-in, which was illegal under Finnish penal code at the time:In its ruling the Supreme Court stated that the defendant had systematically carried out port scanning operations to gather information for the purpose of unauthorised break-in to the bank's computer network. This amounted to an attempted computer break-in.

License Nmap was originally distributed under the GNU General Public License (GPL). In later releases, Nmap's authors added clarifications and specific interpretations to the license where they felt the GPL was unclear or lacking. For instance, Nmap 3.50 specifically revoked the license of SCO Group to distribute Nmap software because of their views on the SCO-Linux controversies. Starting with version 7.90, Nmap transitions to a new custom license NPSL, dual-licensing versions 7.90, 7.91, and 7.92 under both old and new licenses. Several Linux distributions consider the new license non-free.

… excerpt ends here. Continue reading the full article.

Illustrations

Nmap illustration
Nmap illustration
Nmap illustration
Nmap illustration

Worked examples

Example 1 — a first encounter with Nmap

Start with the simplest possible case. Write down what Nmap claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Nmap before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Nmap ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Nmap

In research
Nmap appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Nmap in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Nmap is common in secondary-school and first-year university syllabi. It links to neighbouring topics Cross-platform free software, Free network management software, Linux security software, so understanding it makes those chapters shorter.
In everyday life
Look for Nmap outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.

Affiliate

Preply — study more efficiently by working with a personal tutor. 50% off.

How to study Nmap in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Nmap means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Nmap out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Nmap in simple terms?

Nmap (Network Mapper) is a network scanner created by Gordon Lyon (also known by his pseudonym Fyodor Vaskovich). Nmap is used to discover hosts and services on a computer network by sending packets and analyzing the responses.

Why does Nmap matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Nmap?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Nmap.

Tags

  • Cross-platform free software
  • Free network management software
  • Linux security software
  • Lua (programming language)-scriptable software
  • Network analyzers
  • Pentesting software toolkits
  • Port scanners
  • Security testing tools
  • Software programmed in C++
  • Software programmed in Python
  • Unix network-related software

Keep exploring