Rogue_Binary // Triage_Mode
Document_Viewer: /wiki/rbinghidra-setup
Back_To_Index
Rogue Binary MCP
Ghidra MCP Setup
Compile and configure the rbinghidra Model Context Protocol server natively.
Section: Requirements
The rbinghidra MCP server requires a headless Ghidra installation and a working Rust toolchain. It runs completely locally without containers.
- Ghidra installation directory (version 12.1 or newer recommended).
- Java Development Kit (JDK 21 or newer) configured and available in your environment path.
- Rust toolchain (Cargo/rustc 1.75 or newer).
Section: Compilation
Clone the repository and compile the native Rust binary inside your local environment.
- Navigate into the cloned rbinghidra directory.
- Run the cargo build command with release optimizations.
- The compiled native executable will be located in the target directory.
cd ~/rbinghidra
cargo build --release
Section: MCP Client Configuration
Add the server to your AI agent client (such as Claude Desktop or Claude Code) using absolute executable paths and standard environment variables.
- Define GHIDRA_INSTALL_DIR to point to your headless Ghidra folder.
- Define RBM_CACHE_DIR to control where Ghidra project files and decompilation cache are saved.
- Configure execution to run directly through the native binary pipe.
{
"mcpServers": {
"rbinghidra": {
"command": "/path/to/rbinghidra/target/release/rbinghidra",
"env": {
"GHIDRA_INSTALL_DIR": "/path/to/ghidra",
"RBM_CACHE_DIR": "~/.cache/rbinghidra"
}
}
}
}
claude mcp add rbinghidra -- \
/path/to/rbinghidra/target/release/rbinghidra \
-e GHIDRA_INSTALL_DIR=/path/to/ghidra \
-e RBM_CACHE_DIR=~/.cache/rbinghidra
Section: Cache and Projects
The server manages private Ghidra headless projects automatically inside your specified cache directory. Consecutive calls reuse these pre-imported databases for sub-second responses.
- Ghidra project databases are persisted under the ghidra/ subpath of your cache directory.
- In-flight locks ensure multiple queries to the same binary do not cause conflicts.
- Timeout configurations can be controlled via the RBM_GHIDRA_TIMEOUT environment variable.