mirror of https://github.com/opa334/TrollStore.git
Add TrollInstaller2 installation method for all arm64e devices 14.0-15.5b4
This commit is contained in:
parent
7dcc863f2b
commit
f75e1f3450
|
@ -3,4 +3,6 @@ out/
|
||||||
.theos/
|
.theos/
|
||||||
packages/
|
packages/
|
||||||
xcuserdata
|
xcuserdata
|
||||||
.vscode
|
.vscode
|
||||||
|
pwnify_compiled
|
||||||
|
Developer.ipa
|
|
@ -13,6 +13,11 @@
|
||||||
#import <SpringBoardServices/SpringBoardServices.h>
|
#import <SpringBoardServices/SpringBoardServices.h>
|
||||||
#import <Security/Security.h>
|
#import <Security/Security.h>
|
||||||
|
|
||||||
|
#ifdef INSTALLER_EMBEDDED
|
||||||
|
#define MAIN_NAME rootHelperMain
|
||||||
|
#else
|
||||||
|
#define MAIN_NAME main
|
||||||
|
#endif
|
||||||
|
|
||||||
extern mach_msg_return_t SBReloadIconForIdentifier(mach_port_t machport, const char* identifier);
|
extern mach_msg_return_t SBReloadIconForIdentifier(mach_port_t machport, const char* identifier);
|
||||||
@interface SBSHomeScreenService : NSObject
|
@interface SBSHomeScreenService : NSObject
|
||||||
|
@ -1093,7 +1098,8 @@ void uninstallPersistenceHelper(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int argc, char *argv[], char *envp[]) {
|
int MAIN_NAME(int argc, char *argv[], char *envp[])
|
||||||
|
{
|
||||||
@autoreleasepool {
|
@autoreleasepool {
|
||||||
if(argc <= 1) return -1;
|
if(argc <= 1) return -1;
|
||||||
|
|
||||||
|
|
28
README.md
28
README.md
|
@ -10,8 +10,6 @@ It works because of a CoreTrust bug that affects iOS 14.0 - 15.4.1 (15.5b4).
|
||||||
|
|
||||||
N/A means: NO DEVICE / VERSION COMBINATION EXISTS
|
N/A means: NO DEVICE / VERSION COMBINATION EXISTS
|
||||||
|
|
||||||
None means: No way to install TrollStore currently
|
|
||||||
|
|
||||||
| Version / Device | A8 | A9 | A10 | A11 | A12 | A13 | A14 | A15 |
|
| Version / Device | A8 | A9 | A10 | A11 | A12 | A13 | A14 | A15 |
|
||||||
| --- | --- | --- | --- | --- | --- | --- | --- | --- |
|
| --- | --- | --- | --- | --- | --- | --- | --- | --- |
|
||||||
| iOS 14.0 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
| iOS 14.0 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
||||||
|
@ -25,25 +23,23 @@ None means: No way to install TrollStore currently
|
||||||
| iOS 14.4.2 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
| iOS 14.4.2 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
||||||
| iOS 14.5 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
| iOS 14.5 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
||||||
| iOS 14.5.1 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
| iOS 14.5.1 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | N/A |
|
||||||
| iOS 14.6 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | None | N/A |
|
| iOS 14.6 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollInstaller2](./install_trollinstaller2) | N/A |
|
||||||
| iOS 14.7 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | None | N/A |
|
| iOS 14.7 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollInstaller2](./install_trollinstaller2) | N/A |
|
||||||
| iOS 14.7.1 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | None | N/A |
|
| iOS 14.7.1 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollInstaller2](./install_trollinstaller2) | N/A |
|
||||||
| iOS 14.8 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | None | N/A |
|
| iOS 14.8 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollInstaller2](./install_trollinstaller2) | N/A |
|
||||||
| iOS 14.8.1 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | None | None | None | N/A |
|
| iOS 14.8.1 | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollHelper](./install_trollhelper.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | N/A |
|
||||||
| iOS 15.0 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
| iOS 15.0 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
||||||
| iOS 15.0.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
| iOS 15.0.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
||||||
| iOS 15.0.2 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
| iOS 15.0.2 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
||||||
| iOS 15.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
| iOS 15.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
||||||
| iOS 15.1.1 | N/A | N/A | N/A | N/A | N/A | N/A | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
| iOS 15.1.1 | N/A | N/A | N/A | N/A | N/A | N/A | [TrollInstaller](./install_trollinstaller.md) | [TrollInstaller](./install_trollinstaller.md) |
|
||||||
| iOS 15.2 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | None | None | None | None |
|
| iOS 15.2 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) |
|
||||||
| iOS 15.2.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | None | None | None | None |
|
| iOS 15.2.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) |
|
||||||
| iOS 15.3 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | None | None | None | None |
|
| iOS 15.3 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) |
|
||||||
| iOS 15.3.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | None | None | None | None |
|
| iOS 15.3.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) |
|
||||||
| iOS 15.4 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | None | None | None | None |
|
| iOS 15.4 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) |
|
||||||
| iOS 15.4.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | None | None | None | None |
|
| iOS 15.4.1 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) |
|
||||||
| iOS 15.5 Beta 1 - Beta 4 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | None | None | None | None |
|
| iOS 15.5 Beta 1 - Beta 4 | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [SSH Ramdisk](./install_with_sshrd.md) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) | [TrollInstaller2](./install_trollinstaller2) |
|
||||||
|
|
||||||
Full 14.0 - 15.5b4 installation support will come when the Fugu15 installation method is public.
|
|
||||||
|
|
||||||
# Updating TrollStore
|
# Updating TrollStore
|
||||||
|
|
||||||
|
|
|
@ -13,6 +13,7 @@
|
||||||
- (void)startActivity:(NSString*)activity;
|
- (void)startActivity:(NSString*)activity;
|
||||||
- (void)stopActivityWithCompletion:(void (^)(void))completion;
|
- (void)stopActivityWithCompletion:(void (^)(void))completion;
|
||||||
|
|
||||||
|
- (void)downloadTrollStoreAndDo:(void (^)(NSString* localTrollStoreTarPath))doHandler;
|
||||||
- (void)installTrollStorePressed;
|
- (void)installTrollStorePressed;
|
||||||
- (void)updateTrollStorePressed;
|
- (void)updateTrollStorePressed;
|
||||||
- (void)rebuildIconCachePressed;
|
- (void)rebuildIconCachePressed;
|
||||||
|
|
|
@ -53,20 +53,11 @@
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)_updateOrInstallTrollStore:(BOOL)update
|
- (void)downloadTrollStoreAndDo:(void (^)(NSString* localTrollStoreTarPath))doHandler
|
||||||
{
|
{
|
||||||
NSURL* trollStoreURL = [NSURL URLWithString:@"https://github.com/opa334/TrollStore/releases/latest/download/TrollStore.tar"];
|
NSURL* trollStoreURL = [NSURL URLWithString:@"https://github.com/opa334/TrollStore/releases/latest/download/TrollStore.tar"];
|
||||||
NSURLRequest* trollStoreRequest = [NSURLRequest requestWithURL:trollStoreURL];
|
NSURLRequest* trollStoreRequest = [NSURLRequest requestWithURL:trollStoreURL];
|
||||||
|
|
||||||
if(update)
|
|
||||||
{
|
|
||||||
[self startActivity:@"Updating TrollStore"];
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
[self startActivity:@"Installing TrollStore"];
|
|
||||||
}
|
|
||||||
|
|
||||||
NSURLSessionDownloadTask* downloadTask = [NSURLSession.sharedSession downloadTaskWithRequest:trollStoreRequest completionHandler:^(NSURL *location, NSURLResponse *response, NSError *error)
|
NSURLSessionDownloadTask* downloadTask = [NSURLSession.sharedSession downloadTaskWithRequest:trollStoreRequest completionHandler:^(NSURL *location, NSURLResponse *response, NSError *error)
|
||||||
{
|
{
|
||||||
if(error)
|
if(error)
|
||||||
|
@ -88,27 +79,36 @@
|
||||||
NSString* tarTmpPath = [NSTemporaryDirectory() stringByAppendingPathComponent:@"TrollStore.tar"];
|
NSString* tarTmpPath = [NSTemporaryDirectory() stringByAppendingPathComponent:@"TrollStore.tar"];
|
||||||
[[NSFileManager defaultManager] copyItemAtPath:location.path toPath:tarTmpPath error:nil];
|
[[NSFileManager defaultManager] copyItemAtPath:location.path toPath:tarTmpPath error:nil];
|
||||||
|
|
||||||
int ret = spawnRoot(helperPath(), @[@"install-trollstore", tarTmpPath], nil, nil);
|
doHandler(tarTmpPath);
|
||||||
[[NSFileManager defaultManager] removeItemAtPath:tarTmpPath error:nil];
|
}
|
||||||
|
}];
|
||||||
|
|
||||||
if(ret == 0)
|
[downloadTask resume];
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)_updateOrInstallTrollStore:(BOOL)update
|
||||||
|
{
|
||||||
|
if(update)
|
||||||
|
{
|
||||||
|
[self startActivity:@"Updating TrollStore"];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
[self startActivity:@"Installing TrollStore"];
|
||||||
|
}
|
||||||
|
|
||||||
|
[self downloadTrollStoreAndDo:^(NSString* tmpTarPath)
|
||||||
|
{
|
||||||
|
int ret = spawnRoot(helperPath(), @[@"install-trollstore", tmpTarPath], nil, nil);
|
||||||
|
[[NSFileManager defaultManager] removeItemAtPath:tmpTarPath error:nil];
|
||||||
|
|
||||||
|
if(ret == 0)
|
||||||
|
{
|
||||||
|
respring();
|
||||||
|
|
||||||
|
if([self isTrollStore])
|
||||||
{
|
{
|
||||||
respring();
|
exit(0);
|
||||||
|
|
||||||
if([self isTrollStore])
|
|
||||||
{
|
|
||||||
exit(0);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
dispatch_async(dispatch_get_main_queue(), ^
|
|
||||||
{
|
|
||||||
[self stopActivityWithCompletion:^
|
|
||||||
{
|
|
||||||
[self reloadSpecifiers];
|
|
||||||
}];
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -116,17 +116,25 @@
|
||||||
{
|
{
|
||||||
[self stopActivityWithCompletion:^
|
[self stopActivityWithCompletion:^
|
||||||
{
|
{
|
||||||
UIAlertController* errorAlert = [UIAlertController alertControllerWithTitle:@"Error" message:[NSString stringWithFormat:@"Error installing TrollStore: trollstorehelper returned %d", ret] preferredStyle:UIAlertControllerStyleAlert];
|
[self reloadSpecifiers];
|
||||||
UIAlertAction* closeAction = [UIAlertAction actionWithTitle:@"Close" style:UIAlertActionStyleDefault handler:nil];
|
|
||||||
[errorAlert addAction:closeAction];
|
|
||||||
[self presentViewController:errorAlert animated:YES completion:nil];
|
|
||||||
}];
|
}];
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dispatch_async(dispatch_get_main_queue(), ^
|
||||||
|
{
|
||||||
|
[self stopActivityWithCompletion:^
|
||||||
|
{
|
||||||
|
UIAlertController* errorAlert = [UIAlertController alertControllerWithTitle:@"Error" message:[NSString stringWithFormat:@"Error installing TrollStore: trollstorehelper returned %d", ret] preferredStyle:UIAlertControllerStyleAlert];
|
||||||
|
UIAlertAction* closeAction = [UIAlertAction actionWithTitle:@"Close" style:UIAlertActionStyleDefault handler:nil];
|
||||||
|
[errorAlert addAction:closeAction];
|
||||||
|
[self presentViewController:errorAlert animated:YES completion:nil];
|
||||||
|
}];
|
||||||
|
});
|
||||||
|
}
|
||||||
}];
|
}];
|
||||||
|
|
||||||
[downloadTask resume];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)installTrollStorePressed
|
- (void)installTrollStorePressed
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
.theos/
|
||||||
|
packages/
|
||||||
|
.DS_Store
|
|
@ -0,0 +1,17 @@
|
||||||
|
TARGET := iphone:clang:14.5:14.0
|
||||||
|
INSTALL_TARGET_PROCESSES = TrollInstaller2
|
||||||
|
ARCHS = arm64e
|
||||||
|
|
||||||
|
include $(THEOS)/makefiles/common.mk
|
||||||
|
|
||||||
|
APPLICATION_NAME = TrollInstaller2
|
||||||
|
|
||||||
|
TrollInstaller2_FILES = main.m $(wildcard *.m) $(wildcard ../Helper/*.m) ../Store/TSListControllerShared.m ../Store/TSUtil.m
|
||||||
|
TrollInstaller2_FRAMEWORKS = UIKit CoreGraphics
|
||||||
|
TrollInstaller2_PRIVATE_FRAMEWORKS = Preferences
|
||||||
|
TrollInstaller2_LIBRARIES = archive
|
||||||
|
TrollInstaller2_CFLAGS = -fobjc-arc -DINSTALLER_EMBEDDED=1
|
||||||
|
TrollInstaller2_PRIVATE_FRAMEWORKS = SpringBoardServices BackBoardServices
|
||||||
|
TrollInstaller2_CODESIGN_FLAGS = -Sentitlements.plist
|
||||||
|
|
||||||
|
include $(THEOS_MAKE_PATH)/application.mk
|
|
@ -0,0 +1,154 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0">
|
||||||
|
<dict>
|
||||||
|
<key>CFBundleExecutable</key>
|
||||||
|
<string>TrollInstaller2</string>
|
||||||
|
<key>CFBundleIcons</key>
|
||||||
|
<dict>
|
||||||
|
<key>CFBundlePrimaryIcon</key>
|
||||||
|
<dict>
|
||||||
|
<key>CFBundleIconFiles</key>
|
||||||
|
<array>
|
||||||
|
<string>AppIcon29x29</string>
|
||||||
|
<string>AppIcon40x40</string>
|
||||||
|
<string>AppIcon57x57</string>
|
||||||
|
<string>AppIcon60x60</string>
|
||||||
|
</array>
|
||||||
|
<key>UIPrerenderedIcon</key>
|
||||||
|
<true/>
|
||||||
|
</dict>
|
||||||
|
</dict>
|
||||||
|
<key>CFBundleIcons~ipad</key>
|
||||||
|
<dict>
|
||||||
|
<key>CFBundlePrimaryIcon</key>
|
||||||
|
<dict>
|
||||||
|
<key>CFBundleIconFiles</key>
|
||||||
|
<array>
|
||||||
|
<string>AppIcon29x29</string>
|
||||||
|
<string>AppIcon40x40</string>
|
||||||
|
<string>AppIcon57x57</string>
|
||||||
|
<string>AppIcon60x60</string>
|
||||||
|
<string>AppIcon50x50</string>
|
||||||
|
<string>AppIcon72x72</string>
|
||||||
|
<string>AppIcon76x76</string>
|
||||||
|
</array>
|
||||||
|
<key>UIPrerenderedIcon</key>
|
||||||
|
<true/>
|
||||||
|
</dict>
|
||||||
|
</dict>
|
||||||
|
<key>CFBundleIdentifier</key>
|
||||||
|
<string>com.opa334.trollinstaller2</string>
|
||||||
|
<key>CFBundleInfoDictionaryVersion</key>
|
||||||
|
<string>6.0</string>
|
||||||
|
<key>CFBundlePackageType</key>
|
||||||
|
<string>APPL</string>
|
||||||
|
<key>CFBundleSignature</key>
|
||||||
|
<string>????</string>
|
||||||
|
<key>CFBundleSupportedPlatforms</key>
|
||||||
|
<array>
|
||||||
|
<string>iPhoneOS</string>
|
||||||
|
</array>
|
||||||
|
<key>CFBundleVersion</key>
|
||||||
|
<string>1.0</string>
|
||||||
|
<key>LSRequiresIPhoneOS</key>
|
||||||
|
<true/>
|
||||||
|
<key>UIDeviceFamily</key>
|
||||||
|
<array>
|
||||||
|
<integer>1</integer>
|
||||||
|
<integer>2</integer>
|
||||||
|
</array>
|
||||||
|
<key>UIRequiredDeviceCapabilities</key>
|
||||||
|
<array>
|
||||||
|
<string>armv7</string>
|
||||||
|
</array>
|
||||||
|
<key>UILaunchImageFile</key>
|
||||||
|
<string>LaunchImage</string>
|
||||||
|
<key>UILaunchImages</key>
|
||||||
|
<array>
|
||||||
|
<dict>
|
||||||
|
<key>UILaunchImageMinimumOSVersion</key>
|
||||||
|
<string>7.0</string>
|
||||||
|
<key>UILaunchImageName</key>
|
||||||
|
<string>LaunchImage</string>
|
||||||
|
<key>UILaunchImageOrientation</key>
|
||||||
|
<string>Portrait</string>
|
||||||
|
<key>UILaunchImageSize</key>
|
||||||
|
<string>{320, 480}</string>
|
||||||
|
</dict>
|
||||||
|
<dict>
|
||||||
|
<key>UILaunchImageMinimumOSVersion</key>
|
||||||
|
<string>7.0</string>
|
||||||
|
<key>UILaunchImageName</key>
|
||||||
|
<string>LaunchImage-700-568h</string>
|
||||||
|
<key>UILaunchImageOrientation</key>
|
||||||
|
<string>Portrait</string>
|
||||||
|
<key>UILaunchImageSize</key>
|
||||||
|
<string>{320, 568}</string>
|
||||||
|
</dict>
|
||||||
|
<dict>
|
||||||
|
<key>UILaunchImageMinimumOSVersion</key>
|
||||||
|
<string>7.0</string>
|
||||||
|
<key>UILaunchImageName</key>
|
||||||
|
<string>LaunchImage-Portrait</string>
|
||||||
|
<key>UILaunchImageOrientation</key>
|
||||||
|
<string>Portrait</string>
|
||||||
|
<key>UILaunchImageSize</key>
|
||||||
|
<string>{768, 1024}</string>
|
||||||
|
</dict>
|
||||||
|
<dict>
|
||||||
|
<key>UILaunchImageMinimumOSVersion</key>
|
||||||
|
<string>7.0</string>
|
||||||
|
<key>UILaunchImageName</key>
|
||||||
|
<string>LaunchImage-Landscape</string>
|
||||||
|
<key>UILaunchImageOrientation</key>
|
||||||
|
<string>Landscape</string>
|
||||||
|
<key>UILaunchImageSize</key>
|
||||||
|
<string>{768, 1024}</string>
|
||||||
|
</dict>
|
||||||
|
<dict>
|
||||||
|
<key>UILaunchImageMinimumOSVersion</key>
|
||||||
|
<string>8.0</string>
|
||||||
|
<key>UILaunchImageName</key>
|
||||||
|
<string>LaunchImage-800-667h</string>
|
||||||
|
<key>UILaunchImageOrientation</key>
|
||||||
|
<string>Portrait</string>
|
||||||
|
<key>UILaunchImageSize</key>
|
||||||
|
<string>{375, 667}</string>
|
||||||
|
</dict>
|
||||||
|
<dict>
|
||||||
|
<key>UILaunchImageMinimumOSVersion</key>
|
||||||
|
<string>8.0</string>
|
||||||
|
<key>UILaunchImageName</key>
|
||||||
|
<string>LaunchImage-800-Portrait-736h</string>
|
||||||
|
<key>UILaunchImageOrientation</key>
|
||||||
|
<string>Portrait</string>
|
||||||
|
<key>UILaunchImageSize</key>
|
||||||
|
<string>{414, 736}</string>
|
||||||
|
</dict>
|
||||||
|
<dict>
|
||||||
|
<key>UILaunchImageMinimumOSVersion</key>
|
||||||
|
<string>8.0</string>
|
||||||
|
<key>UILaunchImageName</key>
|
||||||
|
<string>LaunchImage-800-Landscape-736h</string>
|
||||||
|
<key>UILaunchImageOrientation</key>
|
||||||
|
<string>Landscape</string>
|
||||||
|
<key>UILaunchImageSize</key>
|
||||||
|
<string>{414, 736}</string>
|
||||||
|
</dict>
|
||||||
|
</array>
|
||||||
|
<key>UISupportedInterfaceOrientations</key>
|
||||||
|
<array>
|
||||||
|
<string>UIInterfaceOrientationPortrait</string>
|
||||||
|
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||||
|
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||||
|
</array>
|
||||||
|
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||||
|
<array>
|
||||||
|
<string>UIInterfaceOrientationPortrait</string>
|
||||||
|
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
||||||
|
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||||
|
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||||
|
</array>
|
||||||
|
</dict>
|
||||||
|
</plist>
|
|
@ -0,0 +1,6 @@
|
||||||
|
|
||||||
|
#import <UIKit/UIKit.h>
|
||||||
|
|
||||||
|
@interface TSI2AppDelegate : UIResponder <UIApplicationDelegate>
|
||||||
|
|
||||||
|
@end
|
|
@ -0,0 +1,22 @@
|
||||||
|
#import "TSI2AppDelegate.h"
|
||||||
|
|
||||||
|
@implementation TSI2AppDelegate
|
||||||
|
|
||||||
|
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
|
||||||
|
return YES;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (UISceneConfiguration *)application:(UIApplication *)application configurationForConnectingSceneSession:(UISceneSession *)connectingSceneSession options:(UISceneConnectionOptions *)options {
|
||||||
|
// Called when a new scene session is being created.
|
||||||
|
// Use this method to select a configuration to create the new scene with.
|
||||||
|
return [[UISceneConfiguration alloc] initWithName:@"Default Configuration" sessionRole:connectingSceneSession.role];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
- (void)application:(UIApplication *)application didDiscardSceneSessions:(NSSet<UISceneSession *> *)sceneSessions {
|
||||||
|
// Called when the user discards a scene session.
|
||||||
|
// If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions.
|
||||||
|
// Use this method to release any resources that were specific to the discarded scenes, as they will not return.
|
||||||
|
}
|
||||||
|
|
||||||
|
@end
|
|
@ -0,0 +1,7 @@
|
||||||
|
#import "../Store/TSListControllerShared.h"
|
||||||
|
|
||||||
|
@interface TSI2RootViewController : TSListControllerShared
|
||||||
|
{
|
||||||
|
NSString* _newerVersion;
|
||||||
|
}
|
||||||
|
@end
|
|
@ -0,0 +1,96 @@
|
||||||
|
#import "TSI2RootViewController.h"
|
||||||
|
#import "../Helper/Shared.h"
|
||||||
|
#import "../Store/TSUtil.h"
|
||||||
|
|
||||||
|
@implementation TSI2RootViewController
|
||||||
|
|
||||||
|
- (NSMutableArray*)specifiers
|
||||||
|
{
|
||||||
|
if(!_specifiers)
|
||||||
|
{
|
||||||
|
_specifiers = [NSMutableArray new];
|
||||||
|
|
||||||
|
BOOL isInstalled = trollStoreAppPath();
|
||||||
|
|
||||||
|
PSSpecifier* utilitiesGroupSpecifier = [PSSpecifier emptyGroupSpecifier];
|
||||||
|
[_specifiers addObject:utilitiesGroupSpecifier];
|
||||||
|
[utilitiesGroupSpecifier setProperty:@"Based on the Fugu15 install method\nMassive shoutouts to @LinusHenze\n\n© 2022 Lars Fröder (opa334)" forKey:@"footerText"];
|
||||||
|
|
||||||
|
if(isInstalled)
|
||||||
|
{
|
||||||
|
PSSpecifier* alreadyInstalledSpecifier = [PSSpecifier preferenceSpecifierNamed:@"TrollStore already installed"
|
||||||
|
target:self
|
||||||
|
set:nil
|
||||||
|
get:nil
|
||||||
|
detail:nil
|
||||||
|
cell:PSStaticTextCell
|
||||||
|
edit:nil];
|
||||||
|
alreadyInstalledSpecifier.identifier = @"alreadyInstalled";
|
||||||
|
[alreadyInstalledSpecifier setProperty:@YES forKey:@"enabled"];
|
||||||
|
[_specifiers addObject:alreadyInstalledSpecifier];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PSSpecifier* installTrollStoreSpecifier = [PSSpecifier preferenceSpecifierNamed:@"Install TrollStore"
|
||||||
|
target:self
|
||||||
|
set:nil
|
||||||
|
get:nil
|
||||||
|
detail:nil
|
||||||
|
cell:PSButtonCell
|
||||||
|
edit:nil];
|
||||||
|
installTrollStoreSpecifier.identifier = @"installTrollStore";
|
||||||
|
[installTrollStoreSpecifier setProperty:@YES forKey:@"enabled"];
|
||||||
|
installTrollStoreSpecifier.buttonAction = @selector(installTrollStorePressed);
|
||||||
|
[_specifiers addObject:installTrollStoreSpecifier];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
[(UINavigationItem *)self.navigationItem setTitle:@"TrollStore Installer 2"];
|
||||||
|
return _specifiers;
|
||||||
|
}
|
||||||
|
|
||||||
|
extern NSString* safe_getExecutablePath();
|
||||||
|
- (void)installTrollStorePressed
|
||||||
|
{
|
||||||
|
[self startActivity:@"Installing TrollStore"];
|
||||||
|
|
||||||
|
[self downloadTrollStoreAndDo:^(NSString* tmpTarPath)
|
||||||
|
{
|
||||||
|
int ret = spawnRoot(safe_getExecutablePath(), @[@"install-trollstore", tmpTarPath], nil, nil);
|
||||||
|
[[NSFileManager defaultManager] removeItemAtPath:tmpTarPath error:nil];
|
||||||
|
if(ret == 0)
|
||||||
|
{
|
||||||
|
respring();
|
||||||
|
|
||||||
|
if([self isTrollStore])
|
||||||
|
{
|
||||||
|
exit(0);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dispatch_async(dispatch_get_main_queue(), ^
|
||||||
|
{
|
||||||
|
[self stopActivityWithCompletion:^
|
||||||
|
{
|
||||||
|
[self reloadSpecifiers];
|
||||||
|
}];
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dispatch_async(dispatch_get_main_queue(), ^
|
||||||
|
{
|
||||||
|
[self stopActivityWithCompletion:^
|
||||||
|
{
|
||||||
|
UIAlertController* errorAlert = [UIAlertController alertControllerWithTitle:@"Error" message:[NSString stringWithFormat:@"Error installing TrollStore: trollstorehelper returned %d", ret] preferredStyle:UIAlertControllerStyleAlert];
|
||||||
|
UIAlertAction* closeAction = [UIAlertAction actionWithTitle:@"Close" style:UIAlertActionStyleDefault handler:nil];
|
||||||
|
[errorAlert addAction:closeAction];
|
||||||
|
[self presentViewController:errorAlert animated:YES completion:nil];
|
||||||
|
}];
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
@end
|
|
@ -0,0 +1,6 @@
|
||||||
|
#import <UIKit/UIKit.h>
|
||||||
|
|
||||||
|
@interface TSI2SceneDelegate : UIResponder <UIWindowSceneDelegate>
|
||||||
|
@property (strong, nonatomic) UIWindow * window;
|
||||||
|
@property (nonatomic, strong) UINavigationController *rootViewController;
|
||||||
|
@end
|
|
@ -0,0 +1,55 @@
|
||||||
|
#import "TSI2SceneDelegate.h"
|
||||||
|
#import "TSI2RootViewController.h"
|
||||||
|
|
||||||
|
@implementation TSI2SceneDelegate
|
||||||
|
|
||||||
|
- (void)scene:(UIScene *)scene willConnectToSession:(UISceneSession *)session options:(UISceneConnectionOptions *)connectionOptions {
|
||||||
|
// Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`.
|
||||||
|
// If using a storyboard, the `window` property will automatically be initialized and attached to the scene.
|
||||||
|
// This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead).
|
||||||
|
|
||||||
|
NSLog(@"scene:%@ willConnectToSession:%@ options:%@", scene, session, connectionOptions);
|
||||||
|
UIWindowScene* windowScene = (UIWindowScene*)scene;
|
||||||
|
_window = [[UIWindow alloc] initWithWindowScene:windowScene];
|
||||||
|
_rootViewController = [[UINavigationController alloc] initWithRootViewController:[[TSI2RootViewController alloc] init]];
|
||||||
|
_window.rootViewController = _rootViewController;
|
||||||
|
[_window makeKeyAndVisible];
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)sceneDidDisconnect:(UIScene *)scene {
|
||||||
|
// Called as the scene is being released by the system.
|
||||||
|
// This occurs shortly after the scene enters the background, or when its session is discarded.
|
||||||
|
// Release any resources associated with this scene that can be re-created the next time the scene connects.
|
||||||
|
// The scene may re-connect later, as its session was not necessarily discarded (see `application:didDiscardSceneSessions` instead).
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
- (void)sceneDidBecomeActive:(UIScene *)scene {
|
||||||
|
// Called when the scene has moved from an inactive state to an active state.
|
||||||
|
// Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive.
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
- (void)sceneWillResignActive:(UIScene *)scene {
|
||||||
|
// Called when the scene will move from an active state to an inactive state.
|
||||||
|
// This may occur due to temporary interruptions (ex. an incoming phone call).
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
- (void)sceneWillEnterForeground:(UIScene *)scene {
|
||||||
|
// Called as the scene transitions from the background to the foreground.
|
||||||
|
// Use this method to undo the changes made on entering the background.
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
- (void)sceneDidEnterBackground:(UIScene *)scene {
|
||||||
|
// Called as the scene transitions from the foreground to the background.
|
||||||
|
// Use this method to save data, release shared resources, and store enough scene-specific state information
|
||||||
|
// to restore the scene back to its current state.
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)scene:(UIScene *)scene openURLContexts:(NSSet<UIOpenURLContext *> *)URLContexts
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
@end
|
|
@ -0,0 +1,8 @@
|
||||||
|
Package: com.opa334.trollinstaller2
|
||||||
|
Name: TrollInstaller2
|
||||||
|
Version: 0.0.1
|
||||||
|
Architecture: iphoneos-arm
|
||||||
|
Description: An awesome application!
|
||||||
|
Maintainer: opa334
|
||||||
|
Author: opa334
|
||||||
|
Section: Utilities
|
|
@ -0,0 +1,35 @@
|
||||||
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0">
|
||||||
|
<dict>
|
||||||
|
<key>platform-application</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.security.no-sandbox</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.persona-mgmt</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.security.exception.files.absolute-path.read-write</key>
|
||||||
|
<array>
|
||||||
|
<string>/</string>
|
||||||
|
</array>
|
||||||
|
<key>com.apple.private.security.container-manager</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.coreservices.canmaplsdatabase</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.lsapplicationworkspace.rebuildappdatabases</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.security.storage.AppBundles</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.MobileContainerManager.allowed</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.MobileInstallationHelperService.InstallDaemonOpsEnabled</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.MobileInstallationHelperService.allowed</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.private.uninstall.deletion</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.backboardd.launchapplications</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.multitasking.termination</key>
|
||||||
|
<true/>
|
||||||
|
</dict>
|
||||||
|
</plist>
|
|
@ -0,0 +1,28 @@
|
||||||
|
#import <Foundation/Foundation.h>
|
||||||
|
#import "TSI2AppDelegate.h"
|
||||||
|
#import "TSI2SceneDelegate.h"
|
||||||
|
#import <objc/runtime.h>
|
||||||
|
|
||||||
|
extern int rootHelperMain(int argc, char *argv[], char *envp[]);
|
||||||
|
|
||||||
|
void classFixup(void)
|
||||||
|
{
|
||||||
|
Class newClass = objc_allocateClassPair([TSI2SceneDelegate class], "WWDC.SceneDelegate", 0);
|
||||||
|
objc_registerClassPair(newClass);
|
||||||
|
}
|
||||||
|
|
||||||
|
int main(int argc, char *argv[], char *envp[]) {
|
||||||
|
@autoreleasepool {
|
||||||
|
if(getuid() == 0)
|
||||||
|
{
|
||||||
|
// I got this idea while taking a shit
|
||||||
|
// Don't judge
|
||||||
|
return rootHelperMain(argc, argv, envp);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
classFixup();
|
||||||
|
return UIApplicationMain(argc, argv, nil, NSStringFromClass(TSI2AppDelegate.class));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -50,7 +50,7 @@ rm -rf ./TrollStore.app
|
||||||
cd -
|
cd -
|
||||||
|
|
||||||
if [[ $1 == "installer" ]]; then
|
if [[ $1 == "installer" ]]; then
|
||||||
# Step five: compile installer
|
# Step five: compile TrollInstaller
|
||||||
xcodebuild -project ../Installer/TrollInstaller/TrollInstaller.xcodeproj -scheme TrollInstaller -destination generic/platform=iOS -archivePath ./out/Installer.xcarchive archive
|
xcodebuild -project ../Installer/TrollInstaller/TrollInstaller.xcodeproj -scheme TrollInstaller -destination generic/platform=iOS -archivePath ./out/Installer.xcarchive archive
|
||||||
|
|
||||||
if [[ -f "./out/Installer.xcarchive/Products/Applications/TrollInstaller.app/embedded.mobileprovision" ]]; then
|
if [[ -f "./out/Installer.xcarchive/Products/Applications/TrollInstaller.app/embedded.mobileprovision" ]]; then
|
||||||
|
@ -65,4 +65,7 @@ if [[ $1 == "installer" ]]; then
|
||||||
cd -
|
cd -
|
||||||
rm -rf ./out/Payload
|
rm -rf ./out/Payload
|
||||||
rm -rf ./out/Installer.xcarchive
|
rm -rf ./out/Installer.xcarchive
|
||||||
|
|
||||||
|
# Step six: compile TrollInstaller 2
|
||||||
|
./build_trollinstaller2.sh
|
||||||
fi
|
fi
|
|
@ -0,0 +1,20 @@
|
||||||
|
cd ../TrollInstaller2
|
||||||
|
make clean
|
||||||
|
make package
|
||||||
|
cd -
|
||||||
|
|
||||||
|
lipo -thin arm64e ../TrollInstaller2/.theos/obj/debug/TrollInstaller2.app/TrollInstaller2 -output ./out/pwn_arm64e
|
||||||
|
ldid -S -M -Kcert.p12 ./out/pwn_arm64e
|
||||||
|
|
||||||
|
mkdir ./out/devpwn
|
||||||
|
unzip target/Developer.ipa -d ./out/devpwn
|
||||||
|
|
||||||
|
./pwnify_compiled ./out/devpwn/Payload/Developer.app/Developer ./out/pwn_arm64e
|
||||||
|
rm ./out/pwn_arm64e
|
||||||
|
|
||||||
|
cd ./out/devpwn
|
||||||
|
zip -mvr devpwn.ipa *
|
||||||
|
cd -
|
||||||
|
|
||||||
|
cp ./out/devpwn/devpwn.ipa ./out/DeveloperInstaller.ipa
|
||||||
|
rm -rf ./out/devpwn
|
|
@ -0,0 +1,23 @@
|
||||||
|
# Installation through TrollInstaller 2
|
||||||
|
|
||||||
|
**Supported devices:** A12-A15, 14.0 - 15.4.1 (15.5b4)
|
||||||
|
|
||||||
|
## Compiling pwned IPA (currently requires a Mac) (Needs THEOS and 14.5 sdk installed)
|
||||||
|
|
||||||
|
1. Get a stock "Apple Developer" IPA (this app: https://apps.apple.com/de/app/apple-developer/id640199958 (sorry german link but you get the idea)), you can do this using Apple Configurator (install it twice to your device and when it gives you the already exists error, copy the IPA from `~/Library/Group\ Containers/<some_uuid>.group.com.apple.configurator/Library/Caches/Assets/TemporaryItems/MobileApps` to somewhere else and then cancel the installation).
|
||||||
|
|
||||||
|
2. Put it into _compile/target/Developer.ipa
|
||||||
|
|
||||||
|
3. Grab pwnify_compiled from Fugu14 repo (https://github.com/LinusHenze/Fugu14/blob/master/tools/pwnify_compiled), sign it using codesign (`codesign -s - <path/to/pwnify_compiled>`) and put it at _compile/pwnify_compiled
|
||||||
|
|
||||||
|
4. Make sure you have Procursus ldid installed and added to your path! (https://github.com/ProcursusTeam/ldid)
|
||||||
|
|
||||||
|
5. cd into _compile and run `./build_trollinstaller2.sh` (`chmod +x ./build_trollinstaller2.sh` if you get a permission error)
|
||||||
|
|
||||||
|
6. Wait a bit, when done, there will be a `DeveloperInstaller.ipa` in _compile/out
|
||||||
|
|
||||||
|
# Using compiled IPA (does not neccessarily require a Mac if you obtained the IPA from non orthodox ways)
|
||||||
|
|
||||||
|
7. You can install that to a device using e.g. ideviceinstaller (other methods may also work, but make sure you don't use a signing cert, you can also use an enterprise plist or something to install it via Safari as shown in Fugu15 demo, something like iFunBox may also work)
|
||||||
|
|
||||||
|
8. After installation, you can use the "Developer" app on your device to install TrollStore
|
Loading…
Reference in New Issue