Solve a crackme with Assist
This walkthrough follows a real Assist session from the first prompt to a verified answer. The target is kestrel-vm, a small stripped Linux x86-64 ELF that asks for a "maintenance password". The twist is that the check is not written in C: main hands the password to an interpreter that runs a bytecode program embedded in the binary.
By the end of the session, Assist has reversed the VM's instruction set, recorded it as an enum in the database, disassembled the embedded program, recovered the password, and confirmed it by emulating the interpreter — and you have seen what each of those steps looks like in the panel. The same approach works on any crackme; only the prompt changes.
Prerequisites
IDA 9.4 SP1 or later (IDA Home, IDA Pro) with a Hex-Rays decompiler license for the target architecture (this walkthrough leans on pseudocode; see Requirements & Support → Decompiler requirements).
Assist installed and an agent connected, see Getting Started.
A permission preset. This walkthrough assumes the recommended Ask before changes preset, so every database edit, script, and memory write shows up as a capability prompt card before it runs. With Work freely, the same steps run without prompts for edits and scripts. See Permissions & Privacy.
The Assist hands-on kit, downloaded and unzipped. This walkthrough uses the
12-vm-crackmefolder.
1. Open the binary and the panel
Open
kestrel-vm.i64from the12-vm-crackmefolder of the kit. The database is already analyzed, so there is nothing to wait for.The Assist panel opens by default. If you closed it, press Ctrl+Shift+K (or choose View → Assist) to reopen it.
With a built-in Assist agent loop backend, Assist offers a one-time Triage this binary suggestion pill above the composer. Triage is a good first step on an unknown sample, but for a crackme you usually already know what you want, so this walkthrough goes straight to a prompt.
2. Ask for the whole job, not just a hint
The prompt that drove the session:
kestrel-vm checks its maintenance password with a custom bytecode VM. Reverse the VM's instruction set, define the opcodes as an enum, write a disassembler for the embedded bytecode program, recover the password from it, and confirm it by emulating the VM.
A prompt like "Tell me what this crackme does" also works and is a fine way to get oriented. The difference is that a prompt which names the deliverables — an enum, a disassembler, a recovered password, an emulation run — tells Assist what counts as done, so it keeps going until every item has evidence behind it instead of stopping at a summary.
3. Watch Assist work
Every tool call appears in the transcript as a card showing the tool, its target, and a summary of the result; expand a card to see the full output. Between calls, Assist posts one-line progress notes ("The VM is at sub_11D0. Now let me pull the embedded bytecode…"). Here is how the session unfolded.
Survey the binary
Assist started with three reads:
List functions — 20 functions, 13 of them named from the ELF's symbols, 7 default
sub_*names. One unnamed function,sub_11D0, is 690 bytes long and dwarfs everything else.Search strings —
usage: %s <maintenance password>,Maintenance mode unlocked. Welcome, engineer.,Wrong password., andVM error.Decompile
main— which ties the two together:
So sub_11D0 is the interpreter, the 559-byte (0x22F) blob at 0x2080 is the program it runs, and the return value is 1 for accept, 0 for reject, and anything else for a VM fault.
Read the interpreter
Decompiling sub_11D0 showed a classic dispatch loop: a 32-byte register file zeroed with memset (eight 32-bit slots), a program counter, a step budget of 0x186A0 (100,000), a comparison flag, and fifteen handlers arranged as an if/switch tree over the opcode byte:
Each handler reveals its operand layout: register selectors are single bytes masked with & 7, immediates are 32-bit little-endian, and branch displacements are signed 16-bit values relative to the end of the instruction. Those widths are what a disassembler needs.
Dump and disassemble the bytecode
Assist read the 559 bytes at 0x2080, then ran an IDAPython script (Run Python permission) that walks the stream with the operand widths it had just derived.
The first attempt was wrong: it reported 559 "instructions", one per byte. Assist noticed that the count equalled the byte count, found the bug in its own decoder, and re-ran. The clean pass produced 126 instructions ending exactly at 0x22AF, with no branch target landing inside an instruction. The script also wrote the listing to a file so you can keep it.
The program is a length guard (strlen == 12) followed by twelve identical blocks. Each block loads one input byte, XORs it with a per-position key, rotates it, multiplies by 157, adds the position index, masks to a byte, and compares the result with a per-position target. Any mismatch jumps to reject; falling through all twelve reaches accept.
Invert the check
With the constants for all twelve positions extracted from the listing, Assist ran a short standalone Python script (Run Python permission). Per byte the constraint is
157 is odd, so it is invertible modulo 256 (its inverse is 181), and each byte solves directly:
The result was Kestrel#VM26. Re-encrypting those twelve bytes reproduced all twelve targets exactly.
Confirm by emulation
A Python reimplementation can share a misreading with the analysis that produced it, so Assist confirmed against the real code by emulating the interpreter at 0x11D0 with the actual arguments (program at 0x2080, length 0x22F, and a buffer holding the candidate password). See Emulation for what the embedded emulator can do.
Kestrel#VM26
accept
2,852
rax = 1
Kestrel#VM27
reject
2,857
rax = 0
The negative control matters: it shows the emulated interpreter actually distinguishes inputs rather than returning 1 for anything.
Record the findings in the database
Only now did Assist touch the database. Under Ask before changes, this is where capability prompt cards appear: Modify this IDA database for the edits, and Share confirmed findings for the memory write. Each card shows the exact change before you choose Deny, Allow once, or Allow for this session.
Create enum
KestrelVmOpcodewith fifteen members,VM_OP_JNE(0x05) throughVM_OP_ROL(0xE3).Set prototype and rename
sub_11D0→kestrel_vm_run, typed asuint32_t __fastcall kestrel_vm_run(const uint8_t *prog, uint64_t prog_len, const char *input).Rename
unk_2080→kestrel_vm_program, with a repeatable comment describing the 559-byte, 126-instruction program.Remember a memory fact summarizing the opcode set, operand grammar, return codes, and the two addresses, so the next session on this binary starts with that knowledge. See Memory.
All of the database edits are grouped into IDA undo steps, so Ctrl+Z reverts them if you disagree.
4. Read the answer
The final reply leads with the result and how it was confirmed, then shows its work: an assumption register listing each assumption (operand widths, branch semantics, rotate behavior, no hidden input opcode) alongside the test that would have falsified it, the instruction-set table, the disassembler summary with the per-position constants, the recovery math with a worked example, the emulation table, a short list of out-of-scope observations ranked by severity, and the list of database changes.
5. Follow up in the same conversation
The conversation keeps its context, so follow-ups can be short and build on each other. Here are four worth trying.
Make the dispatcher readable
Apply the KestrelVmOpcode enum to the opcode bytes at each compare in kestrel_vm_run so the dispatcher reads as named cases.
Assist scanned the function for cmp al, imm8 instructions whose immediate matched an enum member, found exactly fifteen (one per opcode), and applied the enum to each operand. It then verified that the instruction bytes were unchanged (this is display metadata, not a patch) and re-decompiled:
Check that the job is really done
Is this actually solved? Confirm the password end to end, and tell me what in the database is still unresolved.
Rather than answering from memory, Assist re-checked the database. It tried to run the binary natively to confirm the password end to end (Run shell commands permission), which failed because the sample is a Linux ELF and the host was macOS, so it emulated main instead with argc = 2 and argv[1] = "Kestrel#VM26": the program printed Maintenance mode unlocked. Welcome, engineer. and returned 0; with Kestrel#VM27 it printed Wrong password. and returned 1. It also renamed 21 local variables in kestrel_vm_run (opcode, pc, regfile, cmp_flag, step_budget, …) so the dispatcher reads naturally, then listed the remaining work ranked by value — the register file is mistyped as _QWORD[6] instead of uint32_t[8], the trailing .eh_frame bytes are decoded as code — and asked before applying the one item that changes analysis rather than presentation.
Clean up the remaining names
Right-click a default-named function in the Pseudocode or Disassembly view and pick the rename action under IDA Assist, or type the request yourself:
Give the default-named function at 0x1140 a meaningful name based on its behavior, callers, and string/import usage.
Assist read the function, its callers, and the .init_array / .fini_array entries that reference it, identified the tail call through _ITM_registerTMCloneTable, and renamed it register_tm_clones, explaining the evidence and matching the binary's existing lowercase-underscore naming. A one-line follow-up finished the job:
Rename the remaining default-named functions too.
The remaining four defaults became plt0, deregister_tm_clones, __do_global_dtors_aux, and frame_dummy, leaving zero sub_* names and main and start deliberately untouched because they are real ELF symbols.
Verify a claim you care about
Re-derive the operand encoding of every opcode from the handler disassembly, not from your earlier listing, and tell me if anything changes.
Assist's first pass had described JNE as carrying a "status-register selector" byte before the displacement. Checking each handler's operand fetches in the disassembly, Assist found that the handler at 0x1378 contradicts that: the two bytes after the opcode are the low and high halves of one signed 16-bit displacement, and there is no selector byte. Assist opened its reply with the correction, re-derived the listing under the corrected grammar (same 126 instructions, same twelve targets, same password), and revised the memory fact it had stored earlier so the wrong encoding does not come back in a future session.
The lesson generalizes: when a detail matters, ask Assist to re-derive it from the bytes rather than from its own earlier output.
6. Undo, review, and branch
Undo a database edit. Supported edits are grouped into IDA undo steps; press Ctrl+Z in IDA. See Tools & Actions → Undo, conversation rollback, and branching.
Review what was remembered. Open Settings → Memory (or type
/memory) to see the three facts this session saved — the instruction set, the password, and the function map — and edit or delete any of them.Try a different theory. Click Fork on an earlier message to branch the conversation. Both branches stay, and Settings → Tree (
/tree) switches between them. Branching restores the model's context, not the database; use Ctrl+Z for that.Keep the transcript.
/exportsaves the conversation as a self-contained HTML file, and Settings → Sessions (/sessions) lets you resume or review past conversations, including every database edit and script they ran.
What's next?
Emulation — the CPU and whole-process emulation surfaces used to confirm the password.
Memory — how per-binary facts are stored, injected into prompts, and revised.
Tools & Actions — the tool surface, right-click actions, and suggestion pills.
Tool Catalog — every tool with its permission gate and mutation behavior.
Permissions & Privacy — capability prompt cards and confidentiality rules.
Last updated
Was this helpful?
