mirror of
https://github.com/morluto/rea.git
synced 2026-10-26 17:35:11 +00:00
* feat(browser): attribute native execution and listener sources Integrate finite native precise-coverage windows and direct DOM listener inspection through shared CLI/MCP workflows, exact session script identities, inline source evidence and owned instrumentation cleanup. Refs #881, #774 Assisted-by: Yukari (gensokyo-skills:yukari-boundary-analysis) Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing) * fix(browser): preserve runtime identity and settle fixture cleanup Retain complete reported initiator objects, reject changing loader availability, propagate the selected operation through main-frame authorization and complete effect/help inventories. Close only the synthetic owned Chrome via its native endpoint, await process-group settlement and preserve primary verification errors during cleanup. Refs #881 Assisted-by: Yukari (gensokyo-skills:yukari-boundary-analysis) Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing) * fix(browser): settle invalid events and preserve document evidence Accept same-document URL changes with proven stable loader identity, retain metadata without inventing ownership, terminate malformed event collection immediately, and sanitize known transport URLs without erasing sourceURL declarations. Assisted-by: Yukari (gensokyo-skills:yukari-boundary-analysis) Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing) * fix(browser): end detached target windows and sanitize coverage identities Reuse the existing flat-session event matcher, retain prearming termination, and apply the source identity policy to coverage URLs. Add real MCP target-close verification and producer regressions for detachment orderings. Assisted-by: Yukari (gensokyo-skills:yukari-boundary-analysis) Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing) * fix(browser): retain final sample metadata and settle fatal protocol failures Keep source inventory open through the resetting sample, propagate fatal wire failures without outstanding commands, and check listener collection failures after final document validation. Assisted-by: Yukari (gensokyo-skills:yukari-boundary-analysis) Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing) * fix(browser): require default execution worlds for website attribution Preserve native context and world metadata without treating same-frame isolated or unknown contexts as website sources. Verify actual Chrome isolated function execution before excluding its coverage, and cover ambiguous world metadata with producer regressions. Assisted-by: Yukari (gensokyo-skills:yukari-boundary-analysis) Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing) * fix(browser): revalidate runtime source joins and selector failures Assisted-by: Yukari (gensokyo-skills:yukari-boundary-analysis) Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing) --------- Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
134 lines
6.1 KiB
Plaintext
134 lines
6.1 KiB
Plaintext
graph TD
|
|
subgraph "Entry Points"
|
|
CLI["src/cli.ts + src/cli/<br/>One-shot CLI adapter<br/>setup, diagnostics, analysis, decompilation"]
|
|
MAIN["src/main.ts + src/main/<br/>MCP stdio server adapter<br/>config, session, process lifetime"]
|
|
DISPATCH["scripts/rea.mjs<br/>Executable dispatcher<br/>routes mcp / one-shot"]
|
|
end
|
|
|
|
subgraph "Adapters"
|
|
SERVER["src/server/<br/>MCP request translation<br/>createServer, tool registration, toolResult"]
|
|
HOPPER_BRIDGE["bridge/hopper_bridge.py<br/>Runs inside Hopper<br/>adapts operations to Hopper Python API"]
|
|
GHIDRA_BRIDGE["bridge/ghidra/ReaGhidraBridge.java<br/>Packaged HeadlessScript<br/>inventory, decompiler, references, CFG"]
|
|
INSTALL["src/cli/ + src/application/Setup*<br/>Host installation adapters<br/>macOS: verified vendor DMG to ~/Applications<br/>Linux: verified vendor package + apt/dnf/pacman"]
|
|
end
|
|
|
|
subgraph "Application Layer"
|
|
APP["src/application/<br/>Shared CLI/MCP workflows<br/>enhanced analysis and investigations"]
|
|
SESSION["SessionProviderRouter + BinarySession<br/>one immutable deep binding per target<br/>disjoint auxiliary routing"]
|
|
REGISTRY["AnalysisProviderRegistry<br/>sorted deep candidates<br/>deterministic selection, no fallback"]
|
|
RECORDS["src/application/investigation/<br/>composed InvestigationRecords + narrow ports<br/>EvidenceLedger and Unknown ownership"]
|
|
SNAPSHOT["BinarySessionRecords + AnalysisSnapshotCache<br/>binary target/profile snapshots<br/>compatibility facade and post-commit notifications"]
|
|
JS_RECON["src/application/ + src/artifacts/<br/>JavaScript artifact reconstruction<br/>directory/ASAR reads<br/>AST-only bundle projection"]
|
|
end
|
|
|
|
subgraph "Provider Layers"
|
|
HOPPER["src/hopper/<br/>Hopper launch & Unix-socket protocol<br/>BridgeLauncher, HopperClient, protocol"]
|
|
GHIDRA["src/ghidra/<br/>Ghidra discovery, profile & function analysis<br/>snapshot, Unix/Windows transport, bounded lifecycle"]
|
|
IDA["src/ida/<br/>Upstream MCP contract adaptation<br/>live GUI binding or owned headless database"]
|
|
IDA_MCP["External ida-pro-mcp<br/>GUI proxy or database supervisor<br/>upstream installation and engine lifecycle"]
|
|
AUX["src/artifacts/ + src/native/<br/>disjoint artifact and native capabilities"]
|
|
BROWSER["src/browser/<br/>CDP / Playwright capture<br/>captured scripts and native module resolution<br/>execution/: coverage, listener and source attribution"]
|
|
JS_CODEC["src/javascript/sourceMaps/<br/>pinned upstream map codec<br/>owned heap-limited Node process, complete point evidence"]
|
|
INSPECTOR["src/inspector/<br/>passive V8 Inspector discovery and capture<br/>script and target locations"]
|
|
DOTNET["src/dotnet/<br/>Managed static metadata provider<br/>PE/CLI metadata inventory, members, IL"]
|
|
FIRMWARE["src/firmware/<br/>Binwalk / Unblob adapters<br/>owned processes, report normalization, private extraction"]
|
|
ANDROID["src/android/<br/>Static APK adapter<br/>owned SDK stdio, pinned headless JADX, normalization"]
|
|
REFERENCE["src/reference/<br/>Filesystem reference-source reader<br/>bounded traversal, validation, errors"]
|
|
end
|
|
|
|
subgraph "Provider Process Foundation"
|
|
PROCESS["src/process/<br/>owned process groups, private roots<br/>deadlines, bounded file reads and diagnostics, cleanup"]
|
|
WINDOWS["src/windows/<br/>Windows host boundary adapters<br/>package loader, opaque handles, owned jobs and private runtimes"]
|
|
WINDOWS_NATIVE["native/windows/src/<br/>Node-API implementation<br/>NTFS admission, protected DACLs and atomic Job Object assignment"]
|
|
end
|
|
|
|
subgraph "Contracts Layer"
|
|
CONTRACTS["src/contracts/<br/>Caller-visible schemas for analysis, managed, browser, Electron, application, and session tools"]
|
|
ERRORS["src/contracts/errorSchemas.ts<br/>Shared analysis error schemas<br/>CLI diagnostics, generated error catalog"]
|
|
end
|
|
|
|
subgraph "Domain Layer"
|
|
DOMAIN["src/domain/<br/>Pure side-effect-free modules<br/>evidence, comparisons, application graphs"]
|
|
end
|
|
|
|
subgraph "Configuration"
|
|
CONFIG["src/config.ts + src/config/<br/>Zod-validated env parsing<br/>provider settings and origins"]
|
|
end
|
|
|
|
subgraph "Tests"
|
|
TESTS["tests/<br/>Vitest suite<br/>fixtures/ holds fake launcher, bridge, and CDP seams"]
|
|
end
|
|
|
|
subgraph "Evaluation"
|
|
EVALUATION["src/evaluation/<br/>Agent release evaluation<br/>session transcript scoring"]
|
|
end
|
|
|
|
DISPATCH --> CLI
|
|
DISPATCH --> MAIN
|
|
MAIN --> CONFIG
|
|
MAIN --> SERVER
|
|
MAIN --> APP
|
|
CLI --> APP
|
|
APP --> FIRMWARE
|
|
FIRMWARE --> PROCESS
|
|
FIRMWARE --> CONTRACTS
|
|
APP --> ANDROID
|
|
ANDROID --> PROCESS
|
|
ANDROID --> CONTRACTS
|
|
ANDROID --> DOMAIN
|
|
CLI --> ERRORS
|
|
APP --> SESSION
|
|
SESSION --> REGISTRY
|
|
SESSION --> SNAPSHOT
|
|
SNAPSHOT --> RECORDS
|
|
APP -->|record callbacks| RECORDS
|
|
SERVER -->|narrow record ports| RECORDS
|
|
RECORDS --> DOMAIN
|
|
REGISTRY --> HOPPER
|
|
REGISTRY --> GHIDRA
|
|
REGISTRY --> IDA
|
|
IDA --> IDA_MCP
|
|
IDA --> CONTRACTS
|
|
IDA --> DOMAIN
|
|
SESSION --> AUX
|
|
APP --> JS_RECON
|
|
APP --> INSTALL
|
|
SERVER --> CONTRACTS
|
|
SERVER --> APP
|
|
APP --> BROWSER
|
|
APP -->|source-map codec port| JS_CODEC
|
|
JS_CODEC --> PROCESS
|
|
JS_CODEC --> DOMAIN
|
|
APP -->|runtime observation port| INSPECTOR
|
|
INSPECTOR -->|shared CDP and file-location helpers| BROWSER
|
|
INSPECTOR --> DOMAIN
|
|
APP --> DOTNET
|
|
DOTNET --> DOMAIN
|
|
HOPPER --> HOPPER_BRIDGE
|
|
GHIDRA --> GHIDRA_BRIDGE
|
|
HOPPER --> PROCESS
|
|
GHIDRA --> PROCESS
|
|
GHIDRA --> WINDOWS
|
|
PROCESS --> WINDOWS
|
|
WINDOWS --> WINDOWS_NATIVE
|
|
APP --> PROCESS
|
|
APP --> DOMAIN
|
|
JS_RECON --> AUX
|
|
JS_RECON --> DOMAIN
|
|
APP --> REFERENCE
|
|
REFERENCE --> DOMAIN
|
|
CONTRACTS --> DOMAIN
|
|
HOPPER --> DOMAIN
|
|
GHIDRA --> DOMAIN
|
|
AUX --> DOMAIN
|
|
BROWSER --> DOMAIN
|
|
PROCESS --> DOMAIN
|
|
TESTS -.-> MAIN
|
|
TESTS -.-> HOPPER
|
|
TESTS -.-> GHIDRA
|
|
TESTS -.-> IDA
|
|
TESTS -.-> PROCESS
|
|
TESTS -.-> BROWSER
|
|
TESTS -.-> EVALUATION
|
|
TESTS -.-> ERRORS
|