Libre reverse engineering framework and command-line toolset for analyzing, disassembling, debugging and emulating binaries on Unix-like systems.
radareorg/radare2-mcp
An MCP server that lets AI agents drive radare2 for binary analysis, running from the CLI, as an r2 plugin, or over HTTP.
- Stars
- 357
- Forks
- 43
- Open issues
- 9
- Last commit
- 23 days ago
What is it?
r2mcp is a Model Context Protocol (MCP) server written in C that connects AI agents such as Claude, VS Code Copilot Chat, Zed and OpenCode to radare2, the open-source reverse engineering framework. It lets an agent open binaries, run analysis and issue r2 commands through structured tools, so the model can inspect functions, strings and disassembly on its own.
The server can run over stdin/stdout for desktop MCP clients, as an HTTP MCP server with optional bearer-token authentication and per-session multiplexing via the X-Session-ID header, or as a plugin inside an existing radare2 session so it reuses the file and analysis state already loaded. It can attach to local or remote r2 and iaito sessions through r2pipe.
Access control is configurable: read-only mode, a sandbox lock, restricted or fine-grained tool selection, and an approval mode for dangerous run tools. An optional r2xsql plugin adds a SQL tool for querying analysis data.
Key features
- 01Native C implementation built on radare2's APIs.
- 02Runs over stdin/stdout, as an HTTP MCP server, or as an r2 core plugin.
- 03Connects to local or remote r2 and iaito sessions via r2pipe.
- 04Read-only mode, sandbox lock and fine-grained tool restrictions.
- 05Optional bearer-token authentication and per-session HTTP multiplexing.
- 06Optional raw access to run r2 commands or r2js scripts.
Use cases
- Letting an AI assistant in Claude Desktop or VS Code triage a binary and summarize its functions.
- Automating reverse engineering steps from an agent while keeping the target file read-only.
- Exposing a shared radare2 analysis service over HTTP to several clients.
- Querying analysis results with SQL through the r2xsql plugin.
Quick start
- 1
Install r2mcp via r2pm
r2pm -Uci r2mcp - 2
Add the MCP server entry to your client configuration (command r2pm, args -r r2mcp)
- 3
Alternatively, build the Docker image
docker build -t r2mcp .
Things to know
- Requires radare2 to be installed, and newer HTTP session and auth features need radare2 ABI 91 or later.
- The r2mcp binary is meant to be launched by an MCP client, not run directly from the shell.
In collections
Topics
FAQ
- What is radare2-mcp?
- An MCP server that lets AI agents drive radare2 for binary analysis, running from the CLI, as an r2 plugin, or over HTTP. r2mcp is a Model Context Protocol (MCP) server written in C that connects AI agents such as Claude, VS Code Copilot Chat, Zed and OpenCode to radare2, the open-source reverse engineering framework. It lets an agent open binaries, run analysis and issue r2 commands through structured tools, so the model can inspect functions, strings and disassembly on its own.
- Is radare2-mcp free to use? What license does it have?
- radare2-mcp is open source under the MIT license. Check the license terms before using it in commercial products.
- Is radare2-mcp still maintained?
- Actively maintained. The last commit to radare2-mcp was on Oct 15, 2026.
- What can I use radare2-mcp for?
- Letting an AI assistant in Claude Desktop or VS Code triage a binary and summarize its functions. Automating reverse engineering steps from an agent while keeping the target file read-only. Exposing a shared radare2 analysis service over HTTP to several clients. Querying analysis results with SQL through the r2xsql plugin.
- How do I install radare2-mcp?
- Install r2mcp via r2pm: r2pm -Uci r2mcp Add the MCP server entry to your client configuration (command r2pm, args -r r2mcp) Alternatively, build the Docker image: docker build -t r2mcp .
- Where can I get radare2-mcp?
- The source code and installation instructions are on GitHub: https://github.com/radareorg/radare2-mcp
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
LLM-powered plugin for radare2 that adds an r2ai command for AI-assisted reverse engineering, with a decai decompilation plugin.
An MCP server extension for Ghidra that lets AI language models drive reverse engineering analysis through small, focused tools.
Ghidra is an open-source software reverse engineering framework from the NSA, offering disassembly, decompilation, graphing and scripting for compiled code.
A free, open-source reverse engineering platform with a GUI, built on the rizin framework.
A UNIX-like reverse engineering framework and command-line toolset for analyzing binaries, disassembling code and debugging programs.