
pawelkozy/mcp-breach-to-fix-labs 是从 https://github.com/pawelkozy/mcp-breach-to-fix-labs. 导入的 MCP 服务器候选
概览
pawelkozy/mcp-breach-to-fix-labs 是从 https://github.com/pawelkozy/mcp-breach-to-fix-labs. 导入的 MCP 服务器候选
概述(AI 翻译)
MCP 破解修复实验室
十个模型上下文协议(MCP)挑战的实践实验室,重现自真实CVE和公开事件报告。我用Cursor/Claude端到端运行过每个漏洞利用,所以步骤不是理论上的——它们是助手们遵循的工具调用。每个场景都有两种模式发布:
- 易受攻击 - 可被故意利用的实现,可在Cursor/Claude桌面端到端重现。
- Secure - 强化实现,配备防御纵深控制以阻止攻击。
这些实验室都经过了Claude/Cursor的全面实战测试,确保了精确的漏洞利用/缓解流程可复现。
每个挑战都包含Docker服务、FastMCP服务器、夹具和截图,证明漏洞确实有效——没有理论上的说明。
挑战目录
| # | 挑战 | 剧情亮点 |
|---|---|---|
| 01 | CRM 混乱的副手 | 共享 CRM 令牌 + 可预测的 ID 会泄露其他租户的记录。安全版本对每个租户的凭证范围进行范围。 |
| 02 | 文件系统前缀绕过(CVE-2025-53110) | 朴素的startswith路径检查与规范路径强制。 |
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
MCP Breach-to-Fix Labs
Hands-on lab of ten Model Context Protocol (MCP) challenges reproduced from real CVEs and public incident reports. I’ve run every exploit end-to-end with Cursor/Claude, so the steps aren’t theoretical—they’re the exact tool calls the assistants followed. Every scenario ships in two modes:
- Vulnerable - intentionally exploitable implementation you can reproduce end-to-end in Cursor/Claude Desktop.
- Secure - hardened implementation with defense-in-depth controls that block the attack.
These labs were fully battle-tested with Claude/Cursor, ensuring the exact exploit/mitigation flow is reproducible.
Each challenge includes Docker services, FastMCP servers, fixtures, and screenshots that prove the exploit really runs—no theoretical write-ups.
Challenge Catalog
| # | Challenge | Scenario Highlights |
|---|---|---|
| 01 | CRM Confused Deputy | Shared CRM token + predictable IDs leak other tenants’ records. Secure version scopes credentials per tenant. |
| 02 | Filesystem Prefix Bypass (CVE-2025-53110) | Naive startswith path check vs. canonical path enforcement. |
| 03 | Hidden Instructions in Tool Responses | Malicious tool responses inject hidden instructions that redirect WhatsApp messages; secure build sanitizes responses. |
| 04 | Xata Read-Only Bypass | Multi-statement SELECT; attacker appends DELETE to mutate data. Secure build uses sqlparse to enforce single statements. |
| 05 | News Prompt Exfiltration | Malicious article tells the agent to dump config + email it back. Secure build sanitizes remote HTML and gates tools. |
| 06 | Log Poisoning Incident Response | SOC “instructions” inside logs coerce the agent to rotate secrets to attacker-controlled values. Secure build strips directives & blocks sensitive tickets. |
| 07 | Classic SQL Injection (Stored Prompt) | Ticketing app stores malicious prompts via SQLi; secure build parameterizes. |
| 08 | Git Command Injection (GHSA-3q26-f695-pp76) | git init helper shells out with unsanitized repo names; secure uses execFile / allowlist. |
| 09 | GitHub Public Issue Injection | Public issue text tricks MCP to leak private repo data; secure build sanitizes + scopes tokens. |
| 10 | Tool Description Poisoning | Repello.ai-style “rug pull” where tool metadata mutates after approval to exfiltrate SSH keys; secure build freezes descriptions. |
Each challenge stores proof captures under challenges/-/screenshots/ or README for quick reference.
Getting Started
New to MCP? See the Setup Guide for detailed instructions on connecting Cursor, Claude Desktop, or MCP Inspector to the challenge servers.
Prerequisites
- Docker & Docker Compose
- Python 3.10+ (for local execution)
- Cursor or Claude Desktop (recommended for exploits)
Quick Start with Docker
Every challenge has vulnerable and secure Docker services:
# Example: Run the Git Command Injection vulnerable server
安装
This server does not publish a one-line install command.
Open the repository installation guide 新手?先看 mcpskill.org 教程 →