Commit Graph

1334 Commits

Author SHA1 Message Date
morluto cf7477eb46
fix(hopper): wait for late bridges during cleanup (#1866) 2026-10-11 22:50:27 +08:00
Kaoru0822 1f531fc257
fix(managed): decode generic, array, fnptr, and modifier signatures (#1835)
* fix(managed): decode generic, array, fnptr, and modifier signatures

Member signatures using GENERICINST, ARRAY, FNPTR, CMOD_REQD/CMOD_OPT,
or TYPEDBYREF were reported as unsupported, leaving their types unknown
and turning otherwise complete inspections partial. Decode them with an
explicit stack so nested signatures stay recursion-free, keep encoded
TypeDefOrRefOrSpec values, and report malformed shapes as malformed.

Fixes #1832

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(managed): bound array rank before rendering dimensions

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(managed): keep modifier order and reject non-method fnptr headers

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(managed): reject corrupt fnptr flags and misplaced typed references

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(managed): decode signature elements by grammar position

Track whether each element is a field type, return type, parameter,
nested Type, or pointee. VOID is valid only as a return type or
pointee, TYPEDBYREF only as a return type or parameter, and BYREF only
at the top of a return type, parameter, or ref field; other placements
are malformed. Function pointer items are parsed as a return type then
parameters, and generic arguments as Types.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 07:43:48 -07:00
morluto 069308bbe6
fix(hopper): preserve startup failures and recover denied launches
Preserve the primary Hopper startup failure and launcher diagnostics while retaining resources when cleanup cannot be confirmed. Reauthenticate matching external application sessions before document cleanup, keep the Python bridge available for bounded reconnects, and expose the provider-owned Hopper startup deadline.

Real headless Linux Hopper semantic analysis and 65 focused configuration, handshake, cleanup, and bridge tests passed. macOS authorization/crash causes and saved-HOP behavior require their own real-provider verification.

Refs #1808

Co-authored-by: N0zoM1z0 <161784452+N0zoM1z0@users.noreply.github.com>
Co-authored-by: Kaoru0822 <208281322+kaoru0822-kitauji@users.noreply.github.com>
2026-10-11 22:35:01 +08:00
Kaoru0822 ee5275cd9f
fix(artifacts): count a changed partial-inventory root once (#1854)
When partial inventories omitted node details, the root got an unknown
availability row and the differing manifest root digests appended a
second, changed content row, so one logical path was counted as both
changed and unknown. Fold the manifest content change into an existing
unknown or changed root row instead, keeping its dimensions, occurrence
and artifact identities, and citations; contradiction and presence rows
are left as they are.

Fixes #1844

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 22:33:57 +08:00
Ysopwnable 0b4ce83618
fix(windows): retain failed native inspection ownership (#1826) 2026-10-11 21:33:25 +08:00
Ysopwnable 76e4153d34
perf(mcp): reduce Windows startup module resolution (#1814)
perf(mcp): bundle internal modules to reduce Windows startup I/O
2026-10-11 21:01:01 +08:00
morluto 43dafb5abe perf(test): share stdio analysis for comparison fixtures
Produce two comparison scenarios through the existing real MCP session while retaining fresh CLI comparisons, all authored source variants and native execution oracles. Keep the capture-lifetime case as a complete CLI analysis-to-comparison journey.

Validation: 92 tests pass with identical source coverage maps and hit sets across 1,156 files. The covered two-file cohort improved locally from 40.6s to 35.4s including the Git baseline optimization. Typecheck, lint and formatting pass.
2026-10-11 20:51:55 +08:00
morluto ef5f9aa2d7 perf(test): reuse the CI scope Git baseline
Copy a pristine repository into each case-owned workspace instead of repeating init, add, commit and rev-parse for 47 identical baselines. Keep every scenario mutation and real planner invocation, with seed cleanup owned by the file.
2026-10-11 20:51:40 +08:00
morluto f178bf1c00 perf(test): reuse CLI boundary worker module graphs
Share CLI boundary module evaluation in bounded forks while preserving fresh command instances and child processes. Keep module-mocked cleanup tests and source/compiled product catalog verification isolated, and update focused artifact selection.

Flameox full cohort with V8 coverage: 102.8s to 96.6s; 290 passed and two existing skips. Statement, function and branch coverage maps and hit sets match across all 1,153 source files. After syncing main, 75 focused tests, typecheck, lint, docs checks and formatting pass; all 834 test files are discovered exactly once.
2026-10-11 20:29:12 +08:00
BaaRai f2150eb9a7
feat(harmony): project HarmonyOS package inventory evidence (#1447)
* feat(harmony): project HarmonyOS package inventory evidence

First HarmonyOS increment from #1431: HAP, HSP, and App Pack roots are
classified through the hardened ZIP reader and projected into an
execution-free application graph with packaging-model hints, exact
component paths and hashes, App Pack children by path, runtime-family
hints, and path-based N-API bridge hypotheses. HarmonyOS .har stays
unclassified by suffix because .har also names HTTP Archive JSON.

Adds the project_harmony_application_graph tool (CLI and MCP), synthetic
composition coverage, a pinned real-package verify lane, and docs.

* refactor(domain): share application graph projection scaffolding

The HarmonyOS projection mirrors the Android and Apple projections by
design, which pushed jscpd duplication over its 2.5 percent budget.
Extract the identical pieces (inventory input schema, projected
component schema and occurrence flattening, bridge candidate schema
factory, coverage assembly, comparator, canonical digest) into
domain/mobileApplicationGraphProjection.ts and route all three
projections plus the composition fixtures through it. Duplication drops
from 2.52 to 2.49 percent with no behavior change: projection ids,
classifications, and limitations are byte-identical.

* fix(harmony): address review, stable app-pack roots, and rotated fixture

- rebased onto main; the shared projection scaffolding now keeps main's
  nativeRuntimeConvention loop and the harmony runtime families adopt the
  same react-native/flutter/unity path conventions
- the .app App Pack suffix is now a root-input rule only (verified ZIP
  magic in classifyRootFormat and BinaryTargetResolver); nested .app ZIP
  members inside other packages keep the generic zip classification, with
  a regression test, so existing inventories do not change
- the signing limitation now states that an empty signing list does not
  mean unsigned because packaging-tool signatures live in the ZIP signing
  block, and the app-pack root rule is disclosed as suffix-based
- repinned the real-package fixture to the current VHome 2.6.14-beta asset
  after the upstream deleted v5.0.111-beta and replaced the v2.6.14-beta
  asset within hours; the pin records both observed digests

---------

Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-10-11 20:09:21 +08:00
You Wish 0a6b46d5b0
test(ci): stabilize JADX recovery and ignore generated reports (#1668) 2026-10-11 19:56:19 +08:00
Saim Shafique a8a9c4d817
fix(mcp): express inspect_analysis_view selector constraints in the contract schema (#1705)
The item view advertised its four selector alternatives independently of the
selected collection, while collection-specific constraints lived only in a
superRefine that does not survive JSON Schema conversion. Clients validating
against tools/list could not discover that modules accept only path/node_id
and sections/symbols accept only index/name.

Replace the refined object with a discriminated union on collection so the
converted draft-2020-12 schema rejects the same combinations the MCP server
rejects. Runtime selection semantics are unchanged.

Fixes #1695

Co-authored-by: Saim Shafique <sx4imm@gmail.com>
2026-10-11 19:55:16 +08:00
Arthas cdd9fe7167
feat(native): expose typed incoming references at exact addresses (#1715) 2026-10-11 19:52:09 +08:00
Ysopwnable 2e22330037
fix(build): preserve resource controls in strict Turbo tasks (#1809) 2026-10-11 19:50:50 +08:00
Thang Luu ffaf2c12f1
feat(wasm): inspect local artifacts with WABT (#1533)
* feat(wasm): inspect local artifacts with WABT

* fix(wasm): preserve custom names and failed cleanup ownership

---------

Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-10-11 19:49:00 +08:00
Jay-Alexander Elliot e4407dbed5
feat(ghidra): admit bounded PSP ELF through installed Allegrex (#1599)
* feat(ghidra): admit bounded PSP ELF through installed Allegrex

Build on merged generic MIPS without weakening its policy. Bind caller-installed processor files into the analysis profile, check them again before launch, force and verify PSP language selection, retain limitations, and extend the public CLI/MCP verifier with source-owned PSP and target-switching checks. Local actual focused Vitest: 102 passed, one existing permission skip. Hosted static and real-provider results are pending.

* fix(ghidra): validate PSPSDK ABI records in PSP admission

* test(ghidra): bind PSP ABI verification to snapshot profiles

* test(ghidra): declare independent PSP ABI reader contract

* test(ghidra): retain the PSP fixture discriminated type

* test(ghidra): contextually type PSP metadata as the MIPS target variant

* test(ghidra): keep carved firmware checks scoped to generic MIPS fixtures

* style(ghidra): format PSP language-override guard

* style(test): format PSP language override regressions

* fix(ghidra): bound PSP extension enumeration before allocation

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-10-11 19:47:33 +08:00
morluto 0153b4d95b perf(test): batch compatible client profile lifecycles
Keep individual dry-run and scoped doctor checks for all eight profile cases. Share approved setup, idempotency, and uninstall for compatible roots; isolate Devin XDG and default OpenCode environments.

Reduce fresh CLI launches from 41 to 26. A bounded Flameox comparison measured 16.3s before and 12.0s after. All 40 focused client tests, static checks, and test discovery pass.
2026-10-11 19:43:00 +08:00
xeropresence 66c21572de
fix(bun): report the real runtime and enforce worker memory budgets on Windows (#1730)
* fix(bun): report the real runtime and enforce worker memory budgets on Windows

Under Bun, REA recorded Node/V8 identity it did not observe and its JavaScript helper processes ran without a memory bound, because Bun ignores the V8 heap flags REA passes. Source-map trace Evidence claimed runtime node-v8 with Bun's synthetic V8 heap limit (the decoder then rejected that limit, so trace_web_source_location always failed), analysis resource failures reported heap limits Bun does not enforce, the HAR decoder claimed a fixed 192 MiB heap, and doctor reported Bun's Node.js compatibility version as the Node version.

Identify the runtime once from process.versions. Source-map reports record id bun with the Bun and Node.js compatibility versions and a null v8_heap_limit_bytes; the decoder checks the heap budget only for V8 reports and rejects a report from a runtime other than the launching one. The analysis worker reports a null heap limit under Bun, HAR limitations and failures omit heap sizes under Bun, and the doctor node check reports Bun and passes when its Node.js compatibility version is supported.

On Windows under Bun, each helper's owned Job Object now carries a commit limit of its heap budget plus a measured 512 MiB Bun runtime reserve (704 MiB for the codec and HAR decoder, 1536 MiB for the default analyzer). The native addon accepts an optional page-aligned job memory limit on process_spawn, verifies it by readback, associates a private completion port before the child is created, and reports a sticky memoryLimitReached and peak job commit on each poll; inspect reports jobMemoryLimit. A requested limit with an artifact lacking the control refuses the launch, and non-Windows launchers refuse a limit.

Reaching the limit is classified by the job notification rather than Bun's exit status: the analyzer fails the current source with a memory resource failure reporting worker_process_memory_limit_bytes, the codec returns a memory resource failure, and the HAR decoder returns its memory failure with process_memory_limit_bytes. Bun source-map Evidence records process_memory_limit_bytes, verified against the launcher. Node.js launches and outputs are unchanged.

* fix(windows): drain memory notifications after observing exit

---------

Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-10-11 19:20:00 +08:00
xeropresence d412def722
fix(setup): register a stable launcher when run through bunx (#1731)
Setup run through bunx or bun x registered the bin inside bun's temporary
package cache. Detect bun's package-runner launch from npm_command=exec
with a bun user agent and register the pinned bunx launcher, wrapped in
cmd.exe on Windows like the npx launcher. Doctor, update maintenance and
uninstall recognize it as REA-owned, and setup's printed commands name
the runner that launched it.

Read the runner variables case-insensitively on Windows, where the CLI
environment snapshot upper-cases variable names and setup run through
npx also fell back to the cache path.

Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-10-11 19:17:15 +08:00
Ysopwnable 3a17882cc4
fix(javascript): retain unbound CommonJS semantic imports
Collect unbound literal CommonJS dependencies at the semantic module-link owner, retain null binding names and source provenance, and avoid duplicate links for calls already represented by bindings or re-exports. Preserve distinct nested calls, shadowing exclusions, dynamic binding uncertainty, and existing static asset references.

Fixes #1793.
2026-10-11 19:16:32 +08:00
Marnix Pluim 40d9c7b836
test(native): skip the EACCES directory diagnostic as root (#1394)
Root bypasses the mode-0 file permission this test relies on, so
inventory succeeds and the expected EACCES failure never occurs. Match
the root guard used by the other permission-dependent boundary tests.


Claude-Session: https://claude.ai/code/session_01XPY2GmufMNGQKoEgRUx1pd

Co-authored-by: Claude <noreply@anthropic.com>
2026-10-11 19:12:37 +08:00
Jason Cat 951c2aae3b
fix(native): raise default PE resource entry budget to 16384 (#1703)
inspect-pe-resources rejected stock Windows resource images because their
tables exceed the 4096-entry default. Windows 11 25H2 SystemResources
measures imageres.dll.mun at 6476 examined entries, shell32.dll.mun at 5903
and wmploc.DLL.mun at 5440, so the default budget now admits each of them
with headroom while the maximum stays 65536. The independent 8 MiB metadata
budget still bounds allocation, and exceeding any budget still fails without
partial results.

The stable filesystem boundary test now emits a 6476-entry table through a
larger fixture section and asserts that the default budgets report complete
coverage, covering stock-image scale without a real Windows file.
2026-10-11 19:01:33 +08:00
Yann Roberto 3ad5782dfd
fix(javascript): honor package exports before sibling files
Resolve package exports before sibling-file fallback, preserve explicit export blocking, and retain precise CommonJS package self-reference behavior and caller provenance.

Fixes #1761.

Co-authored-by: Yann Roberto <165009858+shoyann@users.noreply.github.com>
2026-10-11 18:57:58 +08:00
morluto 847a1a3f25 test: share native keyed archive integer fixture generation 2026-10-11 18:54:55 +08:00
JingHao-Leon 12c416005f
feat(javascript): recover code-split bundles from multiple inputs (#1686)
* feat(javascript): recover code-split bundles from multiple inputs

recover_javascript_sources accepted a single path, and
validateModuleSet bound every module's provenance to that one snapshot.
A code-split app (runtime + chunks, or an Electron main/preload/renderer
set) had to be recovered one file per call, and modules recovered alone
could not resolve imports across chunks: cross-chunk require(id)
references stayed as numeric ids with property reads.

Add an optional additional_paths input. The listed files are
concatenated, in order after path, into the single engine snapshot, so
one Wakaru run sees every module and cross-chunk imports resolve.
validateModuleSet's single-snapshot binding is unchanged. Module
provenance is attributed back to the input file its first extraction
range starts in, with byte ranges rebased to that file's own offsets;
a module whose ranges cross an input boundary keeps the concatenated
snapshot identity and offsets, recorded as an explicit limitation.
Single-path behavior is byte-for-byte unchanged (one segment,
offset 0).

Fixes #1605

* fix(javascript): preserve source identity in multi-input recovery

---------

Co-authored-by: JingHao-Leon <w15909130000@gmail.com>
Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-10-11 18:39:49 +08:00
Ysopwnable ce845ba428
fix(javascript): preserve and resolve complete source-map URLs (#1788)
Keep line-comment URL declarations intact and percent-decode local URL paths
once, preserving raw Evidence identity and artifact-root confinement.

Fixes #1781. Fixes #1782.

Assisted-by: Suika (gensokyo-skills:suika-scatter-gather-planning)
2026-10-11 18:19:39 +08:00
morluto 044c0a92d5 test: reuse application analysis across comparison directions
Reuse immutable source graphs for both export comparison orientations and obtain rest-argument seeds from the existing public CLI Evidence. Retain all direction-specific assertions while removing nine repeated application analyses.

Validation: 75 focused tests; covered locations and hit status unchanged across all 1137 source files in controlled before/after coverage runs. Comparison file execution fell from 19.2s to 15.3s locally. Static and generated-document checks passed.
2026-10-11 18:15:57 +08:00
morluto e90acaea67 fix(update): resolve Bun global directories before changing cwd 2026-10-11 18:11:52 +08:00
Aravind Rao 262efe6c54
test(native): skip the DMG EACCES diagnostic as root (#1584) 2026-10-11 18:05:24 +08:00
morluto 6bcfeb0e55 test(cli): cache subprocess compilation within each worker 2026-10-11 18:01:32 +08:00
xeropresence e4027e4afc
feat(update): update Bun global installations (#1735)
* feat(update): update Bun global installations

`rea update` only recognized npm global installations and looked up
releases with `npm view`, so a `bun add --global rea-agents` install on a
machine without npm failed with `spawn npm ENOENT`.

Detect the running package inside Bun's global directory
(BUN_INSTALL_GLOBAL_DIR, $BUN_INSTALL/install/global,
$XDG_CACHE_HOME/.bun/install/global, ~/.bun/install/global), resolve the
latest release with `bun info`, install with
`bun add --global --ignore-scripts`, then verify the installed entry point
and plan integration maintenance exactly as for npm.

Bun commands run inside the owning global directory with
BUN_INSTALL_GLOBAL_DIR pinned, so the caller's current project is never
selected. A global directory without package.json is not treated as an
owned installation: Bun then installs into the nearest ancestor project.
npm installations keep their existing commands and messages.

* fix(update): gate Bun self-updates on supported CLI versions

---------

Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-10-11 17:56:05 +08:00
Ysopwnable 817aef4068
fix(apple): validate build-version tool records within cmdsize (#1784) 2026-10-11 17:50:56 +08:00
morluto 85ccef34de test: reuse validators for identical MCP schemas 2026-10-11 17:43:34 +08:00
morluto 42951bbbbe test: reuse identical JavaScript analysis fixtures 2026-10-11 17:43:28 +08:00
Ysopwnable aaeadf2d4c
fix(cli): await browser scenario cleanup on interrupts
Translate browser scenario CLI interrupts into cancellation and await owned provider cleanup. Preserve authenticated observations and cancelled steps with conventional exit codes 130/143.

Refs #1771.
2026-10-11 17:33:57 +08:00
N0zoM1z0 6e38529333 test(docs): type README drift scenarios as fixed pairs 2026-10-11 17:24:46 +08:00
N0zoM1z0 c9136eef71 fix(docs): validate translated README website destinations
Use the website language inventory when comparing README links. Accept the matching localized page while retaining checks for wrong locales, changed destinations, fragments and query parameters.
2026-10-11 17:24:46 +08:00
N0zoM1z0 a2d3338e90 feat(website): add multilingual editions and translation workflow 2026-10-11 17:24:46 +08:00
morluto ff57b75e22 test: bound CLI validation subprocess concurrency
Run the 22 malformed process scenarios in pairs instead of starting 22 compiled CLI runtimes simultaneously. Retain every CLI/MCP error assertion and the no-launch check, and document nested subprocess limits.
2026-10-11 17:23:50 +08:00
morluto a4dd4e8e87 perf(cli): defer command-specific analysis implementations
Load application and Electron workflow implementations only when their commands execute. Keep command schemas and catalog registration eager, and extend the startup import boundary to cover the deferred services.
2026-10-11 17:23:41 +08:00
Immanuel Tikhonov 914ba833de
fix(javascript): report JSON status for imported package manifests
Use the existing JSON-text status checker for explicit package.json imports while retaining separate package-metadata validity. Preserve malformed/unavailable status and partial facts after cancellation.

Co-authored-by: Immanuel Tikhonov <122638311+immanuwell@users.noreply.github.com>
2026-10-11 17:07:57 +08:00
Ysopwnable 4daea941bf
fix(cli): retry retained browser scenario cleanup
Retry retained browser scenario cleanup before the one-shot CLI exits. Preserve primary failures, partial observations and completed Evidence when shutdown fails.

Closes #1771.
2026-10-11 16:51:23 +08:00
morluto 40b37aeee1 ci: balance test shards and reuse package download caches 2026-10-11 16:40:17 +08:00
Kaoru0822 e8528cedcd
fix(hopper): let failed one-shot commands exit while retaining a lease (#1763)
* fix(hopper): let failed one-shot commands exit while retaining a lease

A Hopper target lease retained after unconfirmed cleanup kept its
listening socket referenced, so a one-shot CLI emitted its final
cleanup_incomplete result but never exited, and its live lease rejected
every retry for the same target as already open.

Unreference the lease listener. A live MCP process still holds the
lease for as long as it runs; a completed CLI exits with status 1, and
the stale socket it leaves is recovered by the next acquirer.

Fixes #1751

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(hopper): remove only this test's stale lease sockets

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 01:38:34 -07:00
Kaoru0822 cf692072b5
fix(ida): declare GUI navigation for attached legacy analysis (#1764)
Attached IDA mode always uses the legacy 1.4 producer, whose
disassemble_function jumps to the function and whose decompile_function
opens or reuses a pseudocode view whenever an IDA window is active.
Session discovery still advertised may_show_ui: false for every
operation.

Declare the UI effect for the attached operations that reach those
tools: pseudocode, assembly, raw function instructions and the function
dossier. Headless operations and the other attached operations keep
false. A conformance check now compares each declaration with the
upstream tools the operation actually calls.

Fixes #1712

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 01:36:56 -07:00
Ysopwnable 713db4dc26
fix(process): align capture Evidence provider admission
Use the canonical current and supported legacy process-provider rule for authenticated capture Evidence at both CLI and MCP admission boundaries. Preserve successful Evidence and distinguish provider input errors from digest authentication failures.

Closes #1757.
2026-10-11 16:14:42 +08:00
zayd / cold 58e91e14bd
fix(setup): preserve unrelated Hermes YAML line formatting
Preserve unrelated long YAML scalars when editing an existing Hermes configuration.

Co-authored-by: Zayd <iam@zayd.wtf>
2026-10-11 16:07:44 +08:00
Ysopwnable 857a1b7b04
fix(process): aggregate incomplete trace-spec diagnostics
Summarize incomplete trace-specification pair declarations with exact counts and the first undeclared pair. Preserve complete pair coverage, successful Evidence and independent validation errors; remove temporary pair-scan copies and sorting.

Closes #1753.
2026-10-11 16:04:46 +08:00
Ysopwnable e5699d23b1
fix(mcp): cancel evidence imports before session mutation
Propagate request cancellation through immutable JSON bundle reading and
check it before committing session state. Preserve failed-close ownership.

Fixes #1746

Assisted-by: Suika (gensokyo-skills:suika-scatter-gather-planning)
2026-10-11 15:59:21 +08:00
clyde 062723e44e
fix(browser): retain effective source-map response urls
Preserve source-map response identity and legacy omission, admit identities before body reading, and retain completed results and cleanup causes within the existing output budget. Price fixed envelopes once.

Closes #1729.
Closes #1738.

Co-authored-by: allisaid <curruptdwastaken@gmail.com>
2026-10-11 15:35:43 +08:00