# Pentest Tools

> Active penetration testing toolchain. Covers information gathering, port scanning, vulnerability scanning, web exploitation, SQL injection, directory brute-forcing, password cracking, and similar scenarios. Exposes 20+ security tools to AI agents through an MCP server (pentestMCP / mcp-security-hub). Trigger keywords: penetration testing, port scanning, Nmap, vulnerability scanning, Nuclei, SQL injection, SQLMap, directory brute-forcing, FFUF, password cracking, Hashcat, information gathering, subdomain, web exploitation, ZAP, Burp.

- Skill: `dangeroussong/pentest-tools` (Agent Skill, multi-file: 21 files)
- Install (CLI): `npx get-skill add dangeroussong/pentest-tools`
- Raw SKILL.md: https://api.skillmd.com/api/skills/dangeroussong/pentest-tools/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Data & Analytics
- Author: DangerousSONG (https://skillmd.com/u/dangeroussong)
- Updated: 2026-11-19
- Page: https://skillmd.com/skills/dangeroussong/pentest-tools

---


## ACTION REQUIRED (execute immediately after reading)

1. `NOW`: Read `../field-journal/precedent-pentest.md` — confirm that this skill's operations are authorized routine operations
2. `NOW`: Confirm that **scope.md** exists and that `auth.status=granted` and `network_profile` are valid (see `../ops/scope-contract.md`). If scope is missing, run `case-init.ps1` and stop until the user grants authorization; **never** add `-AuthGranted` automatically
3. `NOW`: Confirm whether the current task falls within this skill's scope of applicability
4. `NEXT`: Read `../tool-index.md` and verify tool availability and actual paths
5. `NEXT`: call bootstrap when a tool is missing; do not guess paths
6. `ACT`: During recon, prefer `references/recon-pipeline.md` (CF browser headers / Windows nmap / curl `--globoff`); append each batch of results to `timeline.md`; write Evidence for candidates with `../scripts/append-evidence.ps1` (a hit is not the same as verified)
7. `ACT`: Modern web/lab client-side surfaces (DOM XSS / prototype pollution / agent-browser) → `references/client-side-lab-playbook.md`; even if you fail to break through, record the observed Evidence and the failure latch

# Pentest Tools
- 攻击大类:C09 Web应用漏洞利用

## Scope of Applicability

Use this skill when the task falls into the following scenarios:

- Target information gathering (port scanning, subdomain enumeration, service identification)
- Vulnerability scanning (web vulnerabilities, CVE detection, misconfigurations)
- Web exploitation (SQL injection, XSS, SSRF, directory brute-forcing)
- Password cracking (hash cracking, dictionary attack)
- Network penetration (service exploitation, lateral movement support)

### Division of Labor with Other Skills

| Scenario | What to Use |
|------|--------|
| Active scanning/attacking (Nmap/Nuclei/SQLMap) | **This skill** |
| Reverse engineering binaries | `ida-reverse/` or `radare2/` |
| Front-end JS signature reverse engineering | `js-reverse/` |
| Browser/desktop automation | `browser-automation/` |
| CTF competitions (comprehensive) | `CTF-Sandbox-Orchestrator/` |

Simple check:
- Need to "scan the target, find vulnerabilities, exploit vulnerabilities" → this skill
- Need to "analyze the internal logic of a program" → a reverse engineering skill
- Need to "operate a browser/desktop" → browser-automation

---

## Tool Matrix

### Information Gathering

| Tool | Purpose | Typical Command |
|------|------|---------|
| **Nmap** | Port scanning, service identification, OS detection | `nmap -sV -sC -O target` |
| **Masscan** | Large-scale fast port scanning | `masscan -p1-65535 target --rate=1000` |
| **Subfinder** | Subdomain enumeration | `subfinder -d target.com` |
| **httpx** | HTTP probing, liveness detection | `httpx -l urls.txt -status-code` |

### Vulnerability Scanning

| Tool | Purpose | Typical Command |
|------|------|---------|
| **Nuclei** | Template-based vulnerability scanning (CVE/misconfiguration/exposure) | `nuclei -u target -t cves/` |
| **ZAP** | Web application security scanning | Invoked through the API or MCP |
| **Nikto** | Web server vulnerability scanning | `nikto -h target` |

### Web Exploitation

| Tool | Purpose | Typical Command |
|------|------|---------|
| **SQLMap** | SQL injection automation | `sqlmap -u "url?id=1" --batch --dbs` |
| **FFUF** | Directory/parameter brute-forcing | `ffuf -u target/FUZZ -w wordlist.txt` |
| **Gobuster** | Directory/subdomain brute-forcing | `gobuster dir -u target -w wordlist` |
| **XSStrike** | XSS detection | `xsstrike -u "url?param=test"` |

### Password Cracking

| Tool | Purpose | Typical Command |
|------|------|---------|
| **Hashcat** | GPU hash cracking | `hashcat -m 0 hash.txt wordlist.txt` |
| **John the Ripper** | CPU hash cracking | `john --wordlist=rockyou.txt hash.txt` |
| **Hydra** | Online brute force | `hydra -l admin -P pass.txt target ssh` |

### Exploitation Frameworks

| Tool | Purpose | Description |
|------|------|------|
| **Metasploit** | Exploitation framework | Requires separate installation, large footprint |
| **Impacket** | Windows protocol exploitation (SMB/WMI/Kerberos) | `pip install impacket` |

---

## MCP Backend Selection

This skill supports two MCP backends; pick either one:

### Option A: pentestMCP (recommended, one-click Docker)

- **Project**: https://github.com/ramkansal/pentestmcp
- **Features**: 20+ tools packaged into a single Docker container, exposed directly by the MCP server
- **Tools**: Nmap, Nuclei, ZAP, SQLMap, FFUF, Nikto, Gobuster, Subfinder, httpx, etc.
- **Installation**:

```bash
# Pull and run
docker pull ramkansal/pentestmcp
docker run -d -p 8080:8080 ramkansal/pentestmcp

# Or build locally
git clone https://github.com/ramkansal/pentestmcp.git
cd pentestmcp
docker build -t pentestmcp .
docker run -d -p 8080:8080 pentestmcp
```

- **MCP registration**:

```json
{
  "mcpServers": {
    "pentest": {
      "url": "http://localhost:8080/mcp"
    }
  }
}
```

### Option B: mcp-security-hub (modular)

- **Project**: https://github.com/FuzzingLabs/mcp-security-hub
- **Features**: each tool runs as an independent MCP server, enabled on demand
- **Tools**: Nmap, Ghidra, Nuclei, SQLMap, Hashcat
- **Installation**: follow the README of each submodule

### Option C: Single-tool MCP (lightest)

If you only need one tool:

| Tool | MCP Project | Installation |
|------|---------|------|
| Nmap | [nmap-mcp-server](https://github.com/PhialsBasement/nmap-mcp-server) | npm |
| Nuclei | [nuclei-mcp](https://github.com/addcontent/nuclei-mcp) | npm |
| SQLMap | mcp-security-hub submodule | pip |

### Reqable MCP (local traffic capture and API workbench)

The Reqable desktop client can expose local traffic capture, API, breakpoint, and rules capabilities through the official [Reqable MCP Server](https://github.com/reqable/reqable-mcp-server). Install and start Reqable separately first, then register the MCP server:

```powershell
powershell -NoProfile -ExecutionPolicy Bypass -File skills\scripts\bootstrap-reverse.ps1 -Capability reqable-mcp -McpHostTarget Codex
```

Replace `Codex` with `Claude` or `Both` to select the corresponding client; when `-McpHostTarget` is omitted, no client global configuration is written.

The stdio configuration after registration is:

```json
{
  "mcpServers": {
    "reqable-mcp": {
      "command": "npx",
      "args": ["-y", "reqable-mcp-server@1.0.1", "--scope", "minimal"]
    }
  }
}
```

- Uses Reqable's local API by default; configure `--host`, `--port`, or `--scope minimal|all` per the official documentation when needed.
- `minimal` is the recommended default scope; `all` exposes more tools that can modify proxies, rules, environments, or saved data.
- Captured traffic, request replay, and rule modification still require the authorization and network restrictions defined in `scope.md`; registering the MCP server must never expand the target scope.

---

## Workflow

### Standard Penetration Testing Workflow

> **Important**: when running a penetration test, you must follow the autonomous loop framework in `references/pentest-loop.md`.
> That framework defines the complete risk gating, documentation standards, context compaction, and completion check mechanisms.

```text
1. Information gathering
   - Nmap port scanning → confirm open services
   - Subfinder subdomain enumeration → expand the attack surface
   - httpx liveness detection → filter out invalid targets

2. Vulnerability scanning
   - Nuclei template scan → quickly discover known vulnerabilities
   - ZAP/Nikto → deep web application scanning

3. Exploitation
   - SQLMap → SQL injection
   - FFUF → discover hidden paths/parameters
   - Manual verification → confirm exploitability

4. Post-exploitation (if within the authorized scope)
   - Privilege escalation
   - Lateral movement
   - Data exfiltration

5. Reporting
   - Invoke the docs-generator skill to produce the penetration testing report
```

### Fast Scan Workflow (results in 5 minutes)

```text
1. nmap -sV -sC target → ports + services
2. nuclei -u target -severity critical,high → high-risk vulnerabilities
3. If a web service is present → ffuf -u target/FUZZ -w common.txt → directories
4. Aggregate findings → decide the next step
```

---

## Notes

- **Authorization is mandatory** — all scanning/attacking operations must stay within the authorized scope
- **Control the scan rate** — avoid triggering WAF/IDS or taking the target down
- **Passive before active** — gather information first, then scan for vulnerabilities, and exploit last
- **Document every action** — record every command and result for the report
- **Do not automate blindly** — the AI should wait for confirmation at every critical step

---

## On-Demand Bootstrap

### Automation Capability Boundaries

| Tool | Auto-Installable | Installation Method | Description |
|------|-----------|---------|------|
| Nmap | ✓ | winget (`Insecure.Nmap`) | Windows build |
| Nuclei | ✓ | `go install` or GitHub Release | Requires Go, or download the binary directly |
| SQLMap | ✓ | `pip install sqlmap` or git clone | Python |
| FFUF | ✓ | GitHub Release | Go binary |
| SecLists | ✓ | GitHub Release ZIP | Comprehensive wordlists (essential for FFUF/Gobuster) |
| Hashcat | ✗ | Manual download | Requires GPU drivers |
| Metasploit | ✗ | Manual installation | Large footprint, Kali is recommended |
| pentestMCP (Docker) | ✗ | Requires Docker | `docker run ramkansal/pentestmcp` |
| Impacket | ✓ | `pip install impacket` | Python |
| ProxyCat | ✓ | `pip install proxycat` | Proxy pool middleware (prevents IP bans during batch scanning) |
| BurpSuite MCP | ✗ | Install from the BurpSuite extension marketplace | Requires BurpSuite Pro/Community |
| Reqable MCP | ✓ | `npx -y reqable-mcp-server@1.0.1` | The Reqable desktop client must be installed manually first |

### Bootstrap Strategy

1. If the user has Docker → recommend pentestMCP (one-click full toolkit)
2. If Docker is unavailable → install each tool individually as needed
3. Install Nmap + Nuclei + SQLMap first (covers 80% of scenarios)

### Manual Installation Guide

```markdown
⚠️ **Penetration testing tools are not installed**

**Recommended option (requires Docker)**:
docker pull ramkansal/pentestmcp
docker run -d -p 8080:8080 ramkansal/pentestmcp

**Lightweight option (install one by one)**:
- Nmap: winget install Insecure.Nmap
- Nuclei: go install -v github.com/projectdiscovery/nuclei/v3/cmd/nuclei@latest
- SQLMap: pip install sqlmap
- FFUF: download from https://github.com/ffuf/ffuf/releases

**Tell me once the installation is done and I will continue the current task.**
```

---

## Reference Resources

- [awesome-pentest](https://github.com/enaqx/awesome-pentest) — a comprehensive list of penetration testing tools with 25k+ stars
- [SecLists](https://github.com/danielmiessler/SecLists) — wordlist/payload collection (essential for FFUF/Gobuster)
- [PayloadsAllTheThings](https://github.com/swisskyrepo/PayloadsAllTheThings) — payloads for every type of vulnerability
- [HackTricks](https://book.hacktricks.wiki/) — the encyclopedia of penetration testing techniques
- [pentest-ai-agents](https://github.com/0xSteph/pentest-ai-agents) — 35 Claude Code penetration testing sub-agents (reference their prompt patterns)
- [Pentest Swarm AI](https://github.com/Armur-Ai/Pentest-Swarm-AI) — swarm-intelligence autonomous penetration testing framework (multi-agent collaboration, MCP server support)
- [ProxyCat](https://github.com/honmashironeko/ProxyCat) — proxy pool middleware (prevents IP bans during batch scanning)
- [planning-with-files](https://github.com/othmanadi/planning-with-files) — task planning skill (for loop testing)

### Reference Documents in This Skill

- `references/pentest-loop.md` — **core loop framework** (risk gating + documentation standards + context compaction)
- `references/recon-pipeline.md` — **authorized recon pipeline** (CF headers / nmap / Evidence)
- `references/client-side-lab-playbook.md` — **DOM XSS / prototype pollution / agent-browser** (lab client-side surfaces)
- `references/burpsuite-mcp-guide.md` — **complete BurpSuite MCP guide** (63 tools + 7 major use cases + AI prompt templates)
- `references/automation-loop-pattern.md` — automated loop testing pattern (lightweight version)
- `references/awesome-pentest-digest.md` — penetration testing tool digest quick reference
- `references/pentest-ai-agents-matrix.md` — 35-agent coverage matrix
- `payloads/` — custom payload directory (AI should prefer these)
- `templates/` — required penetration testing file templates (scope/rules/plan/findings/progress)

### src-hunter Vulnerability Hunting Knowledge Base

The `src-hunter/` directory contains a complete SRC/Bug Bounty vulnerability hunting methodology:

- **19 attack playbooks** (IDOR, RCE, XSS, SQLi, SSRF, OAuth, file upload, etc.)
- **305 structured payloads** + 263 WAF/EDR bypass steps
- **2,887 disclosed HackerOne High/Critical reports**
- **88,636 WooYun historical case statistics**
- **Chinese-vendor component fingerprints and default credentials**
- **CVSS 4.0 report templates**

How to use it: the AI automatically reads the corresponding playbook during the hunt phase and tests according to its flow.

See `src-hunter/SKILL.md` and `src-hunter/references/` for details.

---

## Routing Context

**Upstream Entry Points**: `skills/SKILL.md` (master control), `routing.md`
**Trigger condition**: the task requires actively scanning/attacking a target (port scanning, vulnerability detection, injection testing, etc.)
**Downstream Exit Points**:
- Web vulnerabilities discovered and requiring further analysis → `js-reverse/`
- Binary vulnerabilities discovered and requiring reverse engineering → `ida-reverse/` or `radare2/`
- Browser operation needed to verify vulnerabilities → `browser-automation/`
- Report generation after completion → `docs-generator/`

**Sibling related modules**: `CTF-Sandbox-Orchestrator/` (these tools are used for the Web/Pwn challenges in CTFs)


## Task Completion Self-Check (MUST pass before claiming completion)

- [ ] Did I execute every step in the workflow (rather than only reading it)?
- [ ] Did I use real tool paths based on `tool-index`?
- [ ] Did I produce reproducible evidence (commands / scripts / screenshots / reports)?
- [ ] Did I complete and write back the Checklist items required by RULES?

