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

Corrupted Binary after using gum-graft on iOS Framework Binary #1006

Open
I98 opened this issue Mar 21, 2025 · 0 comments
Open

Corrupted Binary after using gum-graft on iOS Framework Binary #1006

I98 opened this issue Mar 21, 2025 · 0 comments

Comments

@I98
Copy link

I98 commented Mar 21, 2025

Steps to reproduce:

  1. gum-graft function at offset in a framework binary: gum-graft Payload/App.app/Frameworks/AppFramework.framework/AppFramework --instrument=0x<address>
  2. The app crashes during startup. xcrun dyld_info Payload/App.app/Frameworks/AppFramework.framework/AppFramework outputs the error message dyld_info: 'AppFramework' chained fixups, seg_count does not match number of segments

Used frida version 16.7.0

Unfortunately I am not sure if I am allowed to upload the binary here, if I find some time I will try to reproduce the error in a sample app.

Meanwhile the following workaround was successful:

  1. Copy the Binary
  2. gum-graft the copied binary
  3. Use lief.re in python to open both binaries
  4. Add the segments starting with __FRIDA from the grafted to the ungrafted binary (In the same order)
  5. Copy the __TEXT, __text section from the grafted to the ungrafted binary
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

No branches or pull requests

1 participant