惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

V
Vulnerabilities – Threatpost
月光博客
月光博客
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
美团技术团队
Last Week in AI
Last Week in AI
Jina AI
Jina AI
P
Privacy International News Feed
有赞技术团队
有赞技术团队
WordPress大学
WordPress大学
宝玉的分享
宝玉的分享
T
Tenable Blog
阮一峰的网络日志
阮一峰的网络日志
P
Proofpoint News Feed
T
Tailwind CSS Blog
Apple Machine Learning Research
Apple Machine Learning Research
P
Privacy & Cybersecurity Law Blog
人人都是产品经理
人人都是产品经理
S
Schneier on Security
Google DeepMind News
Google DeepMind News
爱范儿
爱范儿
C
Cisco Blogs
K
Kaspersky official blog
C
Cybersecurity and Infrastructure Security Agency CISA
Hugging Face - Blog
Hugging Face - Blog
博客园_首页
O
OpenAI News
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
IT之家
IT之家
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
酷 壳 – CoolShell
酷 壳 – CoolShell
T
Tor Project blog
博客园 - 【当耐特】
腾讯CDC
V
V2EX
A
Arctic Wolf
Webroot Blog
Webroot Blog
S
Securelist
小众软件
小众软件
大猫的无限游戏
大猫的无限游戏
D
Darknet – Hacking Tools, Hacker News & Cyber Security
博客园 - 三生石上(FineUI控件)
The GitHub Blog
The GitHub Blog
量子位
J
Java Code Geeks
博客园 - 叶小钗
S
SegmentFault 最新的问题
Project Zero
Project Zero
www.infosecurity-magazine.com
www.infosecurity-magazine.com
Scott Helme
Scott Helme
Cyberwarzone
Cyberwarzone

Black Hills Information Security, Inc.

Bad Habits: An ANTISOC Operation Same Problem, Different Angles: When Red Team and Blue Team Actually Talk to Each Other How to Identify and Exploit New Vulnerabilities Swapper – A Pure Regex Match/Replace Burp Extension A Practical Guide to BloodHound Data Collection Network Engineering Basics Signed, Trusted, and Abused: Proxy Execution via WebView2 Getting Started In Pentesting – Advice From The BHIS Pentest Lead Cloud Security: Tips and Resources for Securing the Cloud Lessons From A Chatbot Incident How to Lead Effective Tabletops Understanding GRC: How to Navigate Risks and Compliance Standards The “P” in PAM is for Persistence: Linux Persistence Technique Malware Analysis: How to Analyze and Understand Malware OSINT: How to Find, Use, and Control Open-Source Intelligence What to Do with Your First Home Lab When the SOC Goes to Deadwood: A Night to Remember Social Engineering and Microsoft SSPR: The Road to Pwnage is Paved with Good Intentions Common Cyber Threats Finding the Right Penetration Testing Company Deceptive-Auditing: An Active Directory Honeypots Tool The Curious Case of the Comburglar How to Set Smart Goals (That Actually Work For You) Inside the BHIS SOC: A Conversation with Hayden Covington Abusing Delegation with Impacket (Part 3): Resource-Based Constrained Delegation Why You Got Hacked – 2025 Super Edition Abusing Delegation with Impacket (Part 2): Constrained Delegation Abusing Delegation with Impacket (Part 1): Unconstrained Delegation GoSpoof – Turning Attacks into Intel Model Context Protocol (MCP) Bypassing WAFs Using Oversized Requests Getting Started with AI Hacking Part 2: Prompt Injection Wrangling Windows Event Logs with Hayabusa & SOF-ELK (Part 2) DomCat: A Domain Categorization Tool Wrangling Windows Event Logs with Hayabusa & SOF-ELK (Part 1) Microsoft Store and WinGet: Security Risks for Corporate Environments Default Web Content MailFail Commonly Abused Administrative Utilities: A Hidden Risk to Enterprise Security Stop Spoofing Yourself! Disabling M365 Direct Send Bypassing CSP with JSONP: Introducing JSONPeek and CSP B Gone Offensive Tooling Cheatsheets: An Infosec Survival Guide Resource DNS Triage Cheatsheet GraphRunner Cheatsheet Burp Suite Cheatsheet Impacket Cheatsheet Wireshark Cheatsheet Hashcat Cheatsheet EyeWitness Cheatsheet Netcat (nc) Cheatsheet Hunt for Weak Spots in Your Wireless Network with Airodump-ng from the Aircrack-ng Suite Detecting ADCS Privilege Escalation Vulnerability Scanning with Nmap Getting Started with NetExec: Streamlining Network Discovery and Access How to Use Dirsearch Augmenting Penetration Testing Methodology with Artificial Intelligence – Part 3: Arcanum Cyber Security Bot How to Design and Execute Effective Social Engineering Attacks by Phone Abusing S4U2Self for Active Directory Pivoting Why Use a Macro Pad? Espanso: Text Replacement, the Easy Way Caging Copilot: Lessons Learned in LLM Security Augmenting Penetration Testing Methodology with Artificial Intelligence – Part 2: Copilot Augmenting Penetration Testing Methodology with Artificial Intelligence – Part 1: Burpference Intercepting Traffic for Mobile Applications that Bypass the System Proxy How to Root Android Phones Communicating Security to the C-Suite: A Strategic Approach Offline Memory Forensics With Volatility Getting Started with AI Hacking: Part 1 Go-Spoof: A Tool for Cyber Deception How to Test Adversary-in-the-Middle Without Hacking Tools Canary in the Code: Alert()-ing on XSS Exploits How to Hack Wi-Fi with No Wi-Fi Why Your Org Needs a Penetration Test Program Burp Suite Extension: Copy For Light at the End of the Dark Web Wi-Fi Forge: Practice Wi-Fi Security Without Hardware Avoiding Dirty RAGs: Retrieval-Augmented Generation with Ollama and LangChain Gone Phishing: Installing GoPhish and Creating a Campaign 5 Things We Are Going to Continue to Ignore in 2025 John Strand’s 5 Phase Plan For Starting in Computer Security Questions From a Beginner Threat Hunter GRC for Security Managers: From Checklists to Influence AI Large Language Models and Supervised Fine Tuning Attack Tactics 9: Shadow Creds for PrivEsc w/ Kent & Jordan One Active Directory Account Can Be Your Best Early Warning Introduction to Zeek Log Analysis Indecent Exposure: Your Secrets are Showing Creating Burp Extensions: A Beginner’s Guide Pitting AI Against AI: Using PyRIT to Assess Large Language Models (LLMs) The Top Ten List of Why You Got Hacked This Year (2023/2024) ICS Hard Knocks: Mitigations to Scenarios Found in ICS/OT Backdoors & Breaches Intro to Data Analytics Using SQL Finding Access Control Vulnerabilities with Autorize The Detection Engineering Process Cyber Risk Lessons We Can Learn From Hurricane Preparedness Intro to Desktop Application Testing Methodology What Is Penetration Testing? Adversary in the Middle (AitM): Post-Exploitation Pentesting, Threat Hunting, and SOC: An Overview QEMU, MSYS2, and Emacs: Open-Source Solutions to Run Virtual Machines on Windows
Nmap Cheatsheet
BHIS · 2025-08-06 · via Black Hills Information Security, Inc.

, , , , ,

Written by Alireza Liaghat || Reviewed by Dale Hobbs

This blog is part of Offensive Tooling Cheatsheets: An Infosec Survival Guide Resource. You can learn more and find all of the cheatsheets HERE: https://www.blackhillsinfosec.com/offensive-tooling-cheatsheets/

Nmap Cheatsheet: PRINT-FRIENDLY PDF

Find the tool here: https://nmap.org/


Nmap is a powerful open-source tool commonly used by system/network administrators and security professionals to perform network discovery, security auditing, and basic vulnerability assessment. Nmap allows you to quickly identify live hosts, open ports, running services, operating systems, and potential security risks within a network. This cheatsheet provides a reference to essential Nmap commands, scanning techniques, and common use cases to help streamline your network reconnaissance and troubleshooting tasks.

The Nmap Formula

Nmap + Target + Type + Port + Detection + Timing + Scripts + Evasion

TARGET

What do you want to scan?

ExampleDescriptionUse Case
192.168.x.xScan the specified IP addressUsed when there is only one target IP address.
domain.comScan the specified domainUsed when there is only one target domain.
-iL target.txtScan from a list of host addressesUsed when searching a known range of hosts.
--uniqueScans each address only onceUsed in combination with lists. Avoids duplicate scans to speed up the scan.
-nNo DNS resolutionSpeeds up scanning by skipping reverse DNS resolution.

TYPE

How do you want to scan?

ExampleDescriptionUse Case
-sTFull TCP 3-Way Handshake ScanMost reliable scan. Use when not worried about firewalls.
-sS“Stealth” scan. Impartial 3-Way HandshakeDoes not establish a full handshake. “Dumb” firewalls will only see this as regular poor connection.
-sUScan using UDPPreferred for scanning DNS (53), SNMP (161), DHCP (67), TFTP (69), etc.

PORT

What port do you want to scan?

ExampleDescriptionUse Case
-p 80,443Scans only the comma-separated portsUseful for when scanning a host for a specific attack surface.
-p 1-65535Scans all possible portsUseful for all ports in use, including ephemeral (temporary) ports.

DETECTION

What do you want to detect?

ExampleDescriptionUse Case
-sVProbe for service/versionUseful for when mapping and identifying a network
--version-lightTry the most likely probes for detectionUseful for when mapping and identifying a network.
--version-allTry every available probe (max intensity)Useful for when mapping and identifying a network..
-OOS DetectionUseful for when mapping and identifying a network.

TIMING

How fast do you want to scan?

ExampleDescriptionUse Case
--max-rate 5Sends a maximum of 5 probes per secondLimits network traffic to avoid disruptions to the network.
--scan-delay 1Adds 1 second delay between probesLimits network traffic to avoid disruptions to the network.
--host-timeout 1Give up on a particular port after 1 secondLimits network traffic and useful for slow responding devices.

SCRIPTS

What additional scripts do you want?

ExampleDescriptionUse Case
--script=whoisSpoofs the source IP addressUsed when mapping a network.
--scripts=smb-enum-sharesAdds random data to packetsIdentifies SMB shares that might be exposed.
--script=vulnersUses a proxy to scanIdentifies known/unpatched vulnerabilities in a network.

EVASION

How sneaky do you want to be?

ExampleDescriptionUse Case
-spoof-mac 00:0C:29:6F:F3:6BSpoofs the source MAC addressUseful for when the network switch restricts connectivity using MAC addresses
S 192.168.1.1Spoofs the source IP addressUseful for when the network switch restricts connectivity using IP addresses
--data-length 5Adds random data to packetsUseful for when trying to camouflage the network traffic caused by the scan
--proxies 192.168.5.5Uses a proxy to scanUseful for when navigating a scan through an IP-based filter

Example formula of a slow and thorough search:

nmap 192.168.10.50 -sT -p1-65535 -version-light -max-rate 5 --script=vulners -S 192.168.1.1 

Common Port States

open: An application is actively accepting TCP connections or UDP datagrams on this port.
closed:The port is accessible. Nmap probes received a response but was indicated that there is no application listening.
filtered:Nmap cannot determine if the port is open. This could be caused by firewalls dropping packets or by network congestion.


Explore the Infosec Survival Guide and more… for FREE!

Get instant access to all issues of the Infosec Survival Guide, as well as content like our self-published infosec zine, PROMPT#, and exclusive Darknet Diaries comics—all available at no cost.

You can check out all current and upcoming issues here: https://www.blackhillsinfosec.com/prompt-zine/