Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix dyldcache deps carving logic ##bin #23044

Merged
merged 1 commit into from
Jun 17, 2024
Merged

Conversation

mrmacete
Copy link
Collaborator

  • Mark this if you consider it ready to merge
  • I've added tests (optional)
  • I wrote some lines in the book (optional)

Description

The dyldcache-specific logic which parses library-loading Mach-O load commands to carve dependencies in order to filter them was wrongly assuming the path of the loaded library is always at offset 24 instead of looking up the right offset from the command itself.

While this was working 99.99% of the times, when it didn't it broke the deps carving logic and produced weird-looking "alien dep" errors.

The dyldcache-specific logic which parses library-loading Mach-O load
commands to carve dependencies in order to filter them was wrongly
assuming the path of the loaded library is always at offset 24 instead
of looking up the right offset from the command itself.

While this was working 99.99% of the times, when it didn't it broke the
deps carving logic and produced weird-looking "alien dep" errors.
@trufae trufae merged commit 4f1d5be into master Jun 17, 2024
41 checks passed
@trufae trufae deleted the fix/dyldcache-deps-carving-lc branch June 20, 2024 12:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants