[PR #590] [MERGED] fix(native): inspect Apple dispatch metadata in FAT64 binaries #2090

Closed
opened 2026-10-16 21:14:07 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/590
Author: @rudycelekli
Created: 10/5/2026
Status: ✅ Merged
Merged: 10/5/2026
Merged by: @morluto

Base: main ← Head: campaign/rea-dispatch-fat64-20261005


📝 Commits (1)

  • 61c9396 fix(native): inspect Apple dispatch metadata in FAT64 binaries

📊 Changes

2 files changed (+107 additions, -23 deletions)

View changed files

📝 src/native/AppleDispatchMetadata.test.ts (+74 -0)
📝 src/native/AppleDispatchMetadata.ts (+33 -23)

📄 Description

What changed

Apple dispatch metadata recognized only FAT_MAGIC, so a valid FAT_MAGIC_64 universal binary produced an unsupported thin-Mach-O error. Read 32-byte fat_arch_64 records and preserve selected slice offsets using checked BigInt extents. Existing FAT32 behavior remains covered. Regression cases also reject truncated FAT64 tables, out-of-file 64-bit extents, duplicate selected architectures, and absent architectures.

Verification

The FAT64 regression fails against upstream; all eleven Apple dispatch tests pass after the fix. verify:apple-dispatch passes its actual clang and Swift symbol/stripped fixtures. An additional source-built Objective-C dispatch fixture wrapped by xcrun lipo -fat64 retains its performAction: implementation and protocol observations.

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

Native Apple dispatch verification ran on macOS arm64. The decoder remains limited to its existing supported metadata families and reports partial/external/unsupported facets. Hopper and Ghidra were not run.

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


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/morluto/rea/pull/590 **Author:** [@rudycelekli](https://github.com/rudycelekli) **Created:** 10/5/2026 **Status:** ✅ Merged **Merged:** 10/5/2026 **Merged by:** [@morluto](https://github.com/morluto) **Base:** `main` ← **Head:** `campaign/rea-dispatch-fat64-20261005` --- ### 📝 Commits (1) - [`61c9396`](https://github.com/morluto/rea/commit/61c93969eb98fb6b5c32abffda60f5226ccb62b4) fix(native): inspect Apple dispatch metadata in FAT64 binaries ### 📊 Changes **2 files changed** (+107 additions, -23 deletions) <details> <summary>View changed files</summary> 📝 `src/native/AppleDispatchMetadata.test.ts` (+74 -0) 📝 `src/native/AppleDispatchMetadata.ts` (+33 -23) </details> ### 📄 Description ## What changed Apple dispatch metadata recognized only FAT_MAGIC, so a valid FAT_MAGIC_64 universal binary produced an unsupported thin-Mach-O error. Read 32-byte fat_arch_64 records and preserve selected slice offsets using checked BigInt extents. Existing FAT32 behavior remains covered. Regression cases also reject truncated FAT64 tables, out-of-file 64-bit extents, duplicate selected architectures, and absent architectures. ## Verification The FAT64 regression fails against upstream; all eleven Apple dispatch tests pass after the fix. verify:apple-dispatch passes its actual clang and Swift symbol/stripped fixtures. An additional source-built Objective-C dispatch fixture wrapped by xcrun lipo -fat64 retains its performAction: implementation and protocol observations. - `npm run check:pr` - `npm run check:ci` - `npm run verify:package` - `npm pack --dry-run` Native Apple dispatch verification ran on macOS arm64. The decoder remains limited to its existing supported metadata families and reports partial/external/unsupported facets. Hopper and Ghidra were not run. AI assistance was used to investigate, implement, and test this change. Commits are signed and include a DCO sign-off. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-16 21:14:07 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#2090
No description provided.