mythic-mcp
mythic-mcp
将 Mythic C2 框架暴露为 MCP 服务器,使 LLM(Claude 等)能够以对话方式操作代理、下发任务和查询平台数据。
功能
代理管理 — 列出所有活跃回调的详细信息,查看单个代理,杀死代理,更改休眠定时器
任务执行 — shell 命令、文件读取/下载/上传、mimikatz、make_token,以及任何 Mythic 命令的通用调度器
平台数据 — 凭据存储、工件日志、事件日志、文件浏览器、载荷列表、C2 配置文件状态
结构化响应 — 每个工具返回
{"status":"ok","data":...}或{"status":"error","message":...},便于 LLM 可靠解析内置提示 —
start_pentest和start_recon提示模板
Related MCP server: caldera-mcp
要求
Python 3.10+
uv 包管理器
运行中的 Mythic 服务器(v3.x+)
安装
git clone <this-repo>
cd mythic-mcp
uv sync运行
位置参数
uv run main.py <username> <password> [host] [port]uv run main.py mythic_admin mythic_admin_password localhost 7443环境变量
export MYTHIC_USERNAME=mythic_admin
export MYTHIC_PASSWORD=mythic_admin_password
export MYTHIC_HOST=localhost
export MYTHIC_PORT=7443
uv run main.py不使用 TLS
uv run main.py mythic_admin password localhost 7443 --no-ssl如果服务器静默启动且无输出,则表示正在工作——它在标准输入上等待 MCP 消息。
连接到 Claude Desktop
找到配置文件:
操作系统 | 路径 |
Linux |
|
macOS |
|
首先获取 uv 路径:
which uv在 mcpServers 下添加条目:
{
"mcpServers": {
"mythic_mcp": {
"command": "/home/user/.local/bin/uv",
"args": [
"--directory",
"/path/to/mythic-mcp",
"run",
"main.py"
],
"env": {
"MYTHIC_USERNAME": "mythic_admin",
"MYTHIC_PASSWORD": "mythic_admin_password",
"MYTHIC_HOST": "localhost",
"MYTHIC_PORT": "7443"
}
}
}
}完全退出并重新启动 Claude Desktop。一旦服务器连接,聊天界面中的工具图标将列出所有已注册的工具。
工具
代理 / 回调管理
工具 | 描述 |
| 列出所有活跃回调的详细信息(操作系统、架构、PID、IP、休眠、进程、载荷类型等) |
| 按显示 ID 获取单个代理的详细信息 |
| 在 Mythic 中将代理标记为不活跃 |
| 更改休眠间隔(秒)和抖动(%) |
任务执行
工具 | 描述 |
| 通过代理的默认解释器运行 shell 命令 |
| 从目标读取文件(使用 |
| 下载文件并以 base64 格式返回 |
| 将 base64 编码的文件上传到目标 |
|
|
| 运行 mimikatz(例如 |
| 通用调度器 — 按名称调用任何 Mythic 命令 |
平台数据
工具 | 描述 |
| Mythic 凭据存储中的所有凭据 |
| 工件日志(文件、注册表键、创建的进程) |
| 操作事件日志 |
| 目标上目录的文件浏览器条目 |
| 所有未删除的载荷及其构建状态和 C2 配置文件 |
| 所有 C2 配置文件及其运行状态 |
提示
提示 | 描述 |
| 引导 Claude 模拟特定威胁行为者以实现目标 |
| 引导 Claude 在所有活跃代理上执行初始侦察 |
在 Claude 中的使用示例
Use the start_recon prompt.List all active agents, then run whoami on agent 1.Download /etc/passwd from agent 2 and show me its contents.Run mimikatz sekurlsa::logonpasswords on agent 3.Use execute_command to run 'ps' on agent 1 with parameters {"host": "."}.架构
Claude Desktop
│ MCP stdio
▼
main.py (FastMCP tools + prompts)
│
▼
lib/mythic_api.py (MythicAPI class)
├─ mythic Python library → Mythic GraphQL/REST API
└─ httpx (raw GraphQL) → Mythic GraphQL endpoint所有任务调用使用 asyncio.wait_for 并设置 60 秒超时。GraphQL 请求跳过 TLS 验证(verify=False)以处理 Mythic 的自签名证书。
环境变量参考
变量 | 默认值 | 描述 |
| — | Mythic 操作员用户名(必填) |
| — | Mythic 操作员密码(必填) |
|
| Mythic 服务器主机名或 IP |
|
| Mythic 服务器端口 |
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- MIT
- AlicenseAqualityDmaintenanceConnects MCP-compatible AI clients to a MITRE Caldera adversary emulation platform, enabling natural language construction of attack scenarios, agent inspection, and operation management.18Apache 2.0
- Alicense-qualityDmaintenanceA full-featured MCP server providing seamless access to CustomGPT.ai APIs, enabling agent and conversation management through MCP-compatible clients.5MIT
- Alicense-qualityDmaintenanceExposes internal tools from agent harnesses (Claude Code, Codex, etc.) as a standard MCP server by intercepting LLM API calls.1MIT
Related MCP Connectors
MCP server for Pentest-Tools.com: run scans, manage findings and reports via your preffered LLM.
MCP server exposing the Backtest360 engine API as tools for AI agents.
MCP server for Argo RPG Platform — connects AI assistants to campaign data via OAuth2
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/kyawthiha7/mythic-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server