Skip to content

fix(native): preserve mixed-slice signature observations - #5765

Merged
morluto merged 3 commits into
morluto:mainfrom
jdotc1:fix/5697-mixed-signature-diagnostic
Oct 21, 2026
Merged

morluto merged 3 commits into
morluto:mainfrom
jdotc1:fix/5697-mixed-signature-diagnostic

Conversation

@jdotc1

@jdotc1 jdotc1 commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #5697.

A mixed universal Mach-O can report signing metadata for its default slice while codesign -d -r- exits 1 with an Executable= echo followed by the unsigned-slice diagnostic. The classifier rejected that valid two-line response and discarded the signing observations.

Accept the optional echo only when it exactly matches the bound snapshot or its resolved path. Additional, foreign-path or unrelated nonzero diagnostics remain failures, including per-slice probes. Mixed results explicitly mark partial coverage; default-slice metadata does not establish that every slice is signed. This restores the existing result contract without expanding the slice schema covered by #3583/#4359.

If a later slice probe fails, preserve completed aggregate facts, known unsigned architectures, aggregate-unavailability reasons and all collected command provenance in partialObservation, while retaining the typed failure. One bound inspection owns the capture and limitation ledger, and records facts as each stage completes.

Validation:

  • Final correction on macOS arm64, Node 26.12.0: npm run typecheck and npm run build:cached passed; two ineffective-dynamic-import build warnings.
  • node node_modules/vitest/vitest.mjs run --project boundary tests/boundary/providers/native/nativeInventory.golden.test.ts: 24/24 passed. Includes foreign/extra diagnostics, failed slice probes, and a confirmed unsigned x86_64 slice retained when a later arm64 probe fails. Partial-result assertions cover identifier, entitlements, aggregate limitations and all five command captures.
  • Focused lint exited 0 with complexity/length and existing unused-import warnings; final diff whitespace check passed.
  • Reused initial Node 24.18.0/macOS arm64 receipts: mixed regression failed against the base producer; five real inspect-signature --json cases passed (mixed universal, signed and unsigned thin files, unsigned universal, and signed universal system control). These unchanged CLI cases were not rerun. Synthetic fixtures used normal compiler/linker signing behavior; no signing command or target execution ran.

The original issue baseline is reused. Broader CI/static gates, Intel-host behavior and MCP transport remain untested. The failure-preservation regression uses controlled native-command captures; no fresh real-tool failure was induced.

Author readiness

Human owner: @jdotc1

@jdotc1
jdotc1 marked this pull request as ready for review October 21, 2026 03:48
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review 🔄 Running since 2026-10-21T04:05:36.646843Z 698b7d5 New commits
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@greptile-apps

greptile-apps Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The reviewed changes appear safe to merge.

Summary

Preserves mixed-slice signing facts and limitations when a later architecture probe fails.

  • Mixed Mach-O signature checks keep facts when slice replies are incomplete.

Reviews (3) · Last reviewed commit: "fix(native): accumulate known slice obse..." · Reviewed by Greptile

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f255e2f563

ℹ️ 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".

Comment thread src/native/NativeMacOSProvider.ts Resolved

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: dece36ac77

ℹ️ 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".

Comment thread src/native/NativeMacOSProvider.ts Resolved
@morluto
morluto merged commit 89b1941 into morluto:main Oct 21, 2026
5 of 8 checks passed
@github-actions github-actions Bot mentioned this pull request Oct 21, 2026
3 tasks done
Ambar-13 added a commit to Ambar-13/rea that referenced this pull request Oct 21, 2026
Combine main's partial-observation retention for slice inspection (morluto#5765)
with the per-slice comparison: provenance and limitations accumulate on the
shared observation as slices arrive, a slice query that fails for a reason
other than being unsigned is a failure that keeps the facts collected so
far, and the mixed-state notes are recorded before the slice loop.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
@morluto

morluto commented Oct 25, 2026

Copy link
Copy Markdown
Owner

Welcome to REA, @jdotc1. Thanks for keeping mixed-slice signature facts and command provenance available when a later slice probe fails, with incomplete coverage still made explicit.

@morluto morluto added area: native Native analysis and decompilation, including Ghidra, IDA, and Hopper analysis behavior bug Something isn't working labels Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: native Native analysis and decompilation, including Ghidra, IDA, and Hopper analysis behavior bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] inspect-signature still fails on mixed ad hoc signed universal Mach-O after #701

2 participants