RR

radareorg/radare2-mcp

Developer tools공식

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기

340 stars 42 forks 품질 81 트렌드 35MIT

radareorg/radare2-mcp는 https://github.com/radareorg/radare2-mcp.에서 가져온 MCP 서버 후보입니다.

개요

radareorg/radare2-mcp는 https://github.com/radareorg/radare2-mcp.에서 가져온 MCP 서버 후보입니다.

개요(AI 번역)

OpenCode, Mai, VSCode, Claude, CLION 등과 같은 AI 에이전트와 함께 radare2를 사용할 수 있는 MCP 서버입니다.

특징

이 구현은 다음을 제공합니다:

  • 💻 네이티브 r2 API를 사용하여 C로 완전히 작성됨
  • 🧩 CLI에서 r2 플러그인 및 MCP 서버로 동작
  • 🔍 radare2를 이용한 원활한 이진 분석
  • 🔗 r2pipe를 통해 로컬 또는 원격 r2/iaito 세션에 연결
  • 🔒 읽기 전용 모드, 샌드박스 잠금 및 제한 도구 지원
  • 🔩 정밀 공구 구성
  • 🔁 직속/표준 통신 모델
  • 🌐 선택적 X-Session-ID 다중화를 포함한 HTTP MCP 서버 모드
  • 🛠️ 선택적으로 r2 명령어나 r2js 스크립트를 실행할 수 있는 원시 접근

설치

r2pm 사용

패키지를 설치하는 가장 간단한 방법은 r2pm를 사용하는 것입니다:

r2mcp 실행 파일은 홈 디렉터리의 r2pm bindir에 복사됩니다. 하지만 이 바이너리는 셸에서 직접 실행되어서는 안 되며; 선택한 언어 모델의 MCP 서비스 핸들러가 실행할 때만 작동합니다.

이것이 일반적인 mcpServer JSON 구성 파일입니다:

코덱스

코덱스 플러그인을 설치하려면 다음 명령어를 실행하세요:

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.

README

원문 README의 일부입니다. 원문 보기.

Radare2 MCP Server

An MCP server to use radare2 with AI agents such as OpenCode, Mai, VSCode, Claude, CLION, …

Features

This implementation provides:

  • 💻 Fully written in C using the native r2 APIs
  • 🧩 Works from the CLI, as an r2 plugin and as an MCP server
  • 🔍 Seamless binary analysis with radare2
  • 🔗 Connect to any local or remote r2/iaito session via r2pipe
  • 🔒 Supports readonly mode, sandbox lock and restrict tools
  • 🔩 Fine grained tools configuration
  • 🔁 Direct stdin/stdout communication model
  • 🌐 HTTP MCP server mode with optional X-Session-ID multiplexing
  • 🛠️ Optional raw access to run r2 commands or r2js scripts

Installation

Using r2pm

The simplest way to install the package is by using r2pm:

$ r2pm -Uci r2mcp

The r2mcp executable will be copied into r2pm’s bindir in your home directory. However, this binary is not supposed to be executed directly from the shell; it will only work when launched by the MCP service handler of your language model of choice.

$ r2pm -r r2mcp

That’s the common mcpServer JSON configuration file:

{
  "mcpServers": {
    "radare2": {
      "command": "r2pm",
      "args": ["-r", "r2mcp"]
    }
  }
}

Codex

To install the codex plugin just run the following command:

make codex-plugin-install

This will create a personal marketplace in your home and copy the files from dist/codex-plugin inside.

Using Docker

Alternatively, you can build the Docker image:

docker build -t r2mcp .

Update your MCP client configuration file (see below) to use the Docker image to use:

  • "command": "docker"
  • "args": ["run", "--rm", "-i", "-v", "/tmp/data:/data", "r2mcp"].

Configuration

HTTP Server Mode

Use -H [address:]port to run r2mcp as an HTTP MCP server instead of using stdin/stdout. A bare port binds only to 127.0.0.1; use 0.0.0.0:port explicitly to make the server reachable from the network:

r2mcp -H 8765
# Public binding; protect this with -a  or -A.
r2mcp -H 0.0.0.0:8765 -A

Per-session HTTP state is enabled with -X max[:idle_seconds] and routed by the X-Session-ID request header:

r2mcp -H 8765 -X 8:600

HTTP bearer authentication is enabled with -a . Clients must send Authorization: Bearer on every GET and POST request:

GitHub에서 전체 README 보기

설치

docker run --rm -i -v /tmp/data:/data r2mcp
MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →

설정

{ "mcpServers": { "radare2": { "command": "r2pm", "args": ["-r", "r2mcp"] } } }