mirror of
https://github.com/tihmstar/futurerestore.git
synced 2025-07-02 15:08:14 +00:00
iOS 16 support, update submodules
This commit is contained in:
parent
cb39cc2dae
commit
c15e30b290
2
.gitmodules
vendored
2
.gitmodules
vendored
|
@ -5,4 +5,4 @@
|
||||||
[submodule "tsschecker"]
|
[submodule "tsschecker"]
|
||||||
path = external/tsschecker
|
path = external/tsschecker
|
||||||
url = https://github.com/1Conan/tsschecker.git
|
url = https://github.com/1Conan/tsschecker.git
|
||||||
branch = master
|
branch = iOS16
|
||||||
|
|
2
external/idevicerestore
vendored
2
external/idevicerestore
vendored
|
@ -1 +1 @@
|
||||||
Subproject commit 75092808043a67527ad94c263851324d456fe507
|
Subproject commit e738336c231d7a8c3d20d5967711b846a9119a7d
|
2
external/tsschecker
vendored
2
external/tsschecker
vendored
|
@ -1 +1 @@
|
||||||
Subproject commit a600e296a3f2ba764e7ab1f164d10e4e7b82e127
|
Subproject commit 9a046508ffb7cbd62d3ff50042944237389c51b4
|
|
@ -163,9 +163,7 @@ bool futurerestore::init() {
|
||||||
|
|
||||||
uint64_t futurerestore::getDeviceEcid() {
|
uint64_t futurerestore::getDeviceEcid() {
|
||||||
retassure(_didInit, "did not init\n");
|
retassure(_didInit, "did not init\n");
|
||||||
uint64_t ecid;
|
return _client->ecid;
|
||||||
get_ecid(_client, &ecid);
|
|
||||||
return ecid;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int futurerestore::getDeviceMode(bool reRequest) {
|
int futurerestore::getDeviceMode(bool reRequest) {
|
||||||
|
@ -1352,7 +1350,6 @@ void futurerestore::doRestore(const char *ipsw) {
|
||||||
//do magic
|
//do magic
|
||||||
if (_client->image4supported) get_sep_nonce(client, &client->sepnonce, &client->sepnonce_size);
|
if (_client->image4supported) get_sep_nonce(client, &client->sepnonce, &client->sepnonce_size);
|
||||||
get_ap_nonce(client, &client->nonce, &client->nonce_size);
|
get_ap_nonce(client, &client->nonce, &client->nonce_size);
|
||||||
get_ecid(client, &client->ecid);
|
|
||||||
|
|
||||||
if (client->mode == MODE_RECOVERY) {
|
if (client->mode == MODE_RECOVERY) {
|
||||||
retassure(client->srnm, "ERROR: could not retrieve device serial number. Can't continue.\n");
|
retassure(client->srnm, "ERROR: could not retrieve device serial number. Can't continue.\n");
|
||||||
|
@ -1391,7 +1388,7 @@ void futurerestore::doRestore(const char *ipsw) {
|
||||||
|
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
// Borrowed from apple killall.c
|
// Borrowed from apple killall.c
|
||||||
int futurerestore::findProc(const char *procName) {
|
int futurerestore::findProc(const char *procName, bool load) {
|
||||||
struct kinfo_proc *procs = nullptr, *procs2 = nullptr;
|
struct kinfo_proc *procs = nullptr, *procs2 = nullptr;
|
||||||
int mib[4];
|
int mib[4];
|
||||||
size_t mibLen, size = 0;
|
size_t mibLen, size = 0;
|
||||||
|
@ -1480,7 +1477,9 @@ int futurerestore::findProc(const char *procName) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (strcmp(cmd, procName) == 0) {
|
if (strcmp(cmd, procName) == 0) {
|
||||||
info("daemonManager: findProc: found %s!\n", procName);
|
if(!load) {
|
||||||
|
info("daemonManager: findProc: found %s!\n", procName);
|
||||||
|
}
|
||||||
return pid;
|
return pid;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1494,12 +1493,12 @@ void futurerestore::daemonManager(bool load) {
|
||||||
int pid = 0;
|
int pid = 0;
|
||||||
const char *procList[] = { "MobileDeviceUpdater", "AMPDevicesAgent", "AMPDeviceDiscoveryAgent", 0};
|
const char *procList[] = { "MobileDeviceUpdater", "AMPDevicesAgent", "AMPDeviceDiscoveryAgent", 0};
|
||||||
for(int i = 0; i < 3; i++) {
|
for(int i = 0; i < 3; i++) {
|
||||||
pid = findProc(procList[i]);
|
pid = findProc(procList[i], load);
|
||||||
if (pid > 1) {
|
if (pid > 1) {
|
||||||
info("daemonManager: killing %s.\n", procList[i]);
|
|
||||||
if (load) {
|
if (load) {
|
||||||
int ret = kill(pid, SIGCONT);
|
int ret = kill(pid, SIGCONT);
|
||||||
} else {
|
} else {
|
||||||
|
info("daemonManager: killing %s.\n", procList[i]);
|
||||||
int ret = kill(pid, SIGSTOP);
|
int ret = kill(pid, SIGSTOP);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -159,7 +159,7 @@ public:
|
||||||
void doRestore(const char *ipsw);
|
void doRestore(const char *ipsw);
|
||||||
|
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
static int findProc(const char *procName);
|
static int findProc(const char *procName, bool load);
|
||||||
void daemonManager(bool load);
|
void daemonManager(bool load);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue