REA
Use REA when a claim depends on a shipped binary or package, decompilation,
requested runtime evidence, or comparison with
behavior not established by available source. For ordinary analysis of a
complete source repository, use normal repository tools and do not run REA
readiness or provider commands.
Connect only when needed
Installing this skill supplies instructions; it does not register the REA MCP
server, install analysis engines, or add tools to an already-running agent.
The exception is a Claude Code or Codex plugin install: the plugin bundles
this skill and registers its own rea server, outside the state that
rea setup and rea doctor manage.
If REA tools are available and their registration is not known to be stale,
proceed directly to the target. Do not run diagnostics or setup before every
investigation. Use the connected server's actual tool list and input schemas;
a skill installed from repository main may describe capabilities absent from
an older npm release. Keep complete inline Evidence when that server does not
advertise retained references.
If tools are absent, a call is blocked by the client, or a required provider is
unavailable, read connection and recovery.
Diagnose the observed blocker, continue useful supported work, and resume the
original task after repair. Client approval, shell PATH, registration and engine
availability have different remedies; avoid repeating setup for all of them.
If the host times out without a REA result, do not repeat the unchanged call or
assume work stopped. Read the recovery guide's deadline distinction before retrying.
If the MCP connection drops, retry that call once only when it is safe to
repeat or known not to have started. If it may already have changed the
target, or it fails again, tell the user and ask them to restart the MCP
client. If REA could not start its connection, retry once, then tell the user
and ask them to restart the MCP client. Do not retry a startup failure that
returns the same unchanged result. For plugin installs, follow
plugin recovery.
For setup-owned registrations, run rea doctor when REA could not start
or tools stay missing after that restart. For cleanup_incomplete, a retryable
capacity limit, or configuration_invalid, follow the recovery guide's ladder
before asking for a restart. Read that guide before a second repair attempt.
Choose the installation owner before repairing registration. Plugin installs use
plugin recovery;
only setup-owned registrations use the guide's
registration repair plan.
A plugin-only doctor result of missing does not call for rea setup.
REA setup never installs or upgrades Node.js, npm, Homebrew, Java, Ghidra, IDA,
JADX, Kuna, Binwalk, or Unblob. Use existing prerequisites; do not install unrelated
software to repair MCP registration. For an unsupported client, use manual stdio
registration with an existing installation’s absolute runtime and entry script, or continue through the CLI.
A concrete CLI fallback for an operator-supplied JavaScript tree or ASAR is:
npx -y rea-agents@latest analyze-javascript-application /absolute/path/to/app --json
No MCP registration or native engine is required. Read the returned Evidence,
graph, limitations, and unknowns with the same care as an MCP result; the CLI
returns the Evidence record directly. This fallback does not establish that
MCP is configured. Native CLI tasks still require their selected engine.
Prefer an existing rea CLI. When none is installed and REA package acquisition
is within the authorized scope, use npx -y rea-agents@latest in its place from a
trusted directory outside the target project, with absolute target paths. Managed
setup binds the current installation directly; retain its runtime and package
cache entry, or restore that installation before repairing its registration.
For setup-owned registration, configuration repair starts with a read-only setup plan; show paths, backups and
skill replacement before applying authorized changes. Preserve existing approval
and target-execution boundaries.
Route the target first
Choose the first tool from the target the user supplied. Use open_binary for
active-target native or archive workflows; target-free tools take their own
explicit path or endpoint and do not need it.
ASAR or extracted JavaScript/Electron tree:
analyze_javascript_application.
Archive/package member inventory (ZIP/APK/IPA/MSIX/AppX, DMG, or a PyInstaller
executable): open_binary with the supplied local path; use inspect_artifact
when its graph and findings help answer the question. A PyInstaller CArchive
is the application layer; the bootloader is only the native prefix. Start with
detail: "summary" for large inventories, then use retained inventory views
for selected member fields/pages. A complete small inventory can cost less
than extra calls and schemas. Runtime options are metadata, not files.
Compact delivery still inventories and hashes members. See the
Python packaged applications guide.
Bun --compile executable: open_binary, then inspect_artifact; the Bun
module graph is the application layer. Extract stored modules and analyze the
JavaScript. See Bun standalone executables.
Apple app plist, Interface Builder, asset catalog, or keyed archive resources:
open_bundle_resources, then the selected resource tool. This does not
require CFBundleExecutable or a deep provider. Resource sessions have no
executable digest or binary snapshot; use open_binary for native code.
Android APK code, classes, methods, or incoming references:
inspect_android_package, then focused Android tools when advertised.
Archive member inventory still uses the archive route above.
Managed PE/CLI assembly: inspect_managed_artifact.
Firmware image: inspect_firmware_regions when advertised. Use
extract_firmware when extraction is requested, with a caller-selected new
absolute output directory. These tools use caller-supplied Binwalk/Unblob on
Linux; see the firmware guide.
ESP32-family app or bootloader image (0xE9 magic): inspect_artifact
without a provider; see the ESP section of references/native-and-artifacts.md.
.NET NativeAOT PE/ELF: native Ghidra analysis. Native code can yield pseudocode;
consult the NativeAOT workflow in references/native-and-artifacts.md for
optional metadata recovery and its supported host/layout boundary.
Native program behavior, live calls, instrumentation, or command-run effects:
choose the matching native runtime workflow.
open_binary and trace_native_values establish static facts; they do not
observe execution. Runtime tools have distinct launch, attach, mutation and
cleanup effects, and do not require a preliminary static session unless their
own contract says so.
User-owned browser page already open: list_browser_targets.
Browser action the agent must perform (click, type, navigate):
capture_browser_scenario with declared actions. See
runtime observation for connect/launch
and the focused follow-up browser tools.
Agent environment (AgentEnv bundle) of a web application: read
environments before recording; it records with
capture_browser_scenario and writes the bundle with export_environment_bundle.
Fiddler Everywhere traffic or a native .saz capture: read the
Fiddler workflow.
Inspect saved SAZ with inspect_web_network_capture and format: "saz";
connect Everywhere's separate MCP server for live traffic.
Retained HAR/SAZ/native mitmproxy/aioquic qlog capture: inspect_web_network_capture. Select
original record ordinals when useful; inspect producer fields and byte/number
sidecars without fetching recorded URLs or claiming live attribution. HAR/SAZ/qlog
old-generation heap is REA_CAPTURE_DECODER_OLD_GENERATION_MIB (default 192 MiB,
floor 8, maximum 16384), set where REA starts. Host memory and NODE_OPTIONS do not
raise it. See
historical captures for the exact upstream
profile and credential exclusions. Qlog support starts with aioquic 1.5.0
JSON 0.3; stream coverage and endpoint loss declarations do not recover bodies
or establish network loss. Prefer detail summary, then kind qlog trace/stream
pages; select one trace, stream ID and direction for contribution/range pages.
Facts retain all-recorded-events-before-selection scope. Other qlog layouts
and PCAP correlation are unsupported.
User-owned Electron runtime already open: list_electron_targets. Before an electron-main Inspector attempt, check packaged fuses with inspect_electron_fuses; disabled EnableNodeCliInspectArguments means the app ignores --inspect.
Packet-field discovery: inspect_packet_fields searches installed protocols
and field names/types before choosing fields for inspect_packet_capture.
Query/page the relevant records; registrations do not establish observed traffic.
Recorded packet captures: inspect_packet_capture with selected TShark fields,
display filters and decode-as rules. Requires Linux, util-linux prlimit and
TShark 4.x on an absolute PATH entry or via the optional absolute
REA_TSHARK_COMMAND override; see
capture guide.
Packet limits count input packets before filtering. Output defaults to 50 matching
frames; use match_offset / match_limit for later pages, or explicit null
limit for complete matching output. Preserve the source digest across pages.
This does not perform live capture.
For address/DNS/SNI/protocol summaries use inspect_pcap_capture with MCP
detail summary, then retained kind pcap pages. Requires Wireshark 4.x tshark
and capinfos, with Linux prlimit or Windows Job Objects; see
packet summaries.
Select an exact DNS question for address pages; page exhaustion does not prove
network completeness. This reads recordings and does not acquire traffic.
Decoder discovery: inspect_signal_decoders searches installed decoder IDs
or selected decoder help, including channels and options. Query and page the
relevant details before choosing settings; this does not scan hardware.
Recorded logic/signal traces: decode_signal_recording with explicit decoder,
channel and protocol settings. On Linux with util-linux prlimit, supply sigrok-cli 0.7.2 through
REA_SIGROK_COMMAND; see recording guide.
Output defaults to 50 literal lines; select annotation classes and page with
line_offset / line_limit, or explicit null for all remaining output.
Window counts are display lines, not annotations or samples. Preserve source digests across pages.
This reads existing files; it does not acquire hardware signals.
Explicit local WebAssembly artifact: inspect_wasm_artifact. Supply WABT 1.0.42
through REA_WABT_BIN_DIRECTORY; retain exact byte/tool identity and decoded WAT.
Select JavaScript glue and candidate paths explicitly and preserve URL/path
ambiguity. No implicit fetch or target execution; WAT is not original source.
See the WASM guide.
Explicit local Android APK (or ZIP/AAB) signing: inspect_apk_signature.
Prefer its summary or selected signer/digest/lineage page; retain complete
Evidence and use inspect_analysis_view kind apk-signature for follow-ups.
Reports which schemes are present (v1 JAR, v2, v3, v3.1), each signer's
certificate SHA-256 fingerprint (v1 included, from its PKCS#7 block), v3 key-rotation lineage, source stamp, and
whether each signed digest still matches the bytes (self-consistency). This
is identity and integrity, not a trust or authenticity verdict.
See the APK signature guide.
Explicit local EVM bytecode carrier: inspect_evm_interface with caller-selected
raw or hex encoding. The owned worker deadline is timeout_ms (default
30000 ms, range 1..2147483647, next call). It does not raise the fixed byte,
address-space, or CPU allowances. Preserve carrier/decoded digests and treat selectors,
argument strings and mutability as inferred candidates; this performs no chain
lookup or target execution. For the complete inferred interface without hex or
duplicate stdout, discover support and select detail: "summary"; complete
Evidence stays retained under its original identity. Use the returned
parent_evidence_id for exact function or bytecode_hex/stdout/stderr pages.
Candidate coverage does not establish interface completeness. See the
EVM bytecode guide.
Embedded Go compiler, module or build-setting metadata: inspect_go_binary
with the explicit local file. This built-in target-free inspection requires no
Go installation or disassembler. Preserve raw module bytes and source ranges;
absent metadata does not prove a binary is not Go, and unparsed text records
remain explicit. See the
Go binary guide.
Embedded CUDA/HIP code objects: inspect_gpu_code_objects; inventory targets
first, then decode selected payloads and query retained GPU Evidence.
Bundled GGUF or safetensors model declarations: inspect_model_artifact
with the explicit local file. Default header hashing leaves full-file identity
unknown; hash: "full" additionally reads all weights for SHA-256. MCP returns
retained summaries; optional view selects one page in the initial call. Use
inspect_analysis_view kind model-artifact for
batched metadata keys, tensor names or type totals, selected fields and pages.
Preserve header-scoped indices and array preview omissions; do not infer model
behavior from declared architecture or tensor types. See the
model file guide.
Unity IL2CPP names, member owners and string literals from global-metadata.dat:
inspect_il2cpp_metadata with the explicit local file; MCP defaults to compact
counts. Query sections, images, types, methods, fields, properties, events,
parameters or string_literals through inspect_analysis_view
with the returned parent_evidence_id, using exact filters, batch indices and
selected fields. Parameters accept method_indices, avoiding a scan of all
parameter pages. Missing collections in historical Evidence remain unknown.
Versions 24, 27, 29, 31 and 39; no Unity, IL2CPP
binary or disassembler is run. Unrecognized magic (possibly encrypted) and
other versions are unsupported. Optional matching binary_path enables static native addresses and type references; query method_addresses with indices or addresses/states, preserving every shared-body method and both artifact identities. Without a linked binary native counts remain unknown. Byte-pattern fallback is inferred; no runtime behavior or same-build pairing is proved. See the
IL2CPP metadata guide.
Embedded cargo-auditable Rust dependency metadata: inspect_rust_binary
with the explicit local ELF, PE, or thin Mach-O file. This built-in
target-free inspection requires no Rust installation or disassembler. Preserve
package order, dependency indices, and the section file range. A missing
.dep-v0 section is null metadata, not proof the binary has no dependencies.
A rustc commit hash is an inference from a read-only /rustc/<40-hex>/ path.
For selected crates, use view: {collection: "packages", names: [...], fields: ["name", "version", "source"]} on the first call; explicitly include
dependencies for direct index references. Use detail: "summary" for counts
and ranges, or retained inspect_analysis_view Rust package/edge pages for
subsequent filters. Keep the complete parent Evidence accessible; CLI compact
delivery requires --evidence_output.
See the
Rust binary guide.
PE Authenticode certificate table: inspect_pe_certificates with the explicit
local PE32/PE32+ file. This built-in target-free inspection requires no
Windows SDK. Preserve WIN_CERTIFICATE ranges, types, payload SHA-256, and
PKCS#7 signer/X.509 identity fields, including subject_key_identifier_hex
when the signer uses that form. A missing security directory is observed
absence of that table, not proof the image is unsigned in every catalog sense.
Signatures are not verified. See the
PE certificate guide.
PE import and delay-load tables: inspect_pe_imports with the explicit
local PE32/PE32+ file. This built-in target-free inspection requires no
Windows SDK. Preserve DLL names, named and ordinal functions, ILT/IAT RVAs,
delay-load descriptors, and the pefile import hash of the standard import
table. A missing import directory is observed absence of that table, not
proof the image never imported APIs through another table. Bound snapshots
and loaded IAT contents remain unobserved. See the
PE import guide.
PE TLS callbacks and load configuration: inspect_pe_load_config with the
explicit local PE32/PE32+ file. This built-in target-free inspection requires
no Windows SDK. Preserve callback VAs as strings with their RVA, file offset
and section, and the size-covered security cookie, SafeSEH, CFG,
EH-continuation and XFG fields. Guard-flag mitigation claims are inferred
linker declarations, not proof of enforcement. A missing directory is observed
absence of that declaration. See the
PE load configuration guide.
ELF note tables: inspect_elf_notes with the explicit local ELF32/ELF64
file. This built-in target-free inspection requires no disassembler. Preserve
PT_NOTE and SHT_NOTE ranges, owners, types, descriptor SHA-256, and GNU
build-id or ABI-tag fields. A missing table is observed absence of those
declarations, not proof the image never carried notes. See the
ELF notes guide.
Apple .ips crash reports: inspect_apple_ips with the explicit local
file. This built-in target-free inspection requires no Xcode, atos, or
pwntools. Preserve first-line metadata, bug_type as a string, process and
exception facts, lossless integer registers, usedImages UUIDs, and
documented classification matches. Only bug_type "309" yields a crash
body; other types, including "288" stackshots, return no crash result.
Opened Mach-O and dSYM UUID joins remain unobserved. See the
Apple IPS guide.
Linux kernel module metadata: inspect_kernel_module with the explicit local
ELF32/ELF64 relocatable file. This built-in target-free inspection requires
no Linux host or modinfo. Preserve .modinfo key order and duplicate keys,
__versions CRC hex, section file ranges, and the appended signature
trailer's PKCS#7 SHA-256. A missing section is observed absence when section
names are known, not proof the module never carried that metadata.
struct module is not decoded. The signature is not validated. gzip, xz, and
zstd containers are unsupported; decompress into a separate file with an
external codec utility, then inspect the decompressed ET_REL image. See the
kernel module guide.
CPython 3.7–3.13 .pyc header, nested marshal code objects and bytecode
identity: inspect_python_pyc with the explicit local file. This built-in
target-free inspection requires no Python installation. Preserve magic,
PEP 552 hash or mtime/size, nested names, and bytecode SHA-256. Bytecode is
not decompiled, and a decoded header does not prove the matching .py is
present. See the
CPython pyc guide.
Erlang BEAM IFF container: inspect_erlang_beam with the explicit local
.beam file. This built-in target-free inspection requires no Erlang
installation. Preserve chunk names, atom order, export/import/lambda tables,
and the Code header. For selected facts, prefer detail: "summary" plus a
beam view (collection, names/indices, fields and paging), retaining the full
Evidence. CLI summary requires --evidence_output. Missing table counts stay
null; decoded empty tables count zero. Bytecode is not executed. See the
Erlang BEAM guide.
Explicit local SQLite database snapshot: inspect_sqlite_database. Inspect
with Node.js 24.x >=24.15 or 26+ providing native SQLite limits. Read schema
first (compact inventory by default), or select an exact ordinary table
and columns when rows are needed. Defaults are selected-table schema and
20 rows; request schema_scope: "database" for the complete stored schema. Preserve both database and existing sibling WAL identity; row samples
report truncation and have unspecified order. Use a quiescent snapshot rather
than assuming a live database/WAL pair was copied atomically. See the
SQLite guide.
Explicit Linux ELF file for offline layout, symbols, relocations or static
mitigation evidence: inspect_binary_layout. This target-free operation uses
caller-supplied pwntools without opening a disassembler database. Preserve its
raw locations and inference/coverage limits; see the
offline binary guide.
Supplied Linux x86-64 ELF core: inspect_recorded_crash. Read every recorded
thread, raw note and source-bound register without opening a live target.
Historical PIDs do not select live processes. Request include_debugger_context
only when core-only mapping candidates help; see the
recorded crash guide.
PE resource type/name/language trees and static icon group references:
inspect_pe_resources with an explicit path. This portable operation requires
no active target or engine; opaque payloads retain file ranges and SHA-256.
PE export directories and ELF dynamic-symbol exports: inspect_native_exports
with an explicit path; portable, no active target or engine.
Native executable, library, or analysis database: open_binary, then
use focused analysis tools directly; call binary_overview when metadata or
inventory context is useful and available from the selected provider.
For an existing IDA MCP configuration, use open_binary with the original
input binary and provider_id: "ida"; do not pass an .idb or .i64 database.
The legacy attached profile binds the already-open GUI input by SHA-256 and
leaves its database open. The modern headless profile creates and closes an
owned private database without saving. Installation and registration reuse
mrexodia/ida-pro-mcp; see the
IDA provider guide.
For migration to the separate native IDA MCP plugin, follow the guide's
legacy attached migration.
Replace the upstream registration explicitly; modern mrexodia tools are not the
native profile. Native attachment preserves the database but does not provide
direct callers; check session availability and the guide's verification limits.
Proceed directly to analyze_function, pseudocode, or function/string searches
after opening; IDA does not supply binary_overview. Consult session availability
when composing broader workflows. Modern direct callers and unsupported dossier
facets remain unknown; live IDA results are not replayed from snapshots.
With REA_KUNA_COMMAND configured, provider_id: "kuna" answers procedure
lists, lookups, pseudocode, assembly and analyze_function from Kuna's cached
whole-program export. Callers/callees use a separate body-free graph shared by
the session; xrefs returns exact-address incoming sites and filters forwarding
aliases. These queries and inventory lookups do not trigger a C export. Indirect
targets remain unknown and can make relationship coverage partial. Reference
caches expire on close; a fresh CLI process repeats the native reference walk.
Typed references, CFG, raw-memory tools and annotations remain unsupported. A cold first
answer can come from a single-function run (its limitations say so); assembly
waits for the export. For pseudocode and assembly, raw_result.source names the
cached .c/.asm file and byte span, which you may search directly instead of
calling per function. See the
Kuna provider guide.
If the user says only "my app" without a name, path, or target already selected
for this task, ask which app before searching for artifacts. Paths in unrelated
saved reports and nearby test fixtures do not select the user's target. Resolve
an actual human-readable app name to one clear installed artifact when possible;
ask when matches are ambiguous. Never choose an example app on the user's behalf.
In a target-free session, use open_binary to bind any archive/package or
native target whose analysis tool operates on the active target. Do not call an
unadvertised tool; inspect binary_session with {} and its
result.tool_availability for availability reasons and remediation. Expand each
group's names into entries, inheriting the inventory-level client requirements
unless the group overrides them. The grouped name union is the complete tool
inventory; use tools/list for canonical tool schemas. The default summary keeps
each provider candidate's availability and target-support status, code and
reason; omitted_fields lists what it leaves out. Request {"detail": "complete"}
only when you need provider diagnostics, candidate capability sets, or tool
surface, effect and annotation flags; in those closed flag vocabularies, listed
flags are true and omitted known flags are false. Provider candidate facts
describe possible providers, while top-level session capabilities describe the
current route and analysis_provider_binding names the selected provider. Do
not treat those scopes as interchangeable.
For a Ghidra startup timeout on a large native target, follow
deadline recovery
before abandoning deep analysis or repeating the same cold import. The default
330 seconds can be changed for new startup attempts through
update_analysis_settings using ghidra.startup_timeout_ms. Changing the
server's launch environment instead requires a new REA process.
Work summary-first
Start with the default result and use its inline Evidence and graph context.
For a JavaScript application or ELF layout whose size is unknown or large,
call analyze_javascript_application or inspect_binary_layout with
"detail": "summary", then inspect the retained parent_evidence_id with
inspect_analysis_view. Over MCP, analyze_function is summary-first without
a flag: its default reply is the summary, and the complete dossier stays
retained under parent_evidence_id for facet paging. Pass that ID as a
retained-evidence reference to compare_functions, or inside
match_native_functions left_observations/right_observations or
build_call_path.functions; request "detail": "complete" only when the
dossier must travel inline.
Use the same exact-reference form in other advertised logical Evidence inputs,
including optional sources, arrays and nested sources across domains. Each
source can independently be inline or retained; preserve its source identity,
coverage, partial facts and unknowns. A summary or inspection page has its own
Evidence ID: use normalized_result.parent_evidence_id when the consumer needs
the complete source. For portable CLI follow-ups, commands advertising
--evidence-bundle resolve references from that selected exported bundle.
See Evidence composition for scope and
recovery; file selectors are supported only where explicitly advertised.
Page module identities and select the returned node_id before requesting an
item; a single file path can represent several graph roles. Do not repeat an
identical analysis or rejected call without a changed input or resolved blocker.
Recheck session state when a lifecycle change makes that status useful.
Make a focused follow-up only when the
returned result leaves a specific question unanswered.
If MCP reports resource_constraint with details.resource: "transport", call
inspect_analysis_view with its reported same-session Evidence reference for a
summary, one section/module, or a stable page. Use trace_application_feature
once a seed is known, or call export_evidence_bundle to write the complete
session to a selected path. The analysis remains complete in the ledger; avoid
repeating it merely to request the same oversized response. Complete CLI JSON
output also streams without a single MCP frame.
When the retained parent ID is unknown, use get_evidence_bundle with
detail: "summary" and exact filters for operation, target SHA-256,
analysis-profile digest or canonical procedure address. Select its returned
Evidence ID for the next view instead of requesting the complete bundle.
retention: "complete-record" means the whole record is stored; native
value-flow truncation and unknown metadata remain separate. For an exported
portable bundle, use rea inspect-evidence-bundle with JSON containing path,
detail: "summary" and the same filters. Reading that file still requires
validating its full contents within the local memory budget.
A client can also truncate a successful tool result without a REA transport
error. Treat that preview as incomplete; use the retained parent ID for smaller
views or export when the full record is needed. Do not parse the preview as
canonical JSON or repeat the producer. For JavaScript, read the
module-view and trace recipes before
drilling into a large graph; a broad bidirectional trace can expand unrelated
containment relationships even after summary analysis.
Every conclusion must distinguish observations, inferences, and unknowns. Cite
Evidence IDs, preserve limitations and incomplete coverage, and never imply
that static analysis observed execution. Runtime requests execute the declared
target and lifecycle; do not broaden the target or action beyond those fields.
Within the user's requested investigation, call available analysis tools
directly. REA does not require permission grants or per-call approval flags.
The agent client can independently require approval. Follow the declared request
scope and the host's actual access requirements; use the recovery guide for an
observed client-policy rejection.
Plan broader investigations
For requests that span multiple features or subsystems, use a staged workflow:
- Turn the request into a checklist of questions and the evidence each answer
needs. Resolve target identity and constraints from the conversation and
workspace before asking for information again.
- Inspect the current REA session, artifact identity, saved analysis database,
bookmarks, and prior evidence. Reuse matching state; do not open duplicate
sessions or repeat identical analysis.
- Start with the smallest useful overview or inventory. Follow each question
from its entry point through relevant data and state changes to its result.
Batch related operations around a specific hypothesis, then expand only when
the returned evidence leaves a concrete gap.
- Inspect relevant packaged resources and configuration alongside code when
they affect the question. Use format-aware inventory and parsers; do not
infer behavior from filenames, strings, or layout alone.
- Corroborate a conclusion with the evidence type it requires. Use runtime
observation only when static evidence cannot answer the question and the
required host runtime and OS access are available. For JavaScript behavior,
run probes against the actual app through the available browser, Electron,
or process capture workflow.
- Decompose work into independent questions. When parallel workers are
available and the questions do not depend on one another, assign distinct
scopes, point workers to existing evidence, and ask them to return sources,
conclusions, and unresolved gaps. Otherwise, work sequentially.
- Keep a concise finding ledger linking each conclusion to Evidence IDs,
confidence/evidence type, search boundary, and remaining unknowns. Update
the shared index or investigation report so later passes can reuse results.
Before finishing, revisit the original checklist. Mark each question as
answered, partially answered, or unresolved based on its evidence; keep
bounded negative searches bounded, and do not describe a broad investigation
as complete while required questions remain open.
Read only the relevant guide
- Native binaries, managed assemblies, archives, and extraction:
references/native-and-artifacts.md
- ASARs, extracted JavaScript, feature tracing, and version comparison:
references/javascript-applications.md
- Android APK declarations, classes, methods, and static references:
references/android-applications.md
- Native instrumentation, debugger and process capture; browser/Electron
observation; static/runtime comparison:
references/runtime-observation.md
- Evidence paging, comparisons, residual unknowns, and verification:
references/evidence-workflows.md
- Agent environments (AgentEnv bundles) of a web application, recorded from
a live instance or a HAR:
references/environments.md
Finish the task
Explain findings in plain language and tie them to returned evidence. When the
user asks to build something, use normal coding tools and separate observed
behavior from design choices. Close an opened native session with
close_binary when the investigation is complete.
1---2name: reverse-engineer-anything3description: Reverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.4metadata:5 source: https://skillmd.com/skills/cyberstrikeus/reverse-engineer-anything6 version: "59"7---89# REA1011Use REA when a claim depends on a shipped binary or package, decompilation,12requested runtime evidence, or comparison with13behavior not established by available source. For ordinary analysis of a14complete source repository, use normal repository tools and do not run REA15readiness or provider commands.1617## Connect only when needed1819Installing this skill supplies instructions; it does not register the REA MCP20server, install analysis engines, or add tools to an already-running agent.21The exception is a Claude Code or Codex plugin install: the plugin bundles22this skill and registers its own `rea` server, outside the state that23`rea setup` and `rea doctor` manage.2425If REA tools are available and their registration is not known to be stale,26proceed directly to the target. Do not run diagnostics or setup before every27investigation. Use the connected server's actual tool list and input schemas;28a skill installed from repository main may describe capabilities absent from29an older npm release. Keep complete inline Evidence when that server does not30advertise retained references.3132If tools are absent, a call is blocked by the client, or a required provider is33unavailable, read [connection and recovery](references/connection-and-recovery.md).34Diagnose the observed blocker, continue useful supported work, and resume the35original task after repair. Client approval, shell PATH, registration and engine36availability have different remedies; avoid repeating setup for all of them.37If the host times out without a REA result, do not repeat the unchanged call or38assume work stopped. Read the recovery guide's deadline distinction before retrying.39If the MCP connection drops, retry that call once only when it is safe to40repeat or known not to have started. If it may already have changed the41target, or it fails again, tell the user and ask them to restart the MCP42client. If REA could not start its connection, retry once, then tell the user43and ask them to restart the MCP client. Do not retry a startup failure that44returns the same unchanged result. For plugin installs, follow45[plugin recovery](references/connection-and-recovery.md#rea-installed-as-a-client-plugin).46For setup-owned registrations, run `rea doctor` when REA could not start47or tools stay missing after that restart. For `cleanup_incomplete`, a retryable48capacity limit, or `configuration_invalid`, follow the recovery guide's ladder49before asking for a restart. Read that guide before a second repair attempt.5051Choose the installation owner before repairing registration. Plugin installs use52[plugin recovery](references/connection-and-recovery.md#rea-installed-as-a-client-plugin);53only setup-owned registrations use the guide's54[registration repair plan](references/connection-and-recovery.md#repair-registration-when-needed).55A plugin-only doctor result of `missing` does not call for `rea setup`.5657REA setup never installs or upgrades Node.js, npm, Homebrew, Java, Ghidra, IDA,58JADX, Kuna, Binwalk, or Unblob. Use existing prerequisites; do not install unrelated59software to repair MCP registration. For an unsupported client, use manual stdio60registration with an existing installation’s absolute runtime and entry script, or continue through the CLI.6162A concrete CLI fallback for an operator-supplied JavaScript tree or ASAR is:6364```bash65npx -y rea-agents@latest analyze-javascript-application /absolute/path/to/app --json66```6768No MCP registration or native engine is required. Read the returned Evidence,69graph, limitations, and unknowns with the same care as an MCP result; the CLI70returns the Evidence record directly. This fallback does not establish that71MCP is configured. Native CLI tasks still require their selected engine.72Prefer an existing `rea` CLI. When none is installed and REA package acquisition73is within the authorized scope, use `npx -y rea-agents@latest` in its place from a74trusted directory outside the target project, with absolute target paths. Managed75setup binds the current installation directly; retain its runtime and package76cache entry, or restore that installation before repairing its registration.77For setup-owned registration, configuration repair starts with a read-only setup plan; show paths, backups and78skill replacement before applying authorized changes. Preserve existing approval79and target-execution boundaries.8081## Route the target first8283Choose the first tool from the target the user supplied. Use `open_binary` for84active-target native or archive workflows; target-free tools take their own85explicit path or endpoint and do not need it.8687- ASAR or extracted JavaScript/Electron tree:88 `analyze_javascript_application`.89- Archive/package member inventory (ZIP/APK/IPA/MSIX/AppX, DMG, or a PyInstaller90 executable): `open_binary` with the supplied local path; use `inspect_artifact`91 when its graph and findings help answer the question. A PyInstaller CArchive92 is the application layer; the bootloader is only the native prefix. Start with93 `detail: "summary"` for large inventories, then use retained inventory views94 for selected member fields/pages. A complete small inventory can cost less95 than extra calls and schemas. Runtime options are metadata, not files.96 Compact delivery still inventories and hashes members. See the97 [Python packaged applications guide](https://github.com/morluto/rea/blob/main/docs/python-packaged-applications.md).98- Bun `--compile` executable: `open_binary`, then `inspect_artifact`; the Bun99 module graph is the application layer. Extract stored modules and analyze the100 JavaScript. See [Bun standalone executables](https://github.com/morluto/rea/blob/main/docs/bun-standalone.md).101- Apple app plist, Interface Builder, asset catalog, or keyed archive resources:102 `open_bundle_resources`, then the selected resource tool. This does not103 require `CFBundleExecutable` or a deep provider. Resource sessions have no104 executable digest or binary snapshot; use `open_binary` for native code.105- Android APK code, classes, methods, or incoming references:106 `inspect_android_package`, then focused Android tools when advertised.107 Archive member inventory still uses the archive route above.108- Managed PE/CLI assembly: `inspect_managed_artifact`.109- Firmware image: `inspect_firmware_regions` when advertised. Use110 `extract_firmware` when extraction is requested, with a caller-selected new111 absolute output directory. These tools use caller-supplied Binwalk/Unblob on112 Linux; see the [firmware guide](https://github.com/morluto/rea/blob/main/docs/firmware-analysis.md).113- ESP32-family app or bootloader image (`0xE9` magic): `inspect_artifact`114 without a provider; see the ESP section of `references/native-and-artifacts.md`.115- .NET NativeAOT PE/ELF: native Ghidra analysis. Native code can yield pseudocode;116 consult the NativeAOT workflow in `references/native-and-artifacts.md` for117 optional metadata recovery and its supported host/layout boundary.118- Native program behavior, live calls, instrumentation, or command-run effects:119 choose the matching [native runtime workflow](references/runtime-observation.md#native-runtime-questions).120 `open_binary` and `trace_native_values` establish static facts; they do not121 observe execution. Runtime tools have distinct launch, attach, mutation and122 cleanup effects, and do not require a preliminary static session unless their123 own contract says so.124- User-owned browser page already open: `list_browser_targets`.125- Browser action the agent must perform (click, type, navigate):126 `capture_browser_scenario` with declared actions. See127 [runtime observation](references/runtime-observation.md) for connect/launch128 and the focused follow-up browser tools.129- Agent environment (AgentEnv bundle) of a web application: read130 [environments](references/environments.md) before recording; it records with131 `capture_browser_scenario` and writes the bundle with `export_environment_bundle`.132- Fiddler Everywhere traffic or a native `.saz` capture: read the133 [Fiddler workflow](references/runtime-observation.md#fiddler-everywhere-traffic-debugging).134 Inspect saved SAZ with `inspect_web_network_capture` and `format: "saz"`;135 connect Everywhere's separate MCP server for live traffic.136- Retained HAR/SAZ/native mitmproxy/aioquic qlog capture: `inspect_web_network_capture`. Select137 original record ordinals when useful; inspect producer fields and byte/number138 sidecars without fetching recorded URLs or claiming live attribution. HAR/SAZ/qlog139 old-generation heap is `REA_CAPTURE_DECODER_OLD_GENERATION_MIB` (default 192 MiB,140 floor 8, maximum 16384), set where REA starts. Host memory and `NODE_OPTIONS` do not141 raise it. See142 [historical captures](https://github.com/morluto/rea/blob/main/docs/web-network-captures.md) for the exact upstream143 profile and credential exclusions. Qlog support starts with aioquic 1.5.0144 JSON 0.3; stream coverage and endpoint loss declarations do not recover bodies145 or establish network loss. Prefer detail summary, then kind qlog trace/stream146 pages; select one trace, stream ID and direction for contribution/range pages.147 Facts retain all-recorded-events-before-selection scope. Other qlog layouts148 and PCAP correlation are unsupported.149- User-owned Electron runtime already open: `list_electron_targets`. Before an electron-main Inspector attempt, check packaged fuses with `inspect_electron_fuses`; disabled `EnableNodeCliInspectArguments` means the app ignores `--inspect`.150- Packet-field discovery: `inspect_packet_fields` searches installed protocols151 and field names/types before choosing fields for `inspect_packet_capture`.152 Query/page the relevant records; registrations do not establish observed traffic.153- Recorded packet captures: `inspect_packet_capture` with selected TShark fields,154 display filters and decode-as rules. Requires Linux, util-linux prlimit and155 TShark 4.x on an absolute `PATH` entry or via the optional absolute156 `REA_TSHARK_COMMAND` override; see157 [capture guide](https://github.com/morluto/rea/blob/main/docs/packet-captures.md).158 Packet limits count input packets before filtering. Output defaults to 50 matching159 frames; use `match_offset` / `match_limit` for later pages, or explicit null160 limit for complete matching output. Preserve the source digest across pages.161 This does not perform live capture.162 For address/DNS/SNI/protocol summaries use `inspect_pcap_capture` with MCP163 detail summary, then retained kind pcap pages. Requires Wireshark 4.x tshark164 and capinfos, with Linux prlimit or Windows Job Objects; see165 [packet summaries](https://github.com/morluto/rea/blob/main/docs/pcap-analysis.md).166 Select an exact DNS question for address pages; page exhaustion does not prove167 network completeness. This reads recordings and does not acquire traffic.168- Decoder discovery: `inspect_signal_decoders` searches installed decoder IDs169 or selected decoder help, including channels and options. Query and page the170 relevant details before choosing settings; this does not scan hardware.171- Recorded logic/signal traces: `decode_signal_recording` with explicit decoder,172 channel and protocol settings. On Linux with util-linux prlimit, supply sigrok-cli 0.7.2 through173 `REA_SIGROK_COMMAND`; see [recording guide](https://github.com/morluto/rea/blob/main/docs/signal-recordings.md).174 Output defaults to 50 literal lines; select annotation classes and page with175 `line_offset` / `line_limit`, or explicit null for all remaining output.176 Window counts are display lines, not annotations or samples. Preserve source digests across pages.177 This reads existing files; it does not acquire hardware signals.178- Explicit local WebAssembly artifact: `inspect_wasm_artifact`. Supply WABT 1.0.42179 through `REA_WABT_BIN_DIRECTORY`; retain exact byte/tool identity and decoded WAT.180 Select JavaScript glue and candidate paths explicitly and preserve URL/path181 ambiguity. No implicit fetch or target execution; WAT is not original source.182 See the [WASM guide](https://github.com/morluto/rea/blob/main/docs/wasm-artifacts.md).183- Explicit local Android APK (or ZIP/AAB) signing: `inspect_apk_signature`.184 Prefer its summary or selected signer/digest/lineage page; retain complete185 Evidence and use `inspect_analysis_view` kind `apk-signature` for follow-ups.186 Reports which schemes are present (v1 JAR, v2, v3, v3.1), each signer's187 certificate SHA-256 fingerprint (v1 included, from its PKCS#7 block), v3 key-rotation lineage, source stamp, and188 whether each signed digest still matches the bytes (self-consistency). This189 is identity and integrity, not a trust or authenticity verdict.190 See the [APK signature guide](https://github.com/morluto/rea/blob/main/docs/apk-signature.md).191- Explicit local EVM bytecode carrier: `inspect_evm_interface` with caller-selected192 `raw` or `hex` encoding. The owned worker deadline is `timeout_ms` (default193 30000 ms, range 1..2147483647, next call). It does not raise the fixed byte,194 address-space, or CPU allowances. Preserve carrier/decoded digests and treat selectors,195 argument strings and mutability as inferred candidates; this performs no chain196 lookup or target execution. For the complete inferred interface without hex or197 duplicate stdout, discover support and select `detail: "summary"`; complete198 Evidence stays retained under its original identity. Use the returned199 `parent_evidence_id` for exact function or `bytecode_hex`/stdout/stderr pages.200 Candidate coverage does not establish interface completeness. See the201 [EVM bytecode guide](https://github.com/morluto/rea/blob/main/docs/evm-bytecode.md).202- Embedded Go compiler, module or build-setting metadata: `inspect_go_binary`203 with the explicit local file. This built-in target-free inspection requires no204 Go installation or disassembler. Preserve raw module bytes and source ranges;205 absent metadata does not prove a binary is not Go, and unparsed text records206 remain explicit. See the207 [Go binary guide](https://github.com/morluto/rea/blob/main/docs/go-binaries.md).208- Embedded CUDA/HIP code objects: `inspect_gpu_code_objects`; inventory targets209 first, then decode selected payloads and query retained GPU Evidence.210- Bundled GGUF or safetensors model declarations: `inspect_model_artifact`211 with the explicit local file. Default header hashing leaves full-file identity212 unknown; `hash: "full"` additionally reads all weights for SHA-256. MCP returns213 retained summaries; optional `view` selects one page in the initial call. Use214 `inspect_analysis_view` kind `model-artifact` for215 batched metadata keys, tensor names or type totals, selected fields and pages.216 Preserve header-scoped indices and array preview omissions; do not infer model217 behavior from declared architecture or tensor types. See the218 [model file guide](https://github.com/morluto/rea/blob/main/docs/model-artifacts.md).219- Unity IL2CPP names, member owners and string literals from `global-metadata.dat`:220 `inspect_il2cpp_metadata` with the explicit local file; MCP defaults to compact221 counts. Query sections, images, types, methods, fields, properties, events,222 parameters or string_literals through `inspect_analysis_view`223 with the returned `parent_evidence_id`, using exact filters, batch indices and224 selected fields. Parameters accept `method_indices`, avoiding a scan of all225 parameter pages. Missing collections in historical Evidence remain unknown.226 Versions 24, 27, 29, 31 and 39; no Unity, IL2CPP227 binary or disassembler is run. Unrecognized magic (possibly encrypted) and228 other versions are unsupported. Optional matching `binary_path` enables static native addresses and type references; query `method_addresses` with indices or addresses/states, preserving every shared-body method and both artifact identities. Without a linked binary native counts remain unknown. Byte-pattern fallback is inferred; no runtime behavior or same-build pairing is proved. See the229 [IL2CPP metadata guide](https://github.com/morluto/rea/blob/main/docs/il2cpp-metadata.md).230- Embedded cargo-auditable Rust dependency metadata: `inspect_rust_binary`231 with the explicit local ELF, PE, or thin Mach-O file. This built-in232 target-free inspection requires no Rust installation or disassembler. Preserve233 package order, dependency indices, and the section file range. A missing234 `.dep-v0` section is null metadata, not proof the binary has no dependencies.235 A rustc commit hash is an inference from a read-only `/rustc/<40-hex>/` path.236 For selected crates, use `view: {collection: "packages", names: [...],237 fields: ["name", "version", "source"]}` on the first call; explicitly include238 `dependencies` for direct index references. Use `detail: "summary"` for counts239 and ranges, or retained `inspect_analysis_view` Rust package/edge pages for240 subsequent filters. Keep the complete parent Evidence accessible; CLI compact241 delivery requires `--evidence_output`.242 See the243 [Rust binary guide](https://github.com/morluto/rea/blob/main/docs/rust-binaries.md).244- PE Authenticode certificate table: `inspect_pe_certificates` with the explicit245 local PE32/PE32+ file. This built-in target-free inspection requires no246 Windows SDK. Preserve WIN_CERTIFICATE ranges, types, payload SHA-256, and247 PKCS#7 signer/X.509 identity fields, including `subject_key_identifier_hex`248 when the signer uses that form. A missing security directory is observed249 absence of that table, not proof the image is unsigned in every catalog sense.250 Signatures are not verified. See the251 [PE certificate guide](https://github.com/morluto/rea/blob/main/docs/pe-certificates.md).252- PE import and delay-load tables: `inspect_pe_imports` with the explicit253 local PE32/PE32+ file. This built-in target-free inspection requires no254 Windows SDK. Preserve DLL names, named and ordinal functions, ILT/IAT RVAs,255 delay-load descriptors, and the pefile import hash of the standard import256 table. A missing import directory is observed absence of that table, not257 proof the image never imported APIs through another table. Bound snapshots258 and loaded IAT contents remain unobserved. See the259 [PE import guide](https://github.com/morluto/rea/blob/main/docs/pe-imports.md).260- PE TLS callbacks and load configuration: `inspect_pe_load_config` with the261 explicit local PE32/PE32+ file. This built-in target-free inspection requires262 no Windows SDK. Preserve callback VAs as strings with their RVA, file offset263 and section, and the size-covered security cookie, SafeSEH, CFG,264 EH-continuation and XFG fields. Guard-flag mitigation claims are inferred265 linker declarations, not proof of enforcement. A missing directory is observed266 absence of that declaration. See the267 [PE load configuration guide](https://github.com/morluto/rea/blob/main/docs/pe-load-config.md).268- ELF note tables: `inspect_elf_notes` with the explicit local ELF32/ELF64269 file. This built-in target-free inspection requires no disassembler. Preserve270 PT_NOTE and SHT_NOTE ranges, owners, types, descriptor SHA-256, and GNU271 build-id or ABI-tag fields. A missing table is observed absence of those272 declarations, not proof the image never carried notes. See the273 [ELF notes guide](https://github.com/morluto/rea/blob/main/docs/elf-notes.md).274- Apple `.ips` crash reports: `inspect_apple_ips` with the explicit local275 file. This built-in target-free inspection requires no Xcode, atos, or276 pwntools. Preserve first-line metadata, `bug_type` as a string, process and277 exception facts, lossless integer registers, usedImages UUIDs, and278 documented classification matches. Only `bug_type` `"309"` yields a crash279 body; other types, including `"288"` stackshots, return no crash result.280 Opened Mach-O and dSYM UUID joins remain unobserved. See the281 [Apple IPS guide](https://github.com/morluto/rea/blob/main/docs/apple-ips.md).282- Linux kernel module metadata: `inspect_kernel_module` with the explicit local283 ELF32/ELF64 relocatable file. This built-in target-free inspection requires284 no Linux host or `modinfo`. Preserve `.modinfo` key order and duplicate keys,285 `__versions` CRC hex, section file ranges, and the appended signature286 trailer's PKCS#7 SHA-256. A missing section is observed absence when section287 names are known, not proof the module never carried that metadata.288 `struct module` is not decoded. The signature is not validated. gzip, xz, and289 zstd containers are unsupported; decompress into a separate file with an290 external codec utility, then inspect the decompressed `ET_REL` image. See the291 [kernel module guide](https://github.com/morluto/rea/blob/main/docs/kernel-modules.md).292- CPython 3.7–3.13 `.pyc` header, nested marshal code objects and bytecode293 identity: `inspect_python_pyc` with the explicit local file. This built-in294 target-free inspection requires no Python installation. Preserve magic,295 PEP 552 hash or mtime/size, nested names, and bytecode SHA-256. Bytecode is296 not decompiled, and a decoded header does not prove the matching `.py` is297 present. See the298 [CPython pyc guide](https://github.com/morluto/rea/blob/main/docs/python-pyc.md).299- Erlang BEAM IFF container: `inspect_erlang_beam` with the explicit local300 `.beam` file. This built-in target-free inspection requires no Erlang301 installation. Preserve chunk names, atom order, export/import/lambda tables,302 and the Code header. For selected facts, prefer `detail: "summary"` plus a303 `beam` view (collection, names/indices, fields and paging), retaining the full304 Evidence. CLI summary requires `--evidence_output`. Missing table counts stay305 null; decoded empty tables count zero. Bytecode is not executed. See the306 [Erlang BEAM guide](https://github.com/morluto/rea/blob/main/docs/erlang-beam.md).307308- Explicit local SQLite database snapshot: `inspect_sqlite_database`. Inspect309 with Node.js 24.x >=24.15 or 26+ providing native SQLite limits. Read schema310 first (compact inventory by default), or select an exact ordinary table311 and `columns` when rows are needed. Defaults are selected-table schema and312 20 rows; request `schema_scope: "database"` for the complete stored schema. Preserve both database and existing sibling WAL identity; row samples313 report truncation and have unspecified order. Use a quiescent snapshot rather314 than assuming a live database/WAL pair was copied atomically. See the315 [SQLite guide](https://github.com/morluto/rea/blob/main/docs/sqlite-databases.md).316- Explicit Linux ELF file for offline layout, symbols, relocations or static317 mitigation evidence: `inspect_binary_layout`. This target-free operation uses318 caller-supplied pwntools without opening a disassembler database. Preserve its319 raw locations and inference/coverage limits; see the320 [offline binary guide](https://github.com/morluto/rea/blob/main/docs/binary-diagnostics.md).321- Supplied Linux x86-64 ELF core: `inspect_recorded_crash`. Read every recorded322 thread, raw note and source-bound register without opening a live target.323 Historical PIDs do not select live processes. Request `include_debugger_context`324 only when core-only mapping candidates help; see the325 [recorded crash guide](https://github.com/morluto/rea/blob/main/docs/recorded-crashes.md).326- PE resource type/name/language trees and static icon group references:327 `inspect_pe_resources` with an explicit path. This portable operation requires328 no active target or engine; opaque payloads retain file ranges and SHA-256.329- PE export directories and ELF dynamic-symbol exports: `inspect_native_exports`330 with an explicit path; portable, no active target or engine.331- Native executable, library, or analysis database: `open_binary`, then332 use focused analysis tools directly; call `binary_overview` when metadata or333 inventory context is useful and available from the selected provider.334335For an existing IDA MCP configuration, use `open_binary` with the original336input binary and `provider_id: "ida"`; do not pass an `.idb` or `.i64` database.337The legacy attached profile binds the already-open GUI input by SHA-256 and338leaves its database open. The modern headless profile creates and closes an339owned private database without saving. Installation and registration reuse340[mrexodia/ida-pro-mcp](https://github.com/mrexodia/ida-pro-mcp); see the341[IDA provider guide](https://github.com/morluto/rea/blob/main/docs/ida-provider.md).342For migration to the separate native IDA MCP plugin, follow the guide's343[legacy attached migration](https://github.com/morluto/rea/blob/main/docs/ida-provider.md#migrate-a-legacy-attached-registration).344Replace the upstream registration explicitly; modern mrexodia tools are not the345native profile. Native attachment preserves the database but does not provide346direct callers; check session availability and the guide's verification limits.347Proceed directly to `analyze_function`, pseudocode, or function/string searches348after opening; IDA does not supply `binary_overview`. Consult session availability349when composing broader workflows. Modern direct callers and unsupported dossier350facets remain unknown; live IDA results are not replayed from snapshots.351352With `REA_KUNA_COMMAND` configured, `provider_id: "kuna"` answers procedure353lists, lookups, pseudocode, assembly and `analyze_function` from Kuna's cached354whole-program export. Callers/callees use a separate body-free graph shared by355the session; `xrefs` returns exact-address incoming sites and filters forwarding356aliases. These queries and inventory lookups do not trigger a C export. Indirect357targets remain unknown and can make relationship coverage partial. Reference358caches expire on close; a fresh CLI process repeats the native reference walk.359Typed references, CFG, raw-memory tools and annotations remain unsupported. A cold first360answer can come from a single-function run (its limitations say so); assembly361waits for the export. For pseudocode and assembly, `raw_result.source` names the362cached `.c`/`.asm` file and byte span, which you may search directly instead of363calling per function. See the364[Kuna provider guide](https://github.com/morluto/rea/blob/main/docs/kuna-provider.md).365366If the user says only "my app" without a name, path, or target already selected367for this task, ask which app before searching for artifacts. Paths in unrelated368saved reports and nearby test fixtures do not select the user's target. Resolve369an actual human-readable app name to one clear installed artifact when possible;370ask when matches are ambiguous. Never choose an example app on the user's behalf.371372In a target-free session, use `open_binary` to bind any archive/package or373native target whose analysis tool operates on the active target. Do not call an374unadvertised tool; inspect `binary_session` with `{}` and its375`result.tool_availability` for availability reasons and remediation. Expand each376group's `names` into entries, inheriting the inventory-level client requirements377unless the group overrides them. The grouped name union is the complete tool378inventory; use `tools/list` for canonical tool schemas. The default summary keeps379each provider candidate's availability and target-support status, code and380reason; `omitted_fields` lists what it leaves out. Request `{"detail": "complete"}`381only when you need provider diagnostics, candidate capability sets, or tool382surface, effect and annotation flags; in those closed flag vocabularies, listed383flags are true and omitted known flags are false. Provider candidate facts384describe possible providers, while top-level session capabilities describe the385current route and `analysis_provider_binding` names the selected provider. Do386not treat those scopes as interchangeable.387388For a Ghidra startup timeout on a large native target, follow389[deadline recovery](references/native-and-artifacts.md#ghidra-startup-deadline-recovery)390before abandoning deep analysis or repeating the same cold import. The default391330 seconds can be changed for new startup attempts through392`update_analysis_settings` using `ghidra.startup_timeout_ms`. Changing the393server's launch environment instead requires a new REA process.394395## Work summary-first396397Start with the default result and use its inline Evidence and graph context.398For a JavaScript application or ELF layout whose size is unknown or large,399call `analyze_javascript_application` or `inspect_binary_layout` with400`"detail": "summary"`, then inspect the retained `parent_evidence_id` with401`inspect_analysis_view`. Over MCP, `analyze_function` is summary-first without402a flag: its default reply is the summary, and the complete dossier stays403retained under `parent_evidence_id` for facet paging. Pass that ID as a404`retained-evidence` reference to `compare_functions`, or inside405`match_native_functions` `left_observations`/`right_observations` or406`build_call_path.functions`; request `"detail": "complete"` only when the407dossier must travel inline.408Use the same exact-reference form in other advertised logical Evidence inputs,409including optional sources, arrays and nested sources across domains. Each410source can independently be inline or retained; preserve its source identity,411coverage, partial facts and unknowns. A summary or inspection page has its own412Evidence ID: use `normalized_result.parent_evidence_id` when the consumer needs413the complete source. For portable CLI follow-ups, commands advertising414`--evidence-bundle` resolve references from that selected exported bundle.415See [Evidence composition](references/evidence-workflows.md) for scope and416recovery; file selectors are supported only where explicitly advertised.417Page module identities and select the returned `node_id` before requesting an418item; a single file path can represent several graph roles. Do not repeat an419identical analysis or rejected call without a changed input or resolved blocker.420Recheck session state when a lifecycle change makes that status useful.421Make a focused follow-up only when the422returned result leaves a specific question unanswered.423424If MCP reports `resource_constraint` with `details.resource: "transport"`, call425`inspect_analysis_view` with its reported same-session Evidence reference for a426summary, one section/module, or a stable page. Use `trace_application_feature`427once a seed is known, or call `export_evidence_bundle` to write the complete428session to a selected path. The analysis remains complete in the ledger; avoid429repeating it merely to request the same oversized response. Complete CLI JSON430output also streams without a single MCP frame.431432When the retained parent ID is unknown, use `get_evidence_bundle` with433`detail: "summary"` and exact filters for operation, target SHA-256,434analysis-profile digest or canonical procedure address. Select its returned435Evidence ID for the next view instead of requesting the complete bundle.436`retention: "complete-record"` means the whole record is stored; native437value-flow truncation and unknown metadata remain separate. For an exported438portable bundle, use `rea inspect-evidence-bundle` with JSON containing `path`,439`detail: "summary"` and the same `filters`. Reading that file still requires440validating its full contents within the local memory budget.441442A client can also truncate a successful tool result without a REA transport443error. Treat that preview as incomplete; use the retained parent ID for smaller444views or export when the full record is needed. Do not parse the preview as445canonical JSON or repeat the producer. For JavaScript, read the446[module-view and trace recipes](references/javascript-applications.md) before447drilling into a large graph; a broad bidirectional trace can expand unrelated448containment relationships even after summary analysis.449450Every conclusion must distinguish observations, inferences, and unknowns. Cite451Evidence IDs, preserve limitations and incomplete coverage, and never imply452that static analysis observed execution. Runtime requests execute the declared453target and lifecycle; do not broaden the target or action beyond those fields.454455Within the user's requested investigation, call available analysis tools456directly. REA does not require permission grants or per-call approval flags.457The agent client can independently require approval. Follow the declared request458scope and the host's actual access requirements; use the recovery guide for an459observed client-policy rejection.460461## Plan broader investigations462463For requests that span multiple features or subsystems, use a staged workflow:4644651. Turn the request into a checklist of questions and the evidence each answer466 needs. Resolve target identity and constraints from the conversation and467 workspace before asking for information again.4682. Inspect the current REA session, artifact identity, saved analysis database,469 bookmarks, and prior evidence. Reuse matching state; do not open duplicate470 sessions or repeat identical analysis.4713. Start with the smallest useful overview or inventory. Follow each question472 from its entry point through relevant data and state changes to its result.473 Batch related operations around a specific hypothesis, then expand only when474 the returned evidence leaves a concrete gap.4754. Inspect relevant packaged resources and configuration alongside code when476 they affect the question. Use format-aware inventory and parsers; do not477 infer behavior from filenames, strings, or layout alone.4785. Corroborate a conclusion with the evidence type it requires. Use runtime479 observation only when static evidence cannot answer the question and the480 required host runtime and OS access are available. For JavaScript behavior,481 run probes against the actual app through the available browser, Electron,482 or process capture workflow.4836. Decompose work into independent questions. When parallel workers are484 available and the questions do not depend on one another, assign distinct485 scopes, point workers to existing evidence, and ask them to return sources,486 conclusions, and unresolved gaps. Otherwise, work sequentially.4877. Keep a concise finding ledger linking each conclusion to Evidence IDs,488 confidence/evidence type, search boundary, and remaining unknowns. Update489 the shared index or investigation report so later passes can reuse results.490491Before finishing, revisit the original checklist. Mark each question as492answered, partially answered, or unresolved based on its evidence; keep493bounded negative searches bounded, and do not describe a broad investigation494as complete while required questions remain open.495496## Read only the relevant guide497498- Native binaries, managed assemblies, archives, and extraction:499 [references/native-and-artifacts.md](references/native-and-artifacts.md)500- ASARs, extracted JavaScript, feature tracing, and version comparison:501 [references/javascript-applications.md](references/javascript-applications.md)502- Android APK declarations, classes, methods, and static references:503 [references/android-applications.md](references/android-applications.md)504- Native instrumentation, debugger and process capture; browser/Electron505 observation; static/runtime comparison:506 [references/runtime-observation.md](references/runtime-observation.md)507- Evidence paging, comparisons, residual unknowns, and verification:508 [references/evidence-workflows.md](references/evidence-workflows.md)509- Agent environments (AgentEnv bundles) of a web application, recorded from510 a live instance or a HAR:511 [references/environments.md](references/environments.md)512513## Finish the task514515Explain findings in plain language and tie them to returned evidence. When the516user asks to build something, use normal coding tools and separate observed517behavior from design choices. Close an opened native session with518`close_binary` when the investigation is complete.