-
Notifications
You must be signed in to change notification settings - Fork 160
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
mach_inject in Mavericks is broken #5
Comments
Thanks for the report. Patches welcome since currently I can't chase this down myself. |
It looks like it might have to do something with the remote stack size. change: into: It seems to work in both Mavericks and Mountain Lion now. |
Hmm, now I'm wondering if it's a stack alignment issue. |
Still works well in Beta 6. |
Same issue here; will try the modification to see if the patch corrects issue, I wonder if this then breaks Lion |
When I build on OS X 10.9 with the change suggested by @gdonelli , it works fine. But when I build on OS X 10.8.5, I still get the crash. I'm using Xcode 5 for the build on both OSes. Anyone else see this? |
@kunalparmar, it works fine in 18.5 for me. Question: Do you get a crash in 10.8 only with my patch? or also with the default settings (ie that is master)? |
@kunalparmar it works fine in 10.7 , 10.8 and 10.9 with @gdonelli patch. |
@gdonelli, @bafnaparag: I had a setup issue; this works! The comment for line 240 says - "increase the stack, since we're simulating a CALL instruction, which normally pushes return address on the stack". As far I understood, the CALL instruction depends on the processor and not the OS. Can you explain why the stack adjustment is needed for 10.9? Everything works as before on previous OS releases as well. Is it because the return address is unused? Thanks in advance for your help! |
I am speculating in a 64bit architecture we should have data aligned by 64bit ie 8 bytes. No idea what mavericks changes, but it is not unlikely for Apple to change the memory alignment algorithms to improve code security. |
Works fine in GM, would you consider pull request @rentzsch? |
@gdonelli sure, toss me a Pull Request |
@rentzsch Here it is, let me know if you have any problem with it. Thank you! |
The patch does not fix the injection crash for me on Mavericks. Is it working for everyone ? This is the crash signature: Date/Time: 2013-10-29 12:23:45.952 -0400 Sleep/Wake UUID: 3DEAF856-00DB-4FC6-AEF6-1369674F698A Crashed Thread: 13 Exception Type: EXC_BAD_ACCESS (SIGSEGV) Thread 13 Crashed: |
Please ignore my comment. Works like a charm. My test was wrong. |
Hi, Sorry for my english, I'm french. I tried to use the mach_inject_bundle_stub.bundle from Dropbox.app with a simple injector (not sure if this is a good idea), When I try to inject a bundle, mach_inject_bundle_pid returns "err_none" but the Finder crashes immediatly. Thanks in advance, and great job for this very useful tool :) |
I have tried to run various examples of code_inject in Mavericks but they result in the target process crashing with the following stack:
Thread 6 Crashed:
0 libsystem_c.dylib 0x00007fff8e68c505 __xvprintf + 106
I am opening an issue hoping we can figure out a solution.
The text was updated successfully, but these errors were encountered: