Skip to content

kiki1e/IDABridge

Repository files navigation

IDABridge

批量导出 + 实时 MCP 交互,一个插件搞定。

Batch export (NO MCP) + Real-time MCP server, in one IDA plugin.


理念

模式 是什么 适合场景
Ctrl-Shift-E 批量导出 一键导出全部反编译代码为源文件 全局分析、离线阅读、CI/CD
Ctrl-Alt-M MCP 服务器 启动 HTTP JSON-RPC 服务,AI 实时查询 深度追踪、交互式逆向、修改 IDB

两个模式互补,可同时运行。

安装

1. 复制到 IDA 插件目录

Windows:

%APPDATA%\Hex-Rays\IDA Pro\plugins\

Linux/macOS:

~/.idapro/plugins/
# 一键安装
git clone https://github.com/kiki1e/IDABridge.git
cp IDABridge/ida_bridge.py ~/.idapro/plugins/
cp -r IDABridge/ida_mcp ~/.idapro/plugins/

2. 重启 IDA

插件加载后:

  • Ctrl-Shift-E → 批量导出
  • Ctrl-Alt-M → 启动/停止 MCP 服务器
  • Edit → Plugins → MCP Configuration → 配置端口

批量导出模式

Ctrl-Shift-E → 选择导出目录 → 自动导出

导出内容与 IDAShot 一致:反编译 C 代码、反汇编、字符串、导入/导出表、指针引用、内存 hexdump 等。

也支持 headless 模式:

# Windows
idat64.exe -A -S"ida_bridge.py --force" target.exe

# Linux/macOS
idat64 -A -S"ida_bridge.py /path/to/output --force" target.elf

详见 scripts/ 目录下的便捷脚本。

MCP 模式

1. 在 IDA 中启动 MCP 服务器

Ctrl-Alt-M(或 Edit → Plugins → MCP Server)

服务器默认运行在 http://127.0.0.1:13337

2. 配置 Claude Code

claude_config.json 中的内容添加到 Claude Code 的 MCP 配置中(~/.claude/mcp.json 或项目下的 .mcp.json):

{
  "mcpServers": {
    "idabridge": {
      "command": "python",
      "args": ["path/to/IDABridge/mcp_proxy.py"],
      "env": {
        "IDA_MCP_URL": "http://127.0.0.1:13337"
      }
    }
  }
}

3. 使用

在 Claude Code 中直接调用 IDA 工具——反编译、交叉引用、改名、改类型、读内存等 75+ 个 API。

对比

IDABridge IDAShot IDA MCP
批量导出
实时 MCP 查询
修改 IDB ✅ (via MCP)
离线分析
Headless/idat
配置复杂度 一次性 零配置 需 pip 安装
文件数 多个 单个 多个

项目结构

IDABridge/
├── ida_bridge.py         # 核心插件(复制到 plugins 目录)
├── ida_mcp/              # MCP API 模块(复制到 plugins 目录)
├── mcp_proxy.py          # MCP 代理(Claude Code ↔ IDA 桥梁)
├── claude_config.json    # Claude Code MCP 配置示例
├── scripts/
│   ├── export.ps1        # Windows 便捷脚本
│   └── export.sh         # Linux/macOS 便捷脚本
└── README.md

工作流建议

  1. 分析初期Ctrl-Shift-E 全量导出,在 Claude Code 中快速建立全局认知
  2. 深度分析Ctrl-Alt-M 启动 MCP,对关键函数实时交互、改名、追踪
  3. 回归分析 → 修改 IDB 后重新导出,对比分析结果变化

依赖

  • IDA Pro 8.3+ (推荐 9.0+)
  • IDA Pro 自带的 Python 3.x(无需额外安装)

MCP 代理需要:

  • Python 3.10+ (系统 Python,仅运行 mcp_proxy.py 时需要)

License

MIT

致谢

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages