Repository navigation
fix(paths): select caller paths through symlinks and .. as the filesystem does - #4067
Conversation
CLI adapters, binary target resolution, the reverse-engineering service and the objdump and Rizin command builders made caller-selected paths absolute with path.resolve, which collapses `link/..` lexically. On POSIX the filesystem follows `link` first, so these commands inspected, hashed or launched a different file and returned internally consistent Evidence for it. absoluteCallerPath now owns that step: on POSIX it prefixes a relative path with the working directory and keeps an absolute path as spelled; on Windows, where `..` resolves lexically, it keeps win32.resolve. Fixes #3864 Fixes #3911 Fixes #3912 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c92a375dc5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| path: absoluteCallerPath(args.path), | ||
| glue_paths: options.glue_paths?.map((path) => resolve(path)), | ||
| candidate_paths: options.candidate_paths?.map((path) => | ||
| resolve(path), |
There was a problem hiding this comment.
Preserve all caller-selected WASM paths
When --glue-paths or --candidate-paths contains a POSIX path such as link/../asset, only the primary module path avoids lexical normalization; these two mappings still use resolve, so WABT can read the lexical sibling and emit its digest and evidence as a caller-selected glue module or candidate. Apply absoluteCallerPath to both lists as well.
AGENTS.md reference: AGENTS.md:L13-L13
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Valid, fixed in a384b89. Root cause: this PR converted only the primary module path, but --glue_paths and --candidate_paths are caller-selected paths with the same producer. Both lists now go through absoluteCallerPath, and wasmCommands no longer imports resolve. Validated with the affected suites below. WABT is not installed on this host, so there was no real WABT run.
[Medium impact] The PR appears safe to merge, with a non-blocking regression in WASM glue links for ordinary parent references. Findings
Fix with agent prompt### Issue 1
src/wasm/WasmGlueAdapter.ts:47-55
With glue at `/app/sub/glue.js` containing `fetch("../module.wasm")`, this comparison builds `/app/sub/../module.wasm`. That cannot equal the selected candidate `/app/module.wasm`, even when `sub` is an ordinary directory. If `/other/module.wasm` is also selected, both files now appear as `basename-candidates`; previously only `/app/module.wasm` matched.
Compare filesystem-resolved file identities without collapsing symlink parents, while keeping the caller’s spelling in the output. Add this ordinary parent-reference case alongside the symlink test.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.SummaryThe PR moves caller-selected paths through
Diagram%%{init: {'theme': 'neutral'}}%%
flowchart LR
A[Caller-selected path] --> B[absoluteCallerPath]
B --> C[Keep POSIX parent components]
B --> D[Keep trailing directory requirement]
C --> E[Filesystem selects file]
D --> E
B --> F[WASM path-string comparison]
F --> G[Different spellings fall back to filenames]
Reviews (3) · Last reviewed commit: "fix: keep directory requirements and rel..." · Reviewed by Greptile |
Review follow-up. The CLI already passed firmware and WASM paths through absoluteCallerPath, but snapshotFirmware and SafeOutputTree.create re-resolved them lexically, and the WASM glue and candidate lists still used resolve, so those inputs could still select a sibling file or create output beside the intended directory. absoluteCallerPath now also drops `.` segments and repeated or trailing separators on POSIX, which never change the named file, so selected paths such as `./module.wasm` keep matching their glue references exactly. Every `..` is still left for the filesystem. SafeOutputTree keeps host path syntax; its platform argument selects only the Windows name policy. Co-Authored-By: Claude Opus 5.5 <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a384b892b0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| }: { readonly cwd?: string; readonly platform?: NodeJS.Platform } = {}, | ||
| ): string => { | ||
| if (platform === "win32") return win32.resolve(cwd, path); | ||
| const absolute = posix.isAbsolute(path) ? path : `${cwd}/${path}`; |
There was a problem hiding this comment.
Resolve relative caller cwd before preserving path
On POSIX, parseBinaryTarget("sample", { cwd: "fixtures" }) now passes /fixtures/sample to the filesystem, whereas the prior resolve(cwd, input) correctly selected <process.cwd()>/fixtures/sample. cwd is an unconstrained string in BinaryTargetResolverOptions, so callers that use a relative working directory receive an unrelated root path or ENOENT; make the supplied cwd absolute (without normalizing its .. components) before appending a relative input.
AGENTS.md reference: AGENTS.md:L13-L13
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Valid, fixed in 1653bb5. Root cause: the helper used a non-absolute cwd as if it were absolute. A relative cwd is now made absolute first, through the same owner and without collapsing .., before the path is appended. The helper test covers cwd: "fixtures/../x".
| absoluteCallerPath(path), | ||
| ), | ||
| candidate_paths: options.candidate_paths?.map((path) => | ||
| resolve(path), | ||
| absoluteCallerPath(path), | ||
| ), |
There was a problem hiding this comment.
Preserve symlink semantics in WASM glue matching
When the CLI receives a glue path and WASM path such as link/../glue.js and link/../module.wasm, these mappings retain their symlink-sensitive spellings, but associateWasmGlue still computes a local literal with resolve(dirname(path), value) (src/wasm/WasmGlueAdapter.ts:44-47). That lexical resolve turns the reference into the sibling path, so fetch("./module.wasm") is only recorded as a basename match instead of local-path-candidate for the selected file; use the caller-path owner for that comparison too.
AGENTS.md reference: AGENTS.md:L13-L13
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Valid, fixed in 1653bb5. Root cause: associateWasmGlue was a second, lexical interpreter of the same caller-selected paths. It now compares absoluteCallerPath(value, { cwd: dirname(glue) }) with absoluteCallerPath(candidate) and still reports each candidate exactly as given. So ./ spellings and MCP-supplied absolute paths compare consistently, and link/../ is never collapsed onto a sibling. The new case selects link/../module.wasm and link/../glue.js with a competing /app/module.wasm, and asserts an exact local-path-candidate for the selected file only. It fails on the previous commit. Validation for this round: npx vitest run tests/boundary/cli tests/boundary/providers tests/boundary/filesystem tests/boundary/native tests/boundary/mcp tests/boundary/firmware src/application src/wasm tests/acceptance passed 700 files (6,565 tests passed, 93 skipped), plus npm run check:fast.
Review follow-up. absoluteCallerPath stripped a trailing `/` or `/.`, so `file/` selected the regular file instead of failing with ENOTDIR; it now keeps one trailing separator. A relative cwd option was appended to the root; it is now made absolute without collapsing `..`. WASM glue matching resolved local literals lexically, so a module selected through `link/..` matched only by basename; the adapter now compares both sides through absoluteCallerPath and still reports each candidate as given. Co-Authored-By: Claude Opus 5.5 <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1653bb58f3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const segments = path | ||
| .split("/") | ||
| .filter((segment) => segment !== "" && segment !== "."); | ||
| const directory = /\/\.?$/u.test(path) && segments.length > 0; | ||
| return `/${segments.join("/")}${directory ? "/" : ""}`; |
There was a problem hiding this comment.
Preserve leading double slashes in POSIX caller paths
On POSIX implementations that assign special semantics to a // root, this filter changes a caller-selected path such as //namespace/target into /namespace/target. Since this helper now feeds CLI inputs, provider command arguments, hashing, and output roots, those callers can again inspect or create resources in a different namespace; retain the leading double slash rather than treating it as a repeated interior separator.
AGENTS.md reference: AGENTS.md:L13-L13
Useful? React with 👍 / 👎.
| const target = local | ||
| ? absoluteCallerPath(value, { cwd: dirname(path) }) | ||
| : undefined; | ||
| const exact = | ||
| target === undefined | ||
| ? [] | ||
| : candidates.filter( | ||
| (candidate) => absoluteCallerPath(candidate) === target, | ||
| ); |
There was a problem hiding this comment.
With glue at /app/sub/glue.js containing fetch("../module.wasm"), this comparison builds /app/sub/../module.wasm. That cannot equal the selected candidate /app/module.wasm, even when sub is an ordinary directory. If /other/module.wasm is also selected, both files now appear as basename-candidates; previously only /app/module.wasm matched.
Compare filesystem-resolved file identities without collapsing symlink parents, while keeping the caller’s spelling in the output. Add this ordinary parent-reference case alongside the symlink test.
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/wasm/WasmGlueAdapter.ts
Line: 47-55
Comment:
**WASM links become ambiguous**
With glue at `/app/sub/glue.js` containing `fetch("../module.wasm")`, this comparison builds `/app/sub/../module.wasm`. That cannot equal the selected candidate `/app/module.wasm`, even when `sub` is an ordinary directory. If `/other/module.wasm` is also selected, both files now appear as `basename-candidates`; previously only `/app/module.wasm` matched.
Compare filesystem-resolved file identities without collapsing symlink parents, while keeping the caller’s spelling in the output. Add this ordinary parent-reference case alongside the symlink test.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.Resolve the conflicts with main at 32f0e51. No rebase or force-push. - src/cli/wasmCommands.ts: keep the component command and take main's absoluteCallerPath (morluto#4067). The component path now uses it too, instead of path.resolve, so `link/../file` selects the file the filesystem names. Pass the command signal to finishAnalysisCommand, which main now requires (279c590). - src/server/createServer.ts: keep main's rustBinary service and this PR's wasmComponent service in construction, shutdown and the tool context. - tests/boundary/mcp/serverLifecycleMcp.test.ts: keep main's scenario capture service and this PR's component service in the shutdown test. - src/wasm/WabtComponentRouting.ts: the component probe reads its header through main's withArtifactFileHandle, so a failed close is retained as a lease and its error resolves on retry, as main's WABT descriptor-retry test requires. - tests/boundary/cli/callerPathSymlinkParentCli.test.ts: cover inspect-wasm-component through a symlink and `..`; it fails with path.resolve.
…r tools Follow main's absoluteCallerPath (morluto#4067) and pass the command signal to finishAnalysisCommand.
…r tools Follow main's absoluteCallerPath (morluto#4067) and pass the command signal to finishAnalysisCommand.
Use absoluteCallerPath (morluto#4067) so a path with a symlink followed by .. names the same file the CLI and MCP inspect.
Use absoluteCallerPath (morluto#4067) so a path with a symlink followed by .. names the same file the CLI and MCP inspect.
main replaced the node:path resolve import in binaryDiagnosticsCommands.ts with absoluteCallerPath (morluto#4067), so the byte-entropy command's resolve(args.path) no longer type-checks once the PR is merged with main. Use absoluteCallerPath like the other commands, and add src/filesystem/callerPath.ts matching main so the branch builds on its own.
…d methods (#3807) * feat(il2cpp): inventory IL2CPP global-metadata images, types and methods Add inspect_il2cpp_metadata (CLI inspect-il2cpp-metadata), a read-only in-process decoder for unencrypted Unity global-metadata.dat version 39. It reports header sections, serialized index widths, images, type definitions (nesting from the nestedTypes section) and method names. Unrecognized magic and other versions are unsupported; damaged headers, overlapping sections, inconsistent record sizes, out-of-range indices and invalid strings fail with a reason code and no partial success. MCP detail summary retains the complete Evidence and pages rows through inspect_analysis_view kind il2cpp-metadata. Adds an opt-in verify:il2cpp:metadata -- --metadata PATH check. * feat(il2cpp): deliver metadata summaries by default over MCP A 112,232-method file produced a 10.5 MB complete response, above the 10 MiB stdio budget. Default MCP delivery is now the retained summary; detail complete stays available, and the one-shot CLI requests it. * fix(il2cpp): reject shifted strings, nesting cycles and method owner drift Review fuzzing showed that moving the strings section offset by one byte silently renamed every image, type and method. Name indices must now start a string, which also bounds total decoding by the section size. Nesting cycles and methods whose declaring type disagrees with the owning type range are rejected instead of returned. Adds service, shutdown and index-width coverage, and moves environment-specific measurements out of the public guide and tool description. * feat(il2cpp): decode global-metadata versions 29 and 31 Unity 2022.3 writes version 29 or 31 metadata: a 256-byte header of (offset, size) pairs, fixed 4-byte indices, type records with elementTypeIndex, and method records that gained returnParameterToken in version 31. Record counts come from section sizes and must be whole. Sections report a null count for these versions and index widths report fixed-width-version. Image, type and method rows keep the same shape, and the string, nesting and method-ownership checks apply to every version. * fix(il2cpp): bound report size before serializing and tighten coverage Rows share decoded names, so a 130 KB file could expand into gigabytes of JSON before the 64 MiB budget check, ending in an internal RangeError. The provider now refuses from a lower bound on the serialized rows first. The decoder also rejects non-empty sections inside the header, methods outside their declaring type's range and overlapping image type ranges, and keeps a leading byte order mark in names. Layouts now carry one indexing mode instead of two coupled flags, and the tool description explains nested_type_start. * fix(il2cpp): refuse oversized metadata before decoding rows Address review findings on the IL2CPP metadata inventory: - check a lower bound from header row counts before any row object is allocated, so a large rejected file no longer builds every row first; - validate sealed parent Evidence and count its rows once per report instead of on every inspect_analysis_view page; - decode version 39 fixtures with 2- and 4-byte type-definition, generic-container and parameter indices. * docs(il2cpp): attach the decoder comment to readIl2cppMetadata * fix(il2cpp): deliver complete rows by default like the other inspection tools inspect_il2cpp_metadata defaulted to detail summary, the only inspection tool to do so. Omitted detail now returns every row inline, as inspect_artifact, decode_interface_builder and the capture tools do; summary stays one argument away and the guide, CLI reference and skill reference say to select it first for large games, whose complete MCP delivery is refused at the stdio budget with retained Evidence. * test(il2cpp): cover narrow-width -1 sentinels and fix the skill's default An empty image stores its type start as the all-ones value of a one- or two-byte index; the decoder reads it as -1, but no fixture exercised it, so removing either conversion passed the suite. The fixture can now append an empty image, and both widths decode it. The skill still described a summary default; it now says to select summary first, as the guide does. * docs(il2cpp): request summary explicitly in the summary example * chore(il2cpp): hash the verifier metadata through owned file resources * fix(il2cpp): count escaped name length without building the escaped string * fix(il2cpp): keep the verifier's check failure and small-table last page * feat(domain): count JSON string length without building the escaped string * fix(il2cpp): keep descriptor cleanup owners and share the JSON length count * test(domain): give the backslash case real backslashes * fix(il2cpp): select the CLI path and finish the command like the other tools Follow main's absoluteCallerPath (#4067) and pass the command signal to finishAnalysisCommand. * fix(il2cpp): select the verifier input path like the CLI Use absoluteCallerPath (#4067) so a path with a symlink followed by .. names the same file the CLI and MCP inspect. * feat(il2cpp): add compact composable metadata queries Retain source-indexed Evidence for filtered batch and field queries. Bound representation growth before serialization, yield decoding for cancellation, and share CLI Evidence publication with desktop inspection. Verify public Unity metadata against independent byte and managed-DLL oracles and exercise actual stdio SDK workflows. * fix(il2cpp): retain the validated metadata header magic * test(il2cpp): remove obsolete execution wording exception * fix(artifacts): preserve export selection and completed source facts --------- Co-authored-by: gensokyo-dev <[email protected]>
…r tools Follow main's absoluteCallerPath (morluto#4067) and pass the command signal to finishAnalysisCommand.
Use absoluteCallerPath (morluto#4067) so a path with a symlink followed by .. names the same file the CLI and MCP inspect.
…r tools Follow main's absoluteCallerPath (morluto#4067) and pass the command signal to finishAnalysisCommand.
Use absoluteCallerPath (morluto#4067) so a path with a symlink followed by .. names the same file the CLI and MCP inspect.
…2331) * feat(diagnostics): report a byte entropy profile for one local file The diff adds the MCP tool inspect_byte_entropy and the CLI command inspect-byte-entropy, both implemented by ByteEntropyService. One absolute regular file is read offline into observed Evidence: file-wide SHA-256 and Shannon entropy, then fixed blocks and adjacent runs for an optional window, using a power-of-two block size from 256 to 65536 (default 4096), with high at 7.2 or above and low at 1.0 or below. A window past EOF, a missing path, or a non-file is an input error; a size or identity change during the read is an artifact-changed error; empty input reports entropy 0; cancellation is honored before and during the read. Summary detail retains the complete series and returns file entropy, counts, and the ten longest runs for inspect_analysis_view, while the registered effect remains read-only Evidence and the diagnostics docs record the operation and its errors. * fix(diagnostics): flag zero-size files as not shown empty Generated files such as Linux /proc entries report size 0 while holding content, so inspect_byte_entropy read nothing and returned an empty-looking report. A file that reports size 0 now carries a limitation that the result does not show the file is empty. The result stays a success because the tool reads the declared size, which the file-stability checks depend on. * fix(mcp): reject unsupported diagnostic summaries before inspection * fix(ci): repair integrated checks and Hopper test baseline * test(entropy): use shared MCP schema verification after merge * fix(catalog): list inspect_byte_entropy under its own provider Adding inspect_byte_entropy to BINARY_DIAGNOSTICS_TOOL_CONTRACTS put it under pwntools-elf in the generated product catalog, because the pwntools group took every binary diagnostics tool except inspect_pe_resources. The service reports provider byte-entropy. Add a BYTE_ENTROPY_PROVIDER identity beside PE_RESOURCES_PROVIDER, use it in ByteEntropyService, give it its own catalog group, and name the pwntools tools (inspect_binary_layout, inspect_recorded_crash) explicitly so a new diagnostics tool is not attributed to pwntools by default. The catalog test pins both groups. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01KFTE4BHbGYzgf8Uhzcppdh * fix(cli): resolve the byte-entropy path with absoluteCallerPath main replaced the node:path resolve import in binaryDiagnosticsCommands.ts with absoluteCallerPath (#4067), so the byte-entropy command's resolve(args.path) no longer type-checks once the PR is merged with main. Use absoluteCallerPath like the other commands, and add src/filesystem/callerPath.ts matching main so the branch builds on its own. * fix(diagnostics): retain entropy read cleanup ownership * docs(diagnostics): explain entropy output capacity * fix(diagnostics): preserve entropy cancellation outcomes * fix(diagnostics): close the entropy input and warn on large reports Public inspect_byte_entropy input now uses publicInputStrictObject before detail is added, so unknown keys stay rejected on the advertised schema. The tool description warns that complete output can become very large and points callers to a shorter length or a larger block_size. Co-authored-by: morluto <[email protected]> * fix(diagnostics): keep byte-entropy registration mergeable with main Register inspect_byte_entropy beside layout inspection and reject unretained summaries before the file read, without editing workflows. Co-authored-by: morluto <[email protected]> * fix(diagnostics): register byte entropy with the shared tool options Use toolRegistrationOptions so the handler typechecks on this branch and on main, and still refuse unretained summaries before the file read. Co-authored-by: morluto <[email protected]> --------- Co-authored-by: Matt Van Horn <[email protected]> Co-authored-by: morluto <[email protected]> Co-authored-by: Claude Opus 5.5 <[email protected]> Co-authored-by: Kaoru0822 <[email protected]> Co-authored-by: Cursor Agent <[email protected]> Co-authored-by: morluto <[email protected]>
Summary
Fixes #3864, fixes #3911, fixes #3912. On POSIX, a caller path such as
link/../sample, wherelinkis a directory symlink, makes the filesystem followlinkfirst and then apply... REA made caller paths absolute withpath.resolve, which collapseslink/..lexically. As a result, several commands inspected, hashed or launched a sibling file and returned internally consistent, successful Evidence about the wrong artifact. This PR moves that step into one owner that never changes which file a path names.Problem and expected behavior
I reproduced this on main with the built CLI and a real Mach-O (
gh):target/sampleis a copy ofgh../sampleis the same copy with one byte appended.link -> target/child.link/../sample(relative)$PWD/link/../sample(absolute)inspect-go-binary2ba6b7…✗inspect-rust-binaryinspect-with-objdump … file_headersinspect-macho,list-architectures,inspect-signatureThe intended file is
db2578…. Every command exited 0 in every case.There are two lexical producers:
resolve(args.path)) andparseBinaryTarget(resolve(cwd, input)) build the absolute path lexically.RizinDebugSessionManagerlaunch, andReverseEngineeringService, which hashes objdump and Rizin inputs. Because of the builders and the service, the objdump and Rizin bug also reaches MCP callers.Change and scope
src/filesystem/callerPath.tsexportsabsoluteCallerPath(path, { cwd?, platform? }):cwdis made absolute the same way). Only interior.segments and repeated separators are removed, which never change the named file. A trailing/or/.keeps its directory requirement as one trailing/. Every..is kept, so the filesystem resolves symlinks and..in order../module.wasmfrom/appis/app/module.wasm;link/../xstays/app/link/../x.win32.resolve, because Windows resolves..lexically, so that normalization is exact there.resolve/isAbsoluteimports are removed:binaryDiagnostics,capture,coreBinary,evm,firmware(input and output directory),go,rust,signal,sqliteandwasmcommand modules;parseBinaryTarget,ReverseEngineeringService,objdumpCommand,rizinCommandand the Rizin debug launch;--glue_paths/--candidate_pathslists,snapshotFirmware(firmware input) andSafeOutputTree.create(extraction output root). These were review follow-ups: the CLI conversion alone did not reach these owners.SafeOutputTreeuses host path syntax; itsplatformargument selects only the name policy.local_pathnow keeps the caller's spelling (for example…/link/../sample) when the provider reports it. It no longer reports a different file's path.JsonFiles,EvidenceBundleFilesandJavaScriptRecoveryServicestill callresolve(path)on caller-selected JSON, bundle and source paths.Contract and boundary impact
Semantic owner and earliest changed stage:
absoluteCallerPathowns conversion of a caller-selected local path to an absolute path. The CLI adapters, target resolution, provider command builders and the hashing service consume it.Contribution scope fit and linked maintainer decision: a bug fix within the existing boundaries; not applicable.
CLI and MCP/tool-catalog contract: schemas unchanged. The same request now selects the file the filesystem names.
Provider, bridge, target-format, or platform compatibility:
..) after a symlink, or with./duplicate separators, which are now passed through unnormalized.Evidence, artifact, provenance, or reconstruction contract:
local_pathnow describe the selected file.launch_provenance.resolved_pathnow records the absolute path actually launched, which names the same file ascaller_selected_path.Target selection, authority, upstream behavior, and cleanup details: the Rizin debug launch no longer starts a sibling program for such a path. There is no other change to execution authority.
Generated metadata, package, or installation impact: none.
Read existing files or captured data.
Launch or attach to a process. (Only the existing Rizin debug launch path; this PR changes which path it receives.)
Evidence and regression coverage
tests/boundary/cli/callerPathSymlinkParentCli.test.ts(POSIX): public CLI runs ofinspect-go-binary,inspect-rust-binaryandinspect-pe-resourceswith relative and absolutelink/../…spellings, asserting the selected file's SHA-256. It uses the repository's Go and PE resource fixture writers.tests/boundary/filesystem/callerPath.test.ts: POSIX and win32 helper semantics, including which spellings are normalized.tests/boundary/filesystem/symlinkParentOwners.test.ts(POSIX):snapshotFirmwaredigeststarget/image.binforlink/../image.bin, andSafeOutputTree.create("…/link/../out")createstarget/outand not./out. Both fail on the previous commit.src/wasm/WabtOutput.test.ts: a CLI-selected./module.wasmkeeps an exactlocal-path-candidateglue match against a competing/other/module.wasm. This fails with the first version of the helper.RizinDebugSessionReviewRegressions.test.ts(3 cases) andrizinDebuggerCancellationMcp.test.tsderived their expectedresolved_pathwith lexicalresolve. They now derive it from the owner.srcrestored, the new CLI test fails in both cases. Go selects the sibling, and PE resources selects exactly the sibling digest predicted in [Bug] PE resource inspection changes the selected file after a symlink parent component #3911 (9a251f9f…). With the fix, both pass.ghcopy: every command in the table above selectsdb2578…for both spellings.execute-rizin-commandis unavailable on this host (no Rizin), andghis not a PE file.inspect-go-binary link/../sampleinspect-go-binary target/sampleinspect-macho link/../sampleinspect-macho target/sampleThe helper does a string check and a concatenation. The spread between the two fixed runs (385–496 ms) is host noise; this is not a performance change. Output for the
link/../spelling grows by 4 bytes, becauselocal_pathkeeps the caller's spelling instead of the collapsed sibling path.Validation performed
npm run test:focused -- tests/boundary/filesystem/callerPath.test.ts tests/boundary/cli/callerPathSymlinkParentCli.test.ts— 4 passed. The CLI test against main'ssrc: 2 failed, as expected.npx vitest run tests/boundary/cli tests/boundary/providers tests/boundary/filesystem tests/boundary/native src/application tests/acceptance/goBinaryCli.test.ts tests/acceptance/rustBinaryCli.test.ts tests/acceptance/applications/peResources.test.ts— 465 files: 5,294 passed, 3 failed. All three were the Rizin expectations described above; after updating them the file passes (15 passed).npx vitest run tests/boundary/mcp tests/acceptance— 231 files: 1,249 passed, 1 failed. It was the Rizin MCP expectation described above; after updating it the file passes (3 passed).npx vitest run tests/boundary/cli tests/boundary/providers tests/boundary/filesystem tests/boundary/native tests/boundary/mcp tests/boundary/firmware src/application src/wasm tests/acceptance— 700 files, 6,562 passed, 93 skipped, 0 failed. Linux-only firmware integration cases were skipped on this host.npm run check:fast— passed.npm run knip— clean.Compatibility, safety, and release
otool,lipo,codesign, objdump). No Linux or Windows host runs.Author readiness
Human owner:
Before merge
type(scope): outcome.🤖 Generated with Claude Code