A sandboxed MCP tool for reverse engineering with multiple tool integrations
Project description
mcp-reverse-engineering
A sandboxed MCP (Model Context Protocol) tool for reverse engineering that provides a unified interface to various reverse engineering tools with security restrictions.
Purpose
This project provides a secure, sandboxed environment for executing reverse engineering tools via CLI or MCP protocol. It wraps common reverse engineering utilities (strings, objdump, readelf, binwalk, etc.) with safety features like filesystem isolation, timeouts, and argument validation.
Install
pip install mcp-reverse-engineering
Or for development:
pip install -e ".[dev]"
MCP Server Installation
To use as an MCP server with Claude Desktop:
mcp install src/mcp_reverse_engineering/server.py
Usage
CLI
# Extract strings from a binary
mcp-re --tool strings --file /path/to/binary
# Disassemble a binary
mcp-re --tool objdump --args "['-d']" --file /path/to/binary
# Analyze ELF headers
mcp-re --tool readelf --args "['-h', '-s']" --file /path/to/elf
# Run binwalk for firmware analysis
mcp-re --tool binwalk --file /path/to/firmware.bin
Python API
from mcp_reverse_engineering import ReverseEngineeringEngine
# Create engine with default config
engine = ReverseEngineeringEngine(
workspace="./workspace",
timeout=30,
)
# List available tools
print(engine.list_available_tools())
# Execute a tool
result = engine.execute_tool("strings", ["-n", "8"], "/path/to/binary")
print(result)
MCP Server
from mcp_reverse_engineering.server import mcp, strings, objdump, readelf, binwalk
# Run the server (stdio transport for Claude Desktop)
if __name__ == "__main__":
mcp.run()
API
ReverseEngineeringEngine
Main class for executing reverse engineering tools.
engine = ReverseEngineeringEngine(
workspace: str = "./workspace", # Sandbox directory
timeout: int = 30, # Tool execution timeout
config_path: str | Path | None = None, # YAML config path
)
Methods:
execute_tool(tool_name: str, args: List[str], file_path: Optional[str] = None) -> str- Execute a toollist_available_tools() -> List[str]- List enabled toolsget_tool_documentation(tool_name: str) -> Dict[str, Any]- Get tool docsget_mcp_tools() -> List[Dict[str, Any]]- Get MCP tool schemas
Available Tools
| Tool | Category | Description |
|---|---|---|
| file | file_tools | Determine file type |
| strings | file_tools | Extract printable strings |
| hexdump | file_tools | Hexadecimal dump |
| xxd | file_tools | Hexadecimal dump |
| objdump | binary_tools | Disassemble binary |
| readelf | binary_tools | Read ELF headers |
| binwalk | firmware_tools | Firmware analysis |
Development
# Clone the repository
git clone https://github.com/daedalus/mcp_reverse_engineering.git
cd mcp_reverse_engineering
# Install dependencies
pip install -e ".[test]"
# Run tests
pytest
# Format code
ruff format src/ tests/
# Lint
ruff check src/ tests/
# Type check
mypy src/
# Install pre-commit hooks
pip install pre-commit
pre-commit install
MCP Server Configuration
mcp-name: io.github.daedalus/mcp-reverse-engineering
Requirements
- Python 3.11+
- External tools: binwalk, radare2, ghidra, etc. (must be installed separately)
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mcp_reverse_engineering-0.1.3.tar.gz.
File metadata
- Download URL: mcp_reverse_engineering-0.1.3.tar.gz
- Upload date:
- Size: 14.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0af92eb90f1f68f217e82e4ca89d4b680810e604b155e6d6d045a9bf40880bfc
|
|
| MD5 |
4357be5cea695572a7886e5d564c9a30
|
|
| BLAKE2b-256 |
096766520d75c57c9940608de0683c3488ab1676c2e574b82fcc75546290cb7c
|
Provenance
The following attestation bundles were made for mcp_reverse_engineering-0.1.3.tar.gz:
Publisher:
pypi-publish.yml on daedalus/mcp_reverse_engineering
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mcp_reverse_engineering-0.1.3.tar.gz -
Subject digest:
0af92eb90f1f68f217e82e4ca89d4b680810e604b155e6d6d045a9bf40880bfc - Sigstore transparency entry: 1263450341
- Sigstore integration time:
-
Permalink:
daedalus/mcp_reverse_engineering@fcd256e97b33930cd2ca650502e3c8cf5c71929d -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/daedalus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi-publish.yml@fcd256e97b33930cd2ca650502e3c8cf5c71929d -
Trigger Event:
release
-
Statement type:
File details
Details for the file mcp_reverse_engineering-0.1.3-py3-none-any.whl.
File metadata
- Download URL: mcp_reverse_engineering-0.1.3-py3-none-any.whl
- Upload date:
- Size: 20.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a4d5800f95a2d407de544de1e7dfecad415e6eac51841eea02126c108b94d449
|
|
| MD5 |
173cddee7c49d9115042b47e75b923d2
|
|
| BLAKE2b-256 |
4babd20fde61aa0067af260b231261a915346e56f4548f841535dc087b8da73d
|
Provenance
The following attestation bundles were made for mcp_reverse_engineering-0.1.3-py3-none-any.whl:
Publisher:
pypi-publish.yml on daedalus/mcp_reverse_engineering
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mcp_reverse_engineering-0.1.3-py3-none-any.whl -
Subject digest:
a4d5800f95a2d407de544de1e7dfecad415e6eac51841eea02126c108b94d449 - Sigstore transparency entry: 1263450405
- Sigstore integration time:
-
Permalink:
daedalus/mcp_reverse_engineering@fcd256e97b33930cd2ca650502e3c8cf5c71929d -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/daedalus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi-publish.yml@fcd256e97b33930cd2ca650502e3c8cf5c71929d -
Trigger Event:
release
-
Statement type: