Repository navigation
fix(elf): reject unmatched NT_FILE pathnames - #10138
Merged
morluto merged 5 commits intoNov 11, 2026
Merged
Conversation
Codex Review Summary: ✅ CompletedThis 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. |
This was referenced Nov 11, 2026
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Leave
NT_FILEmappings unknown when the descriptor contains unmatched pathname bytes. Retain the raw note identity, location, and hash.Problem and expected behavior
A synthetic ELF core note declares one mapping but appends a second pathname after the one it names. Both
inspect-elf-notesandinspect_elf_notesreported the first row as decoded and ignored the unmatched bytes. The Linux writer emits one filename per mapping and sizes the descriptor to those filenames. This case came from direct inspection of the passive decoder. Linux NT_FILE producerChange and scope
Check the suffix after the declared filenames during the existing descriptor scan. Nonzero bytes leave
corenull. The scan result is reused when program and section tables reference the same descriptor. A zero-filled suffix remains accepted for compatibility, consistent with the existing core mapping authority check.Follow the contribution scope.
Unresolved scope, authority, side effects, or required verification block
integration. Link the required maintainer scope decision for new providers or
capabilities involving target execution, injection, mutation, or protection
recovery; ordinary fixes within existing boundaries may state "not applicable".
Draft PRs may leave the scope decision pending and the readiness and merge checklists
unchecked. Maintainers can help resolve open questions.
Contract and boundary impact
core.file.inspect-elf-notesandinspect_elf_notesuse the existing nullablecorefield.corenull.docs/public/product-catalog.json), package, or installation impact (CI generates and validates ignored catalogs andskills/; edit authored instructions in.agents/skills/reverse-engineer-anything/and never commit build outputs): the decoder uses the existing schema and metadata.Expected effects (check known effects; use documentation-only on its own).
Unchecked items do not establish absence; leave uncertainties visible.
Evidence and regression coverage
PT_NOTEandSHT_NOTEretains both entries with the same hash and coverage.0909d89c, both new parser cases failed because the surplus pathname produced a decoded mapping. The same 208-byte synthetic file through the compiled CLI and MCP returned one row. With the fix, both returncore: nullfor that file and retain its descriptor. The exact, zero-suffix, and unterminated controls produced equal normalized reports across revisions.type_name: "core_file",core: nulland a 68-byte descriptor whose SHA-256 isf89ae466300c0f8f3c2f0d4e361538e90c24b2c56dcc7aeef0a01ef05f0f1a2d.EPERMbefore the test called REA. Live Linux core and debugger validation remain separate.For boundary fixes, identify the applicable boundary regressions
and lifecycle regressions
covered by the evidence above, and explain relevant gaps.
For evidence-bearing changes:
Validation performed
Current head
8bc15fe4d237bc5e113d5a51c957d1797b61ab52merges accepted main with a normal merge commit. The diff against that base retains this PR's 3-file patch.Previous revision and validation evidence
npm run check:ci:fast:tasks, architecture guards,npm run docs:check, andgit diff --checkpassed.Compatibility, safety, and release
coreon undecoded notes.Author readiness
Human owner: @wunianze666-netizen
Before merge
type(scope): outcome.Maintainer integration validation
Integrated main
6b2f9918088c02ea00efc417051362f260d1cee2, including the CI lifecycle repair. Feature diff unchanged; current heade54b65f3a646f46e69e95f98b1f2b653a0950722. Combined validation of #10138, #10085 and #10044 on this main: 222 passed, 1 host-ELF skip across 15 parser/service/filesystem/CLI/MCP suites; typecheck and lint passed. The CI repair separately passed 373 tests with 3 host-specific skips. Local macOS Node 24.22.1; fresh hosted CI pending. No Windows loader verification is claimed.