iOS11 tweak 注入无效
设备:iPhone7Plus, 系统版本: iOS11.0.3 通过爱思助手越狱(Electra 1.0.4)
问题:编写tweak后,生成的dylib注入无效
相关检索:
- iOS 11越狱系列 中提到:
看到作者加了一个tweak inject的工具,注入存在问题。
hook 部分: TweakInject 模块负责加载你编写的dylib库。 iOS11 的dpkg工具好像做了重构。 新版的动态库会被安装到
/Library/TweakInject/aaaa.dylib
/Library/MobileSubstrate/DynamicLibraries/aaaa.dylib
这2个目录会存在同样的文件。 TweakInject 库会自动加载TweakInject 目录下的库。
直接安装mobile substrate 后。SB挂掉, 和weak inject 有冲突。 tweak 工具暂时不能使用。
- iosre最后一个回复提到:
/usr/lib/TweakInject
连接到/Library/MobileSubstrate/DynamicLibraries
-
reddit- [Tutorial] [Fix] [Electra] How to fix tweaks not showing/working in electra 1.0.4 jailbreak (tweaks installing but not showing in settings or working)
中解决办法:
The bottom line is, the Substrate Compatibility Layer package tries to make /Library/MobileSubstrate/DynamicLibraries as a symlink to ../../usr/lib/TweakInject ie. /usr/lib/TweakInject. So if you have that /Library/MobileSubstrate/DynamicLibraries folder there already, the package cannot overwrite it, and we face this problem. Need to move everything from DynamicLibraries/ into /usr/lib/TweakInject/, remove the DynamicLibraries, and re-create it as a symlink to /usr/lib/TweakInject.
谷歌翻译下就是:
Substrate Compatibility Layer包尝试使/ Library / MobileSubstrate / DynamicLibraries成为../../usr/lib/TweakInject的符号链接。/ usr / lib中/ TweakInject。所以如果你已经有了/ Library / MobileSubstrate / DynamicLibraries文件夹,那么这个软件包不能覆盖它,而且我们面临这个问题。需要将所有内容从DynamicLibraries /移动到/ usr / lib / TweakInject /中,删除DynamicLibraries并将其重新创建为/ usr / lib / TweakInject的符号链接。