File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -10535,17 +10535,29 @@ restore_customipsw() {
1053510535}
1053610536
1053710537device_dfuipsw_confirm () {
10538- print " * You are about to restore with a DFU IPSW."
10539- print " * This will force the device to enter DFU mode, which is useful for devices with broken buttons."
10540- print " * All device data will be wiped! Only proceed if you have backed up your data."
10541- print " * Expect the restore to fail and the device to be stuck in DFU mode."
10538+ local msg1=" restore"
10539+ local msg2=" This"
10540+ if [[ $1 == " ipsw" ]]; then
10541+ msg1=" create"
10542+ msg2+=" IPSW"
10543+ fi
10544+ print " * You are about to $msg1 a DFU IPSW."
10545+ print " * $msg2 will force the device to enter DFU mode, which is useful for devices with broken buttons."
10546+ if [[ $1 != " ipsw" ]]; then
10547+ print " * All device data will be wiped! Only proceed if you have backed up your data."
10548+ print " * Expect the restore to fail and the device to be stuck in DFU mode."
10549+ fi
1054210550 select_yesno
1054310551 if [[ $? != 1 ]]; then
1054410552 return
1054510553 fi
1054610554 mode=" device_dfuipsw$1 "
1054710555}
1054810556
10557+ device_dfuipswipsw () {
10558+ device_dfuipsw ipsw
10559+ }
10560+
1054910561device_dfuipsw () {
1055010562 # the only change done to the "dfu ipsw" is just applelogo copied and renamed to llb
1055110563 # replacing llb with an invalid img3/im4p to make the restore fail, the device will then fallback to true dfu mode
@@ -11502,7 +11514,6 @@ main() {
1150211514 print " - If so, try to clear the device's NVRAM: go to Useful Utilities -> Clear NVRAM"
1150311515 fi
1150411516 ;;
11505- " dfuipswipsw" ) device_dfuipsw ipsw;;
1150611517 " customipsw" ) restore_customipsw;;
1150711518 " getversion" ) device_enter_ramdisk getversion;;
1150811519 " shutdown" ) $idevicediagnostics shutdown;;
You can’t perform that action at this time.
0 commit comments