Bound Objective-C metadata table and loaded-image reads - #89
Merged
Conversation
Owner
Author
|
@codex review |
|
Codex Review: Didn't find any major issues. Hooray! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
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.
Purpose
Objective-C table counts, byte ranges, loaded root pointers, and referenced layouts are external metadata. Several MachOObjCSection paths still performed unchecked arithmetic, trapping file reads, or unproved loaded-image dereferences. This change makes those structural failures recoverable and keeps readable sibling metadata without claiming they caused the previously observed iOS 27 failures.
Changes
41a1652d95c34bbb2fdf32ba4b7f5cd9d3ba20ba, which centralizes bounded file/image table reads, checks method-entry arithmetic and method-section iteration, and adds checked loaded root and relationship readers.ObjCMetadataTableDiagnosticresults for regular member tables, loaded roots, and loaded relationships across class, protocol, and category reads.3344bd04e6c0819b17df126bea57bae1bbed3022and update the exact-pin contract test.Review focus
Testing
MachOSwiftSectionproduct build, and 6 ObjC-ancestor tests passed after rebuilding the repository-required fixture; codex-review reported no findings.swift test, Release build, iOS/watchOS Core and test compile checks, both simulator-helper Release builds, release-script tests, and exact dependency-pin tests passed.24A5390f:Foundationcompleted with 859 generated files, no Objective-C metadata warnings, and anokdatabase integrity check.AXSpringBoardServerInstancecompleted the new metadata collection and then reproduced its known post-collectionSpringBoardUI +loadabort in runtime fallback; the failure capsule and Crash Reporter agreed on PID, LC_UUID, and SIGABRT.main: no findings (B4EC3F19-7ED9-4C85-BCE1-56A8B301C6A0).Closes #83