Mcpwn
Verified Safeby Teycir
Overview
Automated security testing framework for Model Context Protocol (MCP) servers, detecting RCE, path traversal, prompt injection, and protocol vulnerabilities.
Installation
python3 mcpwn.py --quick npx -y @modelcontextprotocol/server-filesystem /tmpEnvironment Variables
- ANTHROPIC_API_KEY
Security Notes
The tool is designed to generate and send malicious payloads to a target MCP server, which is its intended function. It uses `subprocess.Popen` to run the user-specified target server command, which is a standard approach for such tools. The `eval` pattern is found within a static payload for a deserialization test, and not used on uncontrolled input within the scanner's core logic. The tool's own code does not exhibit direct RCE, hardcoded secrets, or unintended network risks (it sets up listeners for OOB/SSRF detection as part of its testing functionality). It aims for 'Zero dependencies - pure Python stdlib', though older changelogs mention optional LLM-guided payload generation via an API key, which is not actively shown in the provided `payloads.py` or `MCPPentester.get_payloads` functions.
Similar Servers
mcp-scanner
Scans Model Context Protocol (MCP) servers, tools, prompts, and resources for security vulnerabilities, employing static analysis, YARA rules, Cisco AI Defense API, and LLM-based behavioral analysis.
mcp-watch
A comprehensive security scanner for Model Context Protocol (MCP) servers, detecting various vulnerabilities in their implementations.
mcp-zap-server
Orchestrates OWASP ZAP security scanning actions (spider, active scan, OpenAPI import, reporting) via the Model Context Protocol, enabling AI agents like Claude Desktop or Cursor to perform security testing.
mcp-server-fuzzer
Fuzzing and security testing of Model Context Protocol (MCP) servers across multiple transport protocols (HTTP, SSE, Stdio) to validate functionality, robustness, and protocol compliance.