summaryrefslogtreecommitdiffstats
path: root/src/idevicerestore.c
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2013-11-18 18:17:31 +0100
committerGravatar Martin Szulecki2013-11-18 18:17:31 +0100
commit8407a14a1884c386cf5277dec53ecb067c34fac2 (patch)
tree288b2ffe52f51b878335b2aac3d591329a3abedc /src/idevicerestore.c
parente12bd5fc5c9b59e01288dbf0e8e1edc32aa03bf0 (diff)
downloadidevicerestore-8407a14a1884c386cf5277dec53ecb067c34fac2.tar.gz
idevicerestore-8407a14a1884c386cf5277dec53ecb067c34fac2.tar.bz2
normal: Split normal_get_nonce() into ApNonce and SEPNonce getters
Diffstat (limited to 'src/idevicerestore.c')
-rw-r--r--src/idevicerestore.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/idevicerestore.c b/src/idevicerestore.c
index 9717676..0cd5a14 100644
--- a/src/idevicerestore.c
+++ b/src/idevicerestore.c
@@ -562,7 +562,7 @@ int idevicerestore_start(struct idevicerestore_client_t* client)
unsigned char* nonce = NULL;
int nonce_size = 0;
int nonce_changed = 0;
- if (get_nonce(client, &nonce, &nonce_size) < 0) {
+ if (get_ap_nonce(client, &nonce, &nonce_size) < 0) {
/* the first nonce request with older firmware releases can fail and it's OK */
info("NOTE: Unable to get nonce from device\n");
}
@@ -811,7 +811,7 @@ int idevicerestore_start(struct idevicerestore_client_t* client)
unsigned char* nonce = NULL;
int nonce_size = 0;
int nonce_changed = 0;
- if (get_nonce(client, &nonce, &nonce_size) < 0) {
+ if (get_ap_nonce(client, &nonce, &nonce_size) < 0) {
error("ERROR: Unable to get nonce from device!\n");
recovery_send_reset(client);
if (delete_fs && filesystem)
@@ -1257,16 +1257,16 @@ int get_ecid(struct idevicerestore_client_t* client, uint64_t* ecid) {
return 0;
}
-int get_nonce(struct idevicerestore_client_t* client, unsigned char** nonce, int* nonce_size) {
+int get_ap_nonce(struct idevicerestore_client_t* client, unsigned char** nonce, int* nonce_size) {
*nonce = NULL;
*nonce_size = 0;
- info("Getting nonce ");
+ info("Getting ApNonce ");
switch (client->mode->index) {
case MODE_NORMAL:
info("in normal mode... ");
- if (normal_get_nonce(client, nonce, nonce_size) < 0) {
+ if (normal_get_ap_nonce(client, nonce, nonce_size) < 0) {
info("failed\n");
return -1;
}