National Cyber Warfare Foundation (NCWF)login

Inside KRAKEN: how a Rust workbench turns Ghidra into an agent-friendly reverse engineering bench


0 user ratings
2026-10-25 23:30:12
milo
Red Team (CNA)
"Inside

KRAKEN is a pre-alpha reverse-engineering workbench built on Ghidra's decompiler with a Java-free native engine, sandboxed patching, AI-assisted analysis, and verified Rust rewrites for authorized binary analysis.








ToolAdam-AtlasSoftware/kraken — open-source reverse-engineering workbench combining Ghidra's decompiler with a native engine, AI assistance, and Rust rewrite tooling
CategoryReverse engineering / binary analysis platform
Primary UseAuthorized static analysis, decompilation, byte patching, and verified Rust rewrites of ELF/PE binaries in C-like decompiler output
Safe UseFor authorized professionals analyzing software they own or are permitted to assess — malware triage in sandboxes, CTF work, defensive research, and interdiction-free lab environments
Telemetry NotePurely local analysis tool; every edit is logged with its author in an undoable history, and Ghidra/native engines run in Landlock-confined processes with no network — defenders observing it see only local process activity

KRAKEN, published at Adam-AtlasSoftware/kraken and written in Rust under GPL-3.0-or-later, is a reverse-engineering workbench that takes an unusual position in a crowded field: instead of being yet another GUI wrapper around Ghidra, it restructures the entire analysis workflow around a single command registry that drives the CLI, an MCP server, the GUI, and external AI agents simultaneously. The core promise is that you, your scripts, and AI agents all operate on the same project through one set of commands, so automation and manual review cannot drift apart. Every edit is logged, attributed to its author, and undoable — a design that reads as a direct answer to the trust problems that come with letting language models loose on a binary analysis session. At 0.1a pre-alpha, with roughly 32 stars and Linux x86_64 as the only fully supported platform, this is clearly an early project, but the architecture described in the README is unusually coherent for its age.


The analysis engine comes in two flavors, and the distinction matters operationally. The native engine requires no Java at all and handles ELF and Windows PE files on x86 and x86-64, with the processor files bundled in the release. The optional full Ghidra engine, fetched via kraken setup, extends coverage to Mach-O and a much wider processor set. New projects automatically select the native engine when it can open the file, falling back to Ghidra otherwise. The project ships a practice corpus in corpus/bin/ and a docs/tutorial.md that walks a newcomer through a first session — a deliberate onboarding choice for analysts who don't yet know reverse engineering, reinforced by an offline glossary and in-app term explanations.


The feature surface covers what you'd expect from a serious workbench: function discovery and decompilation to C-like output via Ghidra's decompiler, a listing view, hex view, control-flow graph, cross-references, strings, imports and exports, and a memory map. Interactive editing is first-class — renaming functions, setting types, adding comments — and the UI supports search, filtering, and jumping between views. The README's screenshot shows the classic four-pane layout (function list, decompiler, hex, listing) applied to a stripped binary from the project's own corpus, which is a sensible way to demonstrate the tool on material the authors control.


The patching workflow is where the design gets interesting from a safety standpoint. You can type a new instruction and KRAKEN assembles it, or edit the decompiled C and let the assistant compute the smallest machine-code change. Crucially, the original and patched programs can be run side by side in a sandboxed emulator before anything is written, and the original file is never touched — patches are exported as a separate copy. Every patch is an entry in the edit history, so patches proposed by an AI assistant can be reviewed and reverted like any human edit. For authorized analysts doing binary hardening research or verifying vendor fixes, this reviewable-patch model is exactly the right shape.


The AI integration is deep but deliberately constrained. The built-in assistant can explain a function, provide a guided first look at a program, and suggest names — but name suggestions are reviewed by the human before anything changes. Models run locally through Ollama, LM Studio, or llama.cpp, or with a cloud provider. Terminal agents like Claude Code, Codex, and Gemini CLI can either run inside the app or connect from outside over MCP, wired up with something like claude mcp add kraken -- kraken mcp --project ~/kraken-projects/ls. Agent writes are additive or proposals only: an agent may name an unidentified FUN_... function or add a comment within a per-run cap, while anything that would overwrite your work waits for explicit acceptance.


The safety model documented in the README deserves specific attention because it addresses prompt injection head-on — a concern anyone feeding decompiler output into a model should share. Everything derived from the analyzed file (names, strings, comments, decompiled text) is handed to AI models only as clearly marked untrusted data, never as instructions. Ghidra and the native decompiler each run in separate processes confined with Landlock on Linux: no network access, writes restricted to a throwaway home and the project folder, and a scrubbed environment. The program under analysis is executed only for whole-program rewrites, confined the same way, and only after asking the user. This is a threat model statement few comparable tools bother to write down.


The most ambitious feature is the rewrite pipeline, which aims at verified Rust rewrites of binaries function by function. KRAKEN translates a single function to Rust, runs the original under emulation and the Rust version side by side, and surfaces the smallest input where the two disagree — a differential-testing approach to semantic verification. The tool plans the rewrite order callees-first, requires the human to accept verified functions, and can export a finished Cargo workspace. This is genuinely novel positioning: not just understanding a binary, but producing a checkable replacement for it, which has obvious applications in legacy modernization and dependency migration under authorization from the software's owner. Note that on macOS and Windows the rewrite pipeline refuses to run entirely; it needs Landlock and a model, making Linux the platform to use today.


Automation is served through --json output for scripts, a Python module, and a background daemon that keeps projects warm between invocations. The single command registry means the CLI, MCP server, GUI, and agents all share identical semantics, and the command reference is generated from the code via cargo xtask docs. Building from source requires Rust and a C++ compiler: git clone followed by cargo build --release -p kraken-cli -p krakend -p kraken-gui -p engine-native -p kraken-emu, then a one-time kraken setup --native that fetches pinned sources and compiles the Sleigh processor files in about a minute.


For Linux users the release path is straightforward: the install script checks downloads against the release's SHA256SUMS, needs no sudo, and installs into ~/.local; an AppImage and an AUR package (kraken-workbench-bin) are also available, with experimental Windows and macOS archives on the releases page. Once installed, a first session is roughly kraken project-create --binary /usr/bin/ls --project ~/kraken-projects/ls, then kraken analyze, then kraken list-functions --limit 20 to survey the target — using a system utility as the example binary reinforces the tool's intended lawful framing rather than any offensive posture.


Where does KRAKEN fit in an authorized workflow? Its clearest niches are malware triage in controlled lab environments (where the Landlock confinement and never-touch-the-original patch model reduce operational risk), CTF practice and RE education (the tutorial, glossary, and concepts docs lower the barrier considerably), and defensive research into firmware or legacy binaries you own. The Rust rewrite pipeline additionally targets interdiction-free modernization work — replacing unmaintained components with verified equivalents. What to watch for: the project is pre-alpha with breaking changes expected, macOS/Windows are build-verified only, and the Ghidra engine requires a JDK download on first use, which matters in air-gapped environments. The README's closing line is also its most important constraint: use KRAKEN only on software you are permitted to analyse.



Official project repository for Adam-AtlasSoftware/kraken.

Download Tool

Educational analysis for authorized security professionals. Use only in controlled, authorized environments.






Source: OffensiveSec
Source Link: https://www.offsecblog.com/2026/10/inside-kraken-how-rust-workbench-turns.html


Comments
new comment
Nobody has commented yet. Will you be the first?
 
Forum
Red Team (CNA)



Copyright 2012 through 2026 - National Cyber Warfare Foundation - All rights reserved worldwide.