Repository navigation
fix(target): decode app Info.plist executables with an XML parser - #857
Merged
Merged
Conversation
The pattern-based reader decoded entities twice, ignored numeric character references and CDATA, and could match a commented or nested CFBundleExecutable key, so valid app bundles reported a missing program. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review SummaryThis 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. |
darsrc
pushed a commit
to darsrc/rea
that referenced
this pull request
Oct 10, 2026
fix(target): decode app Info.plist executables with an XML parser
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
A macOS
.apptarget resolves toContents/MacOS/<CFBundleExecutable>. For XMLInfo.plistfiles,BinaryTargetResolverread that value with a regular expression and a hand-written entity decoder. Several valid plists therefore resolved to the wrong name, andinspect-macho,list-architectures, and session open reportedapp program file is missing:Info.plistcontentplutil -extract CFBundleExecutable rawmain<string>a&lt;b</string>a<ba<b→ missing<string>a b</string>a b<string><![CDATA[a&b]]></string>a&b<key>CFBundleExecutable</key><string>Old</string>before the real keyAppOldCFBundleExecutablebefore the top-level keyFix
XML plists are decoded with the
plistpackage, whichInterfaceBuilderAnalysisalready uses in the application layer. The resolver reads the top-level dictionary'sCFBundleExecutablestring. Binary plists still use nativeplutil -n, unchanged. The existing name-safety andContents/MacOScontainment checks are unchanged. An empty<string/>is now rejected as an unsafe name instead of an unreadable key.This only affects file resolution. Nothing is executed, and there is no provider claim. The whitespace cases from #765 were already handled on
mainand remain covered.Verification
tests/boundary/filesystem/binaryTarget.test.tscover entity, numeric-reference, CDATA, and commented/nested key cases. 4 fail onmainand pass here. The existing whitespace, unsafe-name, symlink-escape, and binary-plist tests still pass (21/21)..appbundles (a&lt;b,a b, and a commented key).node scripts/rea.mjs inspect-macho X.appreportedapp program file is missingfor all three onmain. With this change it resolvesContents/MacOS/a<b,a b, andAppand reportsarm64.npm run check:changed: 18 files / 144 tests passed.npm run check:fastpassed.tests/composition/analysis-sessions/appleApplication.test.tsandtests/boundary/providers/native/nativeProvider.test.tspassed. IninterfaceBuilderBundle.test.ts, the Xcode-compiled storyboard case fails locally on bothmainand this branch, becauseibtoolrequires full Xcode and this host has only Command Line Tools.No Hopper/Ghidra/IDA verification is needed (target path resolution only).
🤖 Generated with Claude Code