Reverse Engineer Anything: Step-by-Step Setup & Workflow - 가이드

Reverse Engineer Anything: Step-by-Step Setup & Workflow

Learn how to use Reverse Engineer Anything (REA): install the CLI, connect MCP servers to AI agents, analyze binaries, and validate findings.

2026-10-18
reverse engineer anything Wiki Team
Quick Guide
  • Reverse Engineer Anything is an open-source toolkit that lets AI coding agents analyze apps, websites, JavaScript, Electron packages, and native binaries locally.
  • Two interfaces: a CLI for terminal workflows and an MCP server for agent tool calls.
  • Quick start: run npx rea-agents@latest setup to install and configure.
  • Evidence-first: every conclusion should link to addresses, strings, or runtime traces, not guesses.
  • Agent support: works with Claude, Cursor, Codex, Gemini CLI, Windsurf, and Devin.

What Reverse Engineer Anything Is and Who It's For

Reverse Engineer Anything (REA) is an open-source reverse engineering toolkit built for AI coding agents. Instead of recovering original source code automatically, REA gives your agent a structured way to inspect software: it analyzes applications, websites, JavaScript, Electron apps, and native binaries through a local CLI and an MCP server. Everything runs on your machine, with an emphasis on evidence chains and reproducible investigations.

Know the Scope

REA does not automatically decompile software into perfect source code. It orchestrates analysis, records evidence, and helps agents ask narrow, answerable questions about a target.

CLI Users

  • Terminal-first analysts
  • Scripted, repeatable pipelines
  • Direct commands like analyze, search, xrefs

MCP Agent Users

  • Claude, Cursor, Codex, Gemini CLI
  • Windsurf, Devin integrations
  • Agent-driven tool calls

Target Types

  • Native binaries (ELF, PE, Mach-O)
  • Electron apps (ASAR, package.json)
  • Websites and JavaScript runtimes
InterfaceAudienceBest ForKey Capability
CLITerminal usersRepeatable local analysisDirect commands, scripted output
MCP ServerAI coding agentsAgent-driven investigationStructured tool calls, evidence records

Installation and Setup in Five Steps

Setup follows a predictable path: prepare the environment, install REA, diagnose problems, connect your agent, and verify the connection works.

1

Check prerequisites

Confirm you have Node.js and npm installed, plus a supported operating system. REA runs locally, so no cloud account is required. Keep an isolated working directory for analysis targets.

2

Run the installer

Execute npx rea-agents@latest setup. The interactive setup confirms your installation plan, detects installed coding agents, and writes the appropriate configuration.

3

Diagnose the environment

Run rea doctor to check for missing dependencies, path errors, and Node.js or external tool issues. Fix any reported problems before connecting an agent.

4

Connect your coding agent

Register the MCP server in your agent's configuration (Claude Desktop, Cursor, or another MCP client). Restart the client so it discovers REA's tools.

5

Verify the connection

Ask your agent to list available REA tools or run a trivial analysis on a known file. If tools appear and return results, setup is complete.

Environment Mismatch

A common failure is installing dependencies in one Python or Node environment while the agent launches the server with another. Always run rea doctor and test the server command manually under the same user the agent uses.

Setup TaskCommandPurpose
Install REAnpx rea-agents@latest setupInstall and configure CLI + MCP
Diagnose issuesrea doctorDetect missing dependencies and path errors
Verify MCPAgent tool listingConfirm the agent discovers REA tools

Core CLI Commands Reference

The CLI covers the full investigation cycle: identifying a target, searching its contents, tracing relationships, and capturing evidence.

CategoryCommandWhat It Does
Target IDfile <target>Identify format, architecture, executable type
Evidencesha256sum <target>Record a hash proving the target is unmodified
Stringsstrings -a -n 6 <target>Extract printable strings for leads
Disassemblyobjdump -d -M intel <target>Generate assembly for executable sections
Debugginggdb -q <target>Interactive runtime analysis
Report capturetee <report-file>Save output into a reproducible report

REA-specific commands such as analyze, inspect, search, function, xrefs, and trace wrap these operations into agent-friendly workflows.

Evidence Discipline

Hash the target before and after analysis. If the hash changes, your findings no longer describe the original file, and the investigation must restart from a clean copy.

The Six-Phase Analysis Workflow

A reliable investigation moves from low-risk observation to focused analysis and validated conclusions.

1

Identify and preserve

Determine file type, architecture, and imports; record the SHA-256 hash; build a baseline target profile before touching anything.

2

Static analysis

List symbols, extract strings, inspect sections and entry points. Build an initial map without executing the target.

3

Locate and trace

Search for references to interesting strings or imports, trace callers and callees, and record addresses with meaningful working names.

4

Dynamic analysis

Run the target in an isolated debugger, set breakpoints at candidate functions, and capture runtime evidence comparing against static hypotheses.

5

Test hypotheses

On a copy, apply the smallest controlled modification and compare behavior between original and modified targets.

6

Validate and report

Separate direct observations from interpretations, link each conclusion to an address or artifact, and save a reproducible report with tool logs and the target hash.

Ask Narrow Questions

Broad prompts like "explain this binary" produce unreliable output. Ask for one thing at a time: list symbols, find references to a string, decompile one function. Focused requests are easier to validate.

Safety, Permissions, and Troubleshooting

REA emphasizes local analysis and minimal privilege. Follow these practices to keep both your machine and your findings trustworthy.

Safe Analysis Checklist:

  • Analyze unknown binaries only in a VM or container
  • Record the target hash before and after analysis
  • Restrict MCP server access to an approved analysis root
  • Require manual approval before executing unknown programs
  • Keep secrets and personal files outside the workspace
SymptomLikely CauseFix
MCP server exits immediatelyWrong path or missing dependencyUse absolute paths, install deps in the correct environment
Tools not discoveredRegistration after init, stale cacheRegister tools during startup, restart the client
Decompilation unreadableStripped or obfuscated binaryLoad symbols, define code regions, validate dynamically
Permission deniedFile outside approved rootMove inputs into the configured analysis directory
Analysis times outWhole-file scan for a narrow questionAdd range and result-limit parameters, split into jobs
Legal and Ethical Use

Only analyze software you own or are authorized to investigate. Respect licenses and terms of service; reverse engineering restrictions vary by jurisdiction.

FAQ

Q: How do I use Reverse Engineer Anything for the first time?

Run `npx rea-agents@latest setup` to install, then `rea doctor` to verify your environment. Register the MCP server with your coding agent, restart the client, and confirm REA tools appear. Start with a simple target like a small JavaScript file before tackling native binaries.

Q: Which AI coding agents work with REA?

REA supports MCP-capable agents including Claude, Cursor, Codex, Gemini CLI, Windsurf, and Devin. Any MCP-compatible client can connect to the local server through its configuration.

Q: Does REA recover original source code?

No. REA focuses on evidence-based analysis and reproducible investigations rather than restoring original source. It helps agents inspect, trace, and document behavior with verifiable references.

Q: Why does my agent say REA tools don't exist?

Usually the server failed to start or the client cached an old capability list. Test the server command manually, confirm dependencies are installed in the environment the agent actually uses, and restart the client after configuration changes.

Related Articles