re-code-mode
Provides Android APK analysis capabilities, including framework fingerprinting and extraction of endpoints from DEX files, plus Android-specific reverse-engineering playbooks.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
re-code-mode
A layered reverse-engineering toolbox for AI agents, served through UTCP Code Mode so that big outputs are filtered inside a sandbox instead of flooding your model's context window.
Disassembling a binary, listing imports or dumping strings can easily produce tens of thousands of lines. Classic MCP tool-calling pushes all of that into the model. With Code Mode the agent writes a few lines of TypeScript, the filtering happens locally, and only the answer comes back.
// one round-trip: triage + capability filter + selective strings
const t = await re.re_triage_binary({ path: "/samples/app" });
const imps = await re.re_imports_exports({ path: "/samples/app", filter: "socket|ssl|crypt", kind: "imports" });
const urls = await re.re_extract_strings({ path: "/samples/app", preset: "urls", limit: 10 });
return { arch: t.binary_info.arch, hardening: t.binary_info.security,
net_imports: imps.imports.map(i => i.name), urls: urls.strings.map(s => s.string) };Responsible use. This project is for analysing software you own or are authorised to analyse: security research, malware triage, interoperability, CTFs, education. See DISCLAIMER and SECURITY.md.
Architecture
flowchart LR
A[AI agent] -->|TypeScript| B[UTCP Code Mode sandbox]
B -->|MCP stdio| C[re-code-mode server]
C --> L1[Layer 1: local engines<br/>radare2 · rabin2 · binwalk · upx · unzip]
C --> L2[Layer 2: catalog<br/>300+ community tools, clone on demand]
C --> L3[Layer 3: playbooks and agent skills]
C -.optional.-> R[REA engine<br/>200+ tools]Layer | What it gives you |
1 – Engines |
|
2 – Catalog |
|
3 – Playbooks & skills |
|
Inside Code Mode every tool is prefixed with the manual name, so triage_binary is called as re.re_triage_binary(...).
Related MCP server: Antardrishti
Requirements
Node.js ≥ 18, Python 3, git
radare2(providesr2/rabin2),binwalk,upx,unzip,fileOptional:
jadx,apktool,gdb,frida
Quick start
git clone https://github.com/sosiman/re-code-mode.git
cd re-code-mode
bash scripts/setup.sh --install-system-deps # Debian/Ubuntu; on macOS: brew install radare2 binwalk upx
# optional extras
bash scripts/setup.sh --with-skills # clone third-party agent skills into ./skills-repos
bash scripts/setup.sh --with-rea # install the optional REA engine
npm test # smoke + security regression tests
bin/re-run.sh list
bin/re-run.sh triage ./some-binarysetup.sh writes machine-local .utcp_config.json (git-ignored). If your npm blocks install scripts, approve isolated-vm (the V8 sandbox used by Code Mode) with npm install-scripts approve.
CLI cheat-sheet (bin/re-run.sh)
bin/re-run.sh catalog "ghidra" 5 # search the tool catalog
bin/re-run.sh playbook android_apk # methodology for a target type
bin/re-run.sh triage ./bin # arch, hardening, libs, SHA-256 (<1s)
bin/re-run.sh imports ./bin "socket|ssl" # filtered imports/exports
bin/re-run.sh strings ./bin "https?://" # filtered strings
bin/re-run.sh funcs ./bin "main|auth" # functions (radare2 analysis)
bin/re-run.sh decompile ./bin main # pdf + pdc for one function
bin/re-run.sh apk ./app.apk apis # framework fingerprint + endpoints from DEX
bin/re-run.sh firmware ./fw.bin # embedded files + UPX check
bin/re-run.sh fetch radareorg/radare2-mcp # shallow clone into ./tools-cache
bin/re-run.sh skills android; bin/re-run.sh skill-read leanrea
bin/re-run.sh run 'return await re.re_catalog_categories({});'All arguments are JSON-encoded before being placed in the generated TypeScript, so file names and patterns cannot inject code.
Use it from an agent
Copy skills/re-code-mode into your agent's skills directory (Claude Code, Gemini CLI, Codex, Hermes, … — anything that reads SKILL.md) and set RE_CODE_MODE_HOME to this checkout. The skill teaches the agent the workflow and the Code Mode idioms.
Configuration (environment variables)
Variable | Effect |
| Override the project root (default: auto-detected). |
|
|
| Expose the free-form |
| Keep the offensive-security modules when cloning |
Security notes (short version)
Run it locally for a user you trust; it is not a multi-tenant service.
Analysing hostile samples with any disassembler is risky — use a VM/container.
radare2 command injection, option injection in
git clone, code injection through shell arguments and ReDoS are covered by tests intest/smoke.mjs.
Full details and reporting instructions: SECURITY.md.
Third-party material
Nothing from the projects below is redistributed here. They are fetched on your machine, under their licences:
Catalog sources: zhuyansen/awesome-ai-reverse-engineering, morluto/awesome-reverse-engineering
Skills (optional): aicodeking/leanrea, SimoneAvogadro/android-reverse-engineering-skill, zhaoxuya520/reverse-skill
Engine (optional): morluto/rea (
rea-agentson npm)Runtime: radare2, UTCP code-mode CLI, Model Context Protocol SDK
Contributing
See CONTRIBUTING.md. New engines, playbooks and fixes are welcome.
Disclaimer
This software is provided for lawful, authorised security research, education and interoperability work. You are solely responsible for complying with applicable laws, licences and terms of service. The authors accept no liability for misuse. Do not use it to analyse systems or software you are not permitted to analyse.
License
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Autonomous agent guardrails, bash sandboxing, MCP rugpull diffing & prompt firewalls.
Pre-execution governance for AI agents. Deterministic PASS/FAIL/REVIEW verdicts, replayable proof.
Formally-verified injection/exfiltration detector for AI agents (MCP-02).
Hunt zero-days by talking to binaries. 40+ tools. Hosted, OAuth + SSO, invite: hi@byteray.ai
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA headless Ghidra server that enables AI agents to perform deep reverse-engineering tasks such as disassembly, decompilation, and patching via the Model Context Protocol. It supports extensive automation of analysis workflows in sandboxed environments through a catalog of over 200 specialized tools.196GPL 2.0
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to locally analyze and reverse engineer binaries through a compact 12-tool MCP interface for triage, function discovery, disassembly/decompilation, cross-references, strings/imports, call graphs, memory reads, annotations, and binary diffs.1MIT
- AlicenseAqualityBmaintenanceEnables AI agents to run read-only static reverse-engineering tasks — binary triage, symbol and import inventory, per-function decompilation, and Android native-lib analysis — with untrusted samples confined to a no-network bubblewrap chamber that never executes the target.7MIT
- AlicenseNot gradedqualityNot gradedmaintenanceEnables AI agents to inspect and reverse engineer local software targets, including binaries, JavaScript/Electron apps, .NET assemblies, and websites, returning evidence-backed findings for understanding and building similar features.388,706 npmMIT