用私有API獲得iOS系統裏安裝的全部APP

#include <objc/runtime.h>
Class LSApplicationWorkspace_class = objc_getClass("LSApplicationWorkspace");
NSObject* workspace = [LSApplicationWorkspace_class performSelector:@selector(defaultWorkspace)];
NSLog(@"apps: %@", [workspace performSelector:@selector(allApplications)]);

能夠用於非越獄iOS系統。也許能夠靠混淆拼接字符串繞過審覈,值得一試。app

相關文章
相關標籤/搜索