Skip to content

fix(native): inspect the selected universal Mach-O architecture - #601

Merged
morluto merged 2 commits into
morluto:mainfrom
rudycelekli:campaign/rea-selected-native-slice-20261005
Oct 5, 2026
Merged

morluto merged 2 commits into
morluto:mainfrom
rudycelekli:campaign/rea-selected-native-slice-20261005

Conversation

@rudycelekli

@rudycelekli rudycelekli commented Oct 5, 2026 •

Copy link
Copy Markdown

Summary

Keep universal Mach-O observations associated with the selected architecture.

No issue is linked: this is a newly reproduced correctness defect found while reviewing current upstream; the regression and affected production seam are included for review.

Problem and expected behavior

A selected arm64 target can receive the first x86_64 UUID and duplicated load commands from unsliced tool output. Slice-specific observations must belong to the selected target while architecture inventory retains both slices.

Change and scope

Pass the selected architecture to native slice-aware captures using each tool’s supported flag spelling.

Contract and boundary impact

  • Semantic owner and earliest changed stage: NativeMachoInspection native command capture arguments.
  • CLI and MCP/tool-catalog contract: existing operations and schemas remain compatible; UUID and segments describe arm64; architectures lists x86_64 and arm64.
  • Provider, bridge, target-format, or platform compatibility: Universal Mach-O inspection through the macOS native provider.
  • Evidence, artifact, provenance, or reconstruction contract: existing source identity and explicit incomplete/unsupported evidence remain preserved.
  • Process execution, authorization, cleanup, or containment impact: Uses existing allowlisted Xcode tools with explicit architecture arguments.
  • Generated metadata (docs/product-catalog.json), package, or installation impact: no metadata or dependency changes required.

Evidence and regression coverage

  • Tests added or updated: tests/boundary/providers/native/nativeSelectedArchitecture.test.ts.
  • Base reproduction or other evidence: Executed fixture regression for wrong UUID and duplicated __TEXT. Actual production NativeMacOSProvider inspected source-built clang/lipo arm64+x86_64 bytes: SHA-256 410dc4074d99b0ec9be0f97010325b5e2a2780c1c620cd5558acce298b1321e3, selected arm64 UUID F92D4775-9AF2-3497-8066-0ACC20F50B0F, one __TEXT and two inventory architectures. Tool identity/provenance and existing symbol/toolchain limitations are retained. Affected base is ebb4c45.
  • User-visible CLI/MCP output: UUID and segments describe arm64; architectures lists x86_64 and arm64.
  • Remaining proof gaps: Actual native verification ran on macOS arm64. Hopper/Ghidra and other macOS toolchain versions were not run.

For evidence-bearing changes:

  • Observed, derived, and inferred claims remain distinguishable.
  • Artifact identity, source provenance, and failed attempts remain preserved.
  • Unsupported, incomplete, unavailable, or uncertain outcomes remain visible.

Validation performed

Latest upstream sync: 07e0764c0f721cb095edb29f9f66b0b18304a5d1 incorporates current owner main, including the source-map fixture correction from #609. At this head, the original regression plus webSourceMapFetcher.test.ts, npm run check, and npm run check:fast pass. The full local suite was not repeated for this routine sync under the current contribution policy. The implementation checks below were performed before this upstream sync and do not imply a full-suite result for the new head.

  • npm run check:pr — passed
  • npm run check:ci — passed
  • npm run verify:package — passed
  • npm pack --dry-run — passed

Focused regression and reproduction commands ran with the outcomes described above.

Compatibility, safety, and release

  • Breaking changes or migration steps: none.
  • Real Hopper/Ghidra, browser, or OS coverage: Actual native verification ran on macOS arm64. Hopper/Ghidra and other macOS toolchain versions were not run.
  • Package or release metadata impact: no version, dependency, generated catalog or installation changes.
  • Security, privacy, process, or containment review: Uses existing allowlisted Xcode tools with explicit architecture arguments. Final diff contains source and regression tests; local fixtures, binaries, caches and logs are excluded.

Review checklist

  • The PR has one focused outcome and the title follows type(scope): outcome.
  • Related issue is linked, or the reason for not linking one is stated above.
  • Tests cover changed observable behavior and meaningful failure paths.
  • Owning docs, contracts, and generated metadata are updated where needed.
  • User-visible CLI/MCP changes include representative output.
  • I checked the final diff for secrets, unrelated cleanup, and unsupported claims.

AI assistance was used to investigate, implement, and test this change. Commits are signed and include a DCO sign-off.

@rudycelekli

Copy link
Copy Markdown
Author

Synced this branch with current upstream, preserving the owner’s source-map fixture correction from #609. No replacement fixture patch was added.

At 07e0764, the original regression plus webSourceMapFetcher.test.ts, npm run check, and npm run check:fast pass. The complete local suite was not repeated for this maintenance sync under the current contribution policy; GitHub CI on the new head still needs to finish.

@morluto
morluto merged commit 2b7bb3b into morluto:main Oct 5, 2026
19 checks passed
@morluto

morluto commented Oct 7, 2026

Copy link
Copy Markdown
Owner

Thanks, @rudycelekli, for your work on “fix(native): inspect the selected universal Mach-O architecture.” I appreciate your contribution to REA.

darsrc pushed a commit to darsrc/rea that referenced this pull request Oct 10, 2026
@morluto morluto added bug Something isn't working area: native Native analysis and decompilation, including Ghidra, IDA, and Hopper analysis behavior labels Oct 14, 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.

2 participants