- Reverse Engineer Anything (REA) connects Claude Code to reverse engineering tools via MCP and CLI.
- Two interfaces: run terminal commands directly or let the agent call MCP tools.
- Evidence-based workflow: every conclusion links to addresses, strings, or runtime traces.
- Local-first analysis: targets stay on your machine; work in an isolated workspace.
- Start fast:
npx rea-agents@latest setupbootstraps the environment.
Why Use Claude Code with Reverse Engineer Anything?
Reverse Engineer Anything is an open-source toolkit built for AI coding agents. Instead of manually wrestling with disassemblers and string dumps, you let Claude Code coordinate the investigation while REA supplies the tooling through a local MCP server and CLI. The project supports multiple agents, including Claude Code, Cursor, Codex, Gemini CLI, Windsurf, and Devin, but Claude Code's MCP client support and skill system make it one of the smoothest integrations.
The core value is the evidence chain. REA is designed around reproducible investigations: the agent records what it observed, where it found it, and how conclusions were validated, rather than guessing at behavior. Everything runs locally, which keeps your analysis targets and findings on your own machine.
MCP Server
- Agent calls typed tools
- Scoped filesystem access
- Structured, bounded results
CLI
- Direct terminal commands
- Scriptable pipelines
- Human-in-the-loop control
Evidence Records
- Address-linked findings
- Reproducible reports
- Separates fact from inference
REA also works with Cursor, Codex, Gemini CLI, Windsurf, and Devin. The MCP configuration pattern is nearly identical across hosts, so skills you build for Claude Code transfer easily.
Setup: Connecting REA to Claude Code
Getting REA running with Claude Code follows the same pattern as any MCP server registration. The recommended entry point is the setup command, which handles environment checks and agent configuration detection.
Verify prerequisites
Confirm Node.js and npm are installed and up to date. REA also relies on local analysis tooling, so check that your platform's disassembler or debugger dependencies are present before the first run.
Run the setup command
Execute npx rea-agents@latest setup. This initializes the workspace, confirms the installation plan, and detects which coding agents are available for configuration.
Register the MCP server
Add the REA server to Claude Code's MCP configuration, pointing it at your approved analysis root. Pass only the directories and environment variables the server actually needs.
Confirm tool discovery
Restart the host and verify that REA's tools appear in Claude Code. Test with a minimal, read-only call before launching any real investigation.
Diagnose if needed
If anything fails, run rea doctor to check for missing dependencies, path errors, or Node.js version problems, then retry.
| Setup Stage | Command / Action | Expected Result |
|---|---|---|
| Install | npx rea-agents@latest setup | Initialized workspace, agent detected |
| Diagnose | rea doctor | Dependency and path report |
| Verify | Restart Claude Code, list tools | REA tools visible to agent |
| Test | Minimal read-only tool call | Structured result returned |
Only expose the analysis workspace to the MCP server. Keep credentials, personal files, and unrelated repositories outside the server's working directory, and require manual approval before executing unknown binaries.
What REA Can Analyze with Claude Code
REA covers a wide range of targets. The analysis method changes per target type, so match your questions and tools accordingly.
Native Binaries
- Functions and symbols
- Strings and xrefs
- Disassembly, call graphs
Electron Apps
- ASAR extraction
- Main/Renderer/Preload
- IPC and source maps
JavaScript / Sites
- Bundle inspection
- Runtime behavior
- Browser execution paths
APKs & Games
- Package structure
- Assets and logic
- Parameter discovery
Official showcases illustrate the depth: analyzing the Chrome Dino game's speed growth rules and maximum speed parameters, and reconstructing the Windows Calculator percent-key logic across addition and multiplication contexts. Both cases demonstrate the pattern of locating behavior, collecting evidence, then rebuilding a verifiable version.
| Target Type | Key Analysis Focus | Typical Evidence |
|---|---|---|
| Native binary | Functions, imports, call relationships | Addresses, xrefs, traces |
| Electron app | Entry points, IPC channels | ASAR contents, source maps |
| Website / JS | Bundles, network calls, runtime state | Scripts, console traces |
| APK | Manifest, resources, logic | Package files, smali/JS |
Ask Claude Code for focused, tool-backed observations. A request like "find references to this string" produces verifiable output; asking it to "explain the whole program" invites speculation.
The Investigation Workflow
A reliable REA session with Claude Code moves from low-risk observation to validated conclusions across six phases.
Identify the target
Record file type, architecture, size, and SHA-256 hash. Create a baseline profile before any deep analysis.
Static analysis
List symbols and imports, extract strings, inspect sections and entry points to build an initial code and data map.
Locate and trace
Search for references to selected strings or imports, then trace callers and callees to narrow the binary to relevant functions.
Dynamic analysis
Run the target in an isolated, controlled environment with breakpoints. Compare observed runtime behavior against static hypotheses.
Test hypotheses
Apply the smallest controlled modification to a copy, then compare behavior between original and modified versions.
Report and validate
Separate direct observations from interpretations, link each conclusion to an address or artifact, and save a reproducible report.
Useful CLI commands that pair well with agent-driven analysis:
| Command | Purpose | Output |
|---|---|---|
file <target> | Identify format and architecture | ELF, PE, Mach-O classification |
sha256sum <target> | Preserve integrity baseline | Stable digest for comparison |
strings -a -n 6 <target> | Discover readable strings | Paths, messages, URLs |
objdump -d -M intel <target> | Quick disassembly review | Assembly text |
gdb -q <target> | Runtime inspection | Interactive debug session |
Pass artifact paths and retrieve excerpts instead of pasting full disassembly into the conversation. Keep a compact investigation ledger with names, addresses, evidence, and open questions so long sessions stay coherent.
Troubleshooting Common Issues
| Symptom | Likely Cause | Fix |
|---|---|---|
| MCP server exits immediately | Wrong path, missing dependency, stdout pollution | Use absolute paths; send logs to stderr; test manually |
| Tools not discovered | Registration after init, invalid schema | Register tools at init; validate schemas; restart client |
| Decompilation incomplete | Stripped or obfuscated binary | Confirm architecture; load symbols; verify dynamically |
| Permission denied | File outside approved workspace | Move inputs into the analysis root; grant least access |
| Analysis times out | Whole-file jobs, no limits | Add range and result limits; split into bounded jobs |
| Context window overflow | Entire binary in prompt | Use path references and function-level queries |
Treat Claude Code as an analysis assistant, not an authority. Reproduce important conclusions with the underlying tool—a debugger, disassembler, or test input—before treating them as confirmed behavior.
Every REA Investigation Should End With:
- Baseline profile with hash and format recorded
- Evidence linked to specific addresses or artifacts
- Confirmed behavior separated from open questions
- Reproducible report saved with tool logs
- Original target verified unchanged via hash
FAQ
Q: Does Reverse Engineer Anything recover original source code?
No. REA is built around evidence-based analysis and reproducible investigation workflows. It helps agents understand and document how software works locally, rather than automatically recovering original source or copying software.
Q: How does Claude Code connect to REA?
Through REA's MCP server registered in Claude Code's MCP configuration, plus the CLI for direct terminal work. Run `npx rea-agents@latest setup` to initialize, then confirm the server's tools appear in the agent.
Q: Is analysis done locally?
Yes. The project emphasizes local analysis with evidence chains and reproducible investigation flows. Targets and findings stay on your machine inside an approved workspace.
Q: Where do I get help with setup problems?
Run `rea doctor` for dependency and path diagnostics first. For further support, use the official GitHub Issues, the rea.tools website, or the official Discord community linked on the site.