summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2012-09-26 13:05:26 +0200
committerGravatar Martin Szulecki2012-11-07 22:25:48 +0100
commitac89f2f629ded140511fc6239e63d9d73eee6328 (patch)
tree9a8e2daf8fc2ed13f931e2d618a7051eb303f8df /src
parent4dbd4c210e6a78216fdd0339c5a5e1850c1e3e58 (diff)
downloadidevicerestore-ac89f2f629ded140511fc6239e63d9d73eee6328.tar.gz
idevicerestore-ac89f2f629ded140511fc6239e63d9d73eee6328.tar.bz2
idevicerestore: Make first nonce request not mandatory to support "old" iOS builds
Devices running iOS 4.x and older do not use or supply a nonce before an actual iBEC of the target firmware version is loaded which does so. This caused older devices to fail to restore.
Diffstat (limited to 'src')
-rw-r--r--src/idevicerestore.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/idevicerestore.c b/src/idevicerestore.c
index d22b36a..c60da0e 100644
--- a/src/idevicerestore.c
+++ b/src/idevicerestore.c
@@ -541,8 +541,8 @@ int idevicerestore_start(struct idevicerestore_client_t* client)
int nonce_size = 0;
int nonce_changed = 0;
if (get_nonce(client, &nonce, &nonce_size) < 0) {
- error("ERROR: Unable to get nonce from device!\n");
- return -2;
+ /* the first nonce request with older firmware releases can fail and it's OK */
+ info("NOTE: Unable to get nonce from device\n");
}
if (!client->nonce || (nonce_size != client->nonce_size) || (memcmp(nonce, client->nonce, nonce_size) != 0)) {