mirror of
https://github.com/tihmstar/futurerestore.git
synced 2025-01-02 19:25:31 +00:00
removing option to skip checks on 32bit devices
This commit is contained in:
parent
2180c5602e
commit
c119b17543
|
@ -323,14 +323,7 @@ int futurerestore::doRestore(const char *ipsw, bool noerase){
|
||||||
}
|
}
|
||||||
info("Identified device as %s, %s\n", client->device->hardware_model, client->device->product_type);
|
info("Identified device as %s, %s\n", client->device->hardware_model, client->device->product_type);
|
||||||
|
|
||||||
if (skipAPTicketChecks && _is32bit) {
|
if (!(client->tss = nonceMatchesApTickets()))
|
||||||
info("[WARNING] skipping APNonce check. If devicenonce doesn't match ticketnonce, the restore will fail!\n");
|
|
||||||
if (_im4ms.size() != 1)
|
|
||||||
reterror(-72, "ERROR: user selected to skip APNonce checks but specified more than one APTicket.\n"\
|
|
||||||
"Without inspecting APTickets it is not possible to choose the correct one, therfore this feature is disabled.\n"
|
|
||||||
"Either re-enable APTicket checks, or only pass one APTicket\n");
|
|
||||||
client->tss = _aptickets[0];
|
|
||||||
}else if (!(client->tss = nonceMatchesApTickets()))
|
|
||||||
reterror(-20, "Devicenonce does not match APTicket nonce\n");
|
reterror(-20, "Devicenonce does not match APTicket nonce\n");
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -51,7 +51,6 @@ class futurerestore {
|
||||||
const char *_basebandPath;
|
const char *_basebandPath;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
bool skipAPTicketChecks = false; //ignored on 64bit devices
|
|
||||||
futurerestore();
|
futurerestore();
|
||||||
futurerestore(bool is32bit);
|
futurerestore(bool is32bit);
|
||||||
bool init();
|
bool init();
|
||||||
|
|
|
@ -33,7 +33,6 @@ static struct option longopts[] = {
|
||||||
{ "latest-baseband", no_argument, NULL, '1' },
|
{ "latest-baseband", no_argument, NULL, '1' },
|
||||||
{ "no-baseband", no_argument, NULL, '2' },
|
{ "no-baseband", no_argument, NULL, '2' },
|
||||||
{ "is-32bit", no_argument, NULL, '3' },
|
{ "is-32bit", no_argument, NULL, '3' },
|
||||||
{ "skip-ticket-checks", no_argument, NULL, '4' }, //use this for 32bit devices only, this flag is ignored on 64bit devices
|
|
||||||
{ NULL, 0, NULL, 0 }
|
{ NULL, 0, NULL, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -43,7 +42,6 @@ static struct option longopts[] = {
|
||||||
#define FLAG_LATEST_BASEBAND 1 << 3
|
#define FLAG_LATEST_BASEBAND 1 << 3
|
||||||
#define FLAG_NO_BASEBAND 1 << 4
|
#define FLAG_NO_BASEBAND 1 << 4
|
||||||
#define FLAG_IS_32_BIT 1 << 5
|
#define FLAG_IS_32_BIT 1 << 5
|
||||||
#define FLAG_SKIP_TICKET_CHECKS 1 << 6
|
|
||||||
|
|
||||||
void cmd_help(){
|
void cmd_help(){
|
||||||
printf("Usage: futurerestore [OPTIONS] IPSW\n");
|
printf("Usage: futurerestore [OPTIONS] IPSW\n");
|
||||||
|
@ -130,9 +128,6 @@ int main(int argc, const char * argv[]) {
|
||||||
flags |= FLAG_IS_32_BIT;
|
flags |= FLAG_IS_32_BIT;
|
||||||
printf("[INFO] setting 32bit device flag\n");
|
printf("[INFO] setting 32bit device flag\n");
|
||||||
break;
|
break;
|
||||||
case '4': // long option: "skip-apnonce-match-check";
|
|
||||||
flags |= FLAG_SKIP_TICKET_CHECKS;
|
|
||||||
break;
|
|
||||||
case 'd': // long option: "debug"; can be called as short option
|
case 'd': // long option: "debug"; can be called as short option
|
||||||
idevicerestore_debug = 1;
|
idevicerestore_debug = 1;
|
||||||
break;
|
break;
|
||||||
|
@ -159,7 +154,6 @@ int main(int argc, const char * argv[]) {
|
||||||
}
|
}
|
||||||
|
|
||||||
futurerestore client(flags & FLAG_IS_32_BIT);
|
futurerestore client(flags & FLAG_IS_32_BIT);
|
||||||
client.skipAPTicketChecks = (flags & FLAG_SKIP_TICKET_CHECKS);
|
|
||||||
if (!client.init()) reterror(-3,"can't init, no device found\n");
|
if (!client.init()) reterror(-3,"can't init, no device found\n");
|
||||||
|
|
||||||
printf("futurerestore init done\n");
|
printf("futurerestore init done\n");
|
||||||
|
|
Loading…
Reference in a new issue