Skip to content
Skillpedia
Agents35k · #6199

scanning-network-with-nmap-advanced

Has your agent explore networks to find devices and services. It uses advanced techniques to discover vulnerabilities.

What it does

This tool helps map computer networks in an advanced way. It discovers which devices are connected, what services they offer, and if there are any known vulnerabilities, using techniques to avoid detection.

When to use it

  • ✓When mapping large enterprise networks (with permission).
  • ✓To find outdated or insecure software.
  • ✓When trying to discover security flaws in authorized tests.

Example of what to ask your AI

“Discover all devices on the 192.168.1.0/24 network and check for known vulnerabilities.”

Want more? Open the sections below.

How to use

The easiest way: copy the message below and paste it into Claude, ChatGPT, Cursor or any AI. It reads the skill and follows the instructions.

Skill link

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/scanning-network-with-nmap-advanced/SKILL.md

Ready-to-paste message

Use this skill to help me: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/scanning-network-with-nmap-advanced/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
How it works

The tool sends different types of network packets to target computers and analyzes the responses. It uses special scripts to look for flaws and techniques to disguise itself.

Installation

Easiest way: copy the skill link and paste it into Claude, ChatGPT or Cursor asking it to follow the instructions.

In the terminal (Claude Code, Codex, Cursor), in your project folder:

npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill scanning-network-with-nmap-advanced

Or download just the file:

curl -L https://raw.githubusercontent.com/mukul975/Anthropic-Cybersecurity-Skills/main/skills/scanning-network-with-nmap-advanced/SKILL.md -o SKILL.md
Technical content (original SKILL.md)

Original text by the author, straight from GitHub.

Scanning Network with Nmap Advanced Techniques

When to Use

  • Performing comprehensive asset discovery across large enterprise networks during authorized assessments
  • Enumerating service versions and configurations to identify outdated or vulnerable software
  • Bypassing firewall rules and IDS during authorized penetration tests using scan evasion techniques
  • Scripting automated vulnerability checks using the Nmap Scripting Engine (NSE)
  • Generating structured scan output for integration into vulnerability management pipelines

Do not use against networks without explicit written authorization, on production systems during peak hours without approval, or to perform denial-of-service through aggressive scan timing.

Prerequisites

  • Nmap 7.90+ installed (nmap --version to verify)
  • Root/sudo privileges for SYN scans, OS detection, and raw packet techniques
  • Written authorization specifying in-scope IP ranges and any excluded hosts
  • Network access to target ranges (VPN, direct connection, or jump host)
  • Familiarity with TCP/IP protocols and common port assignments

Workflow

Step 1: Host Discovery with Multiple Probes

Use layered discovery to find live hosts even when ICMP is blocked:

# ARP discovery for local subnet (most reliable on LAN)
nmap -sn -PR 192.168.1.0/24 -oA discovery_arp

# Combined ICMP + TCP + UDP probes for remote networks
nmap -sn -PE -PP -PS21,22,25,80,443,445,3389,8080 -PU53,161,500 10.0.0.0/16 -oA discovery_combined

# List scan to resolve DNS names without sending packets to targets
nmap -sL 10.0.0.0/24 -oN dns_resolution.txt

Consolidate results into a live hosts file:

grep "Host:" discovery_combined.gnmap | awk '{print $2}' | sort -t. -k1,1n -k2,2n -k3,3n -k4,4n > live_hosts.txt

Step 2: Port Scanning with Timing and Performance Tuning

# Full TCP SYN scan with optimized timing
nmap -sS -p- --min-rate 5000 --max-retries 2 -T4 -iL live_hosts.txt -oA full_tcp_scan

# Top 1000 UDP ports with version detection
nmap -sU --top-ports 1000 --version-intensity 0 -T4 -iL live_hosts.txt -oA udp_scan

# Specific port ranges for targeted assessment
nmap -sS -p 1-1024,3306,5432,6379,8080-8090,9200,27017 -iL live_hosts.txt -oA targeted_ports

Step 3: Service Version Detection and OS Fingerprinting

# Aggressive service detection with version intensity
nmap -sV --version-intensity 5 -sC -O --osscan-guess -p <open_ports> -iL live_hosts.txt -oA service_enum

# Specific service probing for ambiguous ports
nmap -sV --version-all -p 8443 --script ssl-cert,http-title,http-server-header <target> -oN service_detail.txt

Step 4: NSE Vulnerability Scanning

# Run vulnerability detection scripts
nmap --script vuln -p <open_ports> -iL live_hosts.txt -oA vuln_scan

# Target specific vulnerabilities
nmap --script smb-vuln-ms17-010,smb-vuln-ms08-067 -p 445 -iL live_hosts.txt -oA smb_vulns
nmap --script ssl-heartbleed,ssl-poodle,ssl-ccs-injection -p 443,8443 -iL live_hosts.txt -oA ssl_vulns

# Brute force default credentials on discovered services
nmap --script http-default-accounts,ftp-anon,ssh-auth-methods -p 21,22,80,8080 -iL live_hosts.txt -oA default_creds

Step 5: Firewall Evasion Techniques

# Fragment packets to evade simple packet inspection
nmap -sS -f --mtu 24 -p 80,443 <target> -oN fragmented_scan.txt

# Use decoy addresses to obscure scan origin
nmap -sS -D RND:10 -p 80,443 <target> -oN decoy_scan.txt

# Spoof source port as DNS (53) to bypass poorly configured firewalls
nmap -sS --source-port 53 -p 1-1024 <target> -oN spoofed_port_scan.txt

# Idle scan using a zombie host (completely stealthy)
nmap -sI <zombie_host> -p 80,443,445 <target> -oN idle_scan.txt

# Slow scan to evade IDS rate-based detection
nmap -sS -T1 --max-rate 10 -p 1-1024 <target> -oA stealth_scan

Step 6: Output Parsing and Reporting

# Convert XML output to HTML report
xsltproc full_tcp_scan.xml -o scan_report.html

# Extract open ports per host from grepable output
grep "Ports:" full_tcp_scan.gnmap | awk -F'Ports: ' '{print $1 $2}' > open_ports_summary.txt

# Parse XML with nmap-parse-output for structured data
nmap-parse-output full_tcp_scan.xml hosts-to-port 445

# Import into Metasploit database
msfconsole -q -x "db_import full_tcp_scan.xml; hosts; services; exit"

# Generate CSV for vulnerability management tools
nmap-parse-output full_tcp_scan.xml csv > scan_results.csv

Key Concepts

…

FAQ

Do I need permission to use this tool?

Yes, it is essential to have written authorization before scanning any network to avoid legal issues.

What is 'NSE'?

NSE stands for Nmap Scripting Engine. These are scripts that Nmap uses to perform more advanced tasks, such as searching for specific vulnerabilities.

Can I use this on any network?

No, only use it on networks where you have explicit and authorized permission to perform security testing.

Details

Original description by the author

Performs advanced network recon using Nmap''s Scripting Engine (NSE), timing controls, firewall/IDS evasion, and structured output parsing to discover hosts, enumerate service versions, detect vulnerabilities, and fingerprint OSes. Use during authorized penetration tests or enterprise asset-discovery assessments needing scan evasion, NSE vulnerability checks, or output fed into a vulnerability man

repo: mukul975/Anthropic-Cybersecurity-Skills

Popularity

GitHub stars
35k
Ranking position
#6199
License
Apache-2.0
Updated
8/31/2026

Is this skill useful?

0

Sign in to vote.

Comments

  • …

More skills from this repository

Similar skills