summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Nikias Bassen2022-09-25 11:42:35 +0200
committerGravatar Nikias Bassen2022-09-25 11:42:35 +0200
commit88aeb4ce1313a9e89209c08efa62fb6b7eb428c4 (patch)
tree6713bcc9501ffab1baa6a6eb660079997ee76bf4
parent96f68e6d8826a696747fb2a403a8e39297fff1b9 (diff)
downloadidevicerestore-88aeb4ce1313a9e89209c08efa62fb6b7eb428c4.tar.gz
idevicerestore-88aeb4ce1313a9e89209c08efa62fb6b7eb428c4.tar.bz2
tss: Make sure vinyl tags include eUICC,Gold and eUICC,Main digests
... as well as eUICC,ApProductionMode which was missing before.
-rw-r--r--src/tss.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/tss.c b/src/tss.c
index d8f9789..f162a82 100644
--- a/src/tss.c
+++ b/src/tss.c
@@ -1075,10 +1075,29 @@ int tss_request_add_vinyl_tags(plist_t request, plist_t parameters, plist_t over
plist_dict_set_item(request, "@BBTicket", plist_new_bool(1));
plist_dict_set_item(request, "@eUICC,Ticket", plist_new_bool(1));
+ _plist_dict_copy_bool(request, parameters, "eUICC,ApProductionMode", "ApProductionMode");
_plist_dict_copy_uint(request, parameters, "eUICC,ChipID", NULL);
_plist_dict_copy_data(request, parameters, "eUICC,EID", NULL);
_plist_dict_copy_data(request, parameters, "eUICC,RootKeyIdentifier", NULL);
+ if (!plist_dict_get_item(request, "eUICC,Gold")) {
+ plist_t n = plist_access_path(parameters, 2, "Manifest", "eUICC,Gold");
+ if (n) {
+ plist_t p = plist_new_dict();
+ _plist_dict_copy_data(p, n, "Digest", NULL);
+ plist_dict_set_item(request, "eUICC,Gold", p);
+ }
+ }
+
+ if (!plist_dict_get_item(request, "eUICC,Main")) {
+ plist_t n = plist_access_path(parameters, 2, "Manifest", "eUICC,Main");
+ if (n) {
+ plist_t p = plist_new_dict();
+ _plist_dict_copy_data(p, n, "Digest", NULL);
+ plist_dict_set_item(request, "eUICC,Main", p);
+ }
+ }
+
/* set Nonce for eUICC,Gold component */
node = plist_dict_get_item(parameters, "EUICCGoldNonce");
if (node) {