mirror of
https://github.com/LukeZGD/Legacy-iOS-Kit.git
synced 2024-12-24 15:21:49 +01:00
Update limd, idr, idrr, and fixes
This commit is contained in:
parent
abc05511ff
commit
b84495469e
@ -92,7 +92,9 @@
|
|||||||
- For iPad 4, only 7.0.x blobs can be used
|
- For iPad 4, only 7.0.x blobs can be used
|
||||||
- Restoring to other unsigned versions without blobs is supported on the following devices and target versions:
|
- Restoring to other unsigned versions without blobs is supported on the following devices and target versions:
|
||||||
- iPhone 3GS - iOS 3.1.3, 4.1, 4.3.3, 5.0.1, 5.1.1
|
- iPhone 3GS - iOS 3.1.3, 4.1, 4.3.3, 5.0.1, 5.1.1
|
||||||
- iPod touch 2 - iOS 3.1.3, 4.1
|
- iPod touch 2 - iOS 2.1.1 to 3.0, 3.1.3, 4.1
|
||||||
|
- iPhone 2G, 3G, iPod touch 1 - all versions
|
||||||
|
- iOS 1 doesn't seem to work and may require usage of [ZiPhone](https://github.com/Zibri/ZiPhone), [more info here](https://nitter.net/tihmstar/status/1734620913071542435)
|
||||||
|
|
||||||
## Supported OS versions/distros
|
## Supported OS versions/distros
|
||||||
|
|
||||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
bin/macos/iproxy
BIN
bin/macos/iproxy
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
111
restore.sh
111
restore.sh
@ -575,8 +575,9 @@ device_get_info() {
|
|||||||
|
|
||||||
log "Getting device info..."
|
log "Getting device info..."
|
||||||
if [[ $device_mode == "WTF" ]]; then
|
if [[ $device_mode == "WTF" ]]; then
|
||||||
device_s5l8900xall
|
device_proc=1
|
||||||
device_wtfexit=1
|
device_wtfexit=1
|
||||||
|
device_s5l8900xall
|
||||||
fi
|
fi
|
||||||
case $device_mode in
|
case $device_mode in
|
||||||
"DFU" | "Recovery" )
|
"DFU" | "Recovery" )
|
||||||
@ -863,6 +864,7 @@ device_find_mode() {
|
|||||||
local i=0
|
local i=0
|
||||||
local device_in
|
local device_in
|
||||||
local mode="$1"
|
local mode="$1"
|
||||||
|
local wtfreal
|
||||||
|
|
||||||
if [[ $mode == "Restore" ]]; then
|
if [[ $mode == "Restore" ]]; then
|
||||||
:
|
:
|
||||||
@ -873,6 +875,9 @@ device_find_mode() {
|
|||||||
if [[ $mode == "DFUreal" ]]; then
|
if [[ $mode == "DFUreal" ]]; then
|
||||||
mode="DFU"
|
mode="DFU"
|
||||||
usb=1227
|
usb=1227
|
||||||
|
elif [[ $mode == "WTFreal" ]]; then
|
||||||
|
mode="WTF"
|
||||||
|
wtfreal=1
|
||||||
elif [[ $mode == "DFU" ]]; then
|
elif [[ $mode == "DFU" ]]; then
|
||||||
mode="WTF"
|
mode="WTF"
|
||||||
fi
|
fi
|
||||||
@ -913,7 +918,7 @@ device_find_mode() {
|
|||||||
error "Failed to find device in $mode mode (Timed out). Please run the script again."
|
error "Failed to find device in $mode mode (Timed out). Please run the script again."
|
||||||
fi
|
fi
|
||||||
return 1
|
return 1
|
||||||
elif [[ $mode == "WTF" ]]; then
|
elif [[ $mode == "WTF" && $wtfreal != 1 ]]; then
|
||||||
device_s5l8900xall
|
device_s5l8900xall
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
@ -1012,7 +1017,11 @@ device_dfuhelper() {
|
|||||||
sleep 1
|
sleep 1
|
||||||
done
|
done
|
||||||
echo
|
echo
|
||||||
device_find_mode DFU
|
if [[ $2 == "WTFreal" ]]; then
|
||||||
|
device_find_mode WTFreal
|
||||||
|
else
|
||||||
|
device_find_mode DFU
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
device_enter_mode() {
|
device_enter_mode() {
|
||||||
@ -1020,6 +1029,22 @@ device_enter_mode() {
|
|||||||
# attempt to enter given mode, and device_find_mode function will then set device_mode variable
|
# attempt to enter given mode, and device_find_mode function will then set device_mode variable
|
||||||
local opt
|
local opt
|
||||||
case $1 in
|
case $1 in
|
||||||
|
"WTFreal" )
|
||||||
|
if [[ $device_mode == "WTF" ]]; then
|
||||||
|
return
|
||||||
|
elif [[ $device_mode == "Normal" ]]; then
|
||||||
|
device_enter_mode Recovery
|
||||||
|
fi
|
||||||
|
if [[ $device_mode == "Recovery" ]]; then
|
||||||
|
device_dfuhelper norec WTFreal
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
log "Found an S5L8900 device in $device_mode mode. Your device needs to be in WTF mode to continue."
|
||||||
|
print "* iOS 1 restores require WTF mode."
|
||||||
|
print "* Force restart your device and place it in normal or recovery mode, then re-enter WTF mode."
|
||||||
|
device_find_mode WTFreal 100
|
||||||
|
;;
|
||||||
|
|
||||||
"Recovery" )
|
"Recovery" )
|
||||||
if [[ $device_mode == "Normal" ]]; then
|
if [[ $device_mode == "Normal" ]]; then
|
||||||
print "* The device needs to be in recovery/DFU mode before proceeding."
|
print "* The device needs to be in recovery/DFU mode before proceeding."
|
||||||
@ -1176,6 +1201,10 @@ device_enter_mode() {
|
|||||||
local irec_pwned
|
local irec_pwned
|
||||||
local tool_pwned
|
local tool_pwned
|
||||||
|
|
||||||
|
if [[ $device_proc == 1 ]]; then
|
||||||
|
device_enter_mode DFU
|
||||||
|
return
|
||||||
|
fi
|
||||||
if [[ $device_mode == "DFU" ]]; then
|
if [[ $device_mode == "DFU" ]]; then
|
||||||
irec_pwned=$($irecovery -q | grep -c "PWND")
|
irec_pwned=$($irecovery -q | grep -c "PWND")
|
||||||
fi
|
fi
|
||||||
@ -3050,7 +3079,12 @@ ipsw_prepare_custom() {
|
|||||||
mv options.plist options.$device_model.plist
|
mv options.plist options.$device_model.plist
|
||||||
fi
|
fi
|
||||||
if [[ $device_target_vers == "3"* ]]; then
|
if [[ $device_target_vers == "3"* ]]; then
|
||||||
RootSize=520
|
case $device_type in
|
||||||
|
iPhone1,[12] ) RootSize=420;;
|
||||||
|
iPhone2,1 ) RootSize=530;;
|
||||||
|
iPod1,1 ) RootSize=413;;
|
||||||
|
iPod2,1 ) RootSize=450;;
|
||||||
|
esac
|
||||||
elif [[ $platform == "macos" ]]; then
|
elif [[ $platform == "macos" ]]; then
|
||||||
plutil -extract 'SystemPartitionSize' xml1 options.$device_model.plist -o size
|
plutil -extract 'SystemPartitionSize' xml1 options.$device_model.plist -o size
|
||||||
RootSize=$(cat size | sed -ne '/<integer>/,/<\/integer>/p' | sed -e "s/<integer>//" | sed "s/<\/integer>//" | sed '2d')
|
RootSize=$(cat size | sed -ne '/<integer>/,/<\/integer>/p' | sed -e "s/<integer>//" | sed "s/<\/integer>//" | sed '2d')
|
||||||
@ -3280,7 +3314,7 @@ restore_idevicerestore() {
|
|||||||
echo
|
echo
|
||||||
log "Restoring done! Read the message below if any error has occurred:"
|
log "Restoring done! Read the message below if any error has occurred:"
|
||||||
case $device_target_vers in
|
case $device_target_vers in
|
||||||
3* | 4* ) print "* For device activation, go to: Other Utilities -> Attempt Activation";;
|
1* | 2* | 3* | 4* ) print "* For device activation, go to: Other Utilities -> Attempt Activation";;
|
||||||
esac
|
esac
|
||||||
if [[ $opt != 0 ]]; then
|
if [[ $opt != 0 ]]; then
|
||||||
print "* If the restore failed on updating baseband:"
|
print "* If the restore failed on updating baseband:"
|
||||||
@ -3415,25 +3449,24 @@ restore_latest() {
|
|||||||
device_enter_mode Recovery
|
device_enter_mode Recovery
|
||||||
ipsw_extract
|
ipsw_extract
|
||||||
fi
|
fi
|
||||||
|
if [[ $debug_mode == 1 ]]; then
|
||||||
|
ExtraArgs+="d"
|
||||||
|
fi
|
||||||
log "Running idevicerestore with command: $idevicerestore2 $ExtraArgs \"$ipsw_path.ipsw\""
|
log "Running idevicerestore with command: $idevicerestore2 $ExtraArgs \"$ipsw_path.ipsw\""
|
||||||
$idevicerestore2 $ExtraArgs "$ipsw_path.ipsw"
|
$idevicerestore2 $ExtraArgs "$ipsw_path.ipsw"
|
||||||
opt=$?
|
opt=$?
|
||||||
if [[ $1 == "custom" ]]; then
|
if [[ $1 == "custom" ]]; then
|
||||||
log "Restoring done! Read the message below if any error has occurred:"
|
log "Restoring done! Read the message below if any error has occurred:"
|
||||||
if [[ $opt != 0 ]]; then
|
|
||||||
print "* If you are getting the error \"unable to find AppleNANDFTL\":"
|
|
||||||
print " -> This means that your device is not compatible with $device_target_vers"
|
|
||||||
fi
|
|
||||||
print "* Please read the \"Troubleshooting\" wiki page in GitHub before opening any issue!"
|
print "* Please read the \"Troubleshooting\" wiki page in GitHub before opening any issue!"
|
||||||
print "* Your problem may have already been addressed within the wiki page."
|
print "* Your problem may have already been addressed within the wiki page."
|
||||||
print "* If opening an issue in GitHub, please provide a FULL log/output. Otherwise, your issue may be dismissed."
|
print "* If opening an issue in GitHub, please provide a FULL log/output. Otherwise, your issue may be dismissed."
|
||||||
fi
|
fi
|
||||||
case $device_target_vers in
|
case $device_target_vers in
|
||||||
3* | 4* ) print "* For device activation, go to: Other Utilities -> Attempt Activation";;
|
1* | 2* | 3* | 4* ) print "* For device activation, go to: Other Utilities -> Attempt Activation";;
|
||||||
esac
|
esac
|
||||||
if [[ $ipsw_jailbreak == 1 ]]; then
|
if [[ $ipsw_jailbreak == 1 ]]; then
|
||||||
case $device_target_vers in
|
case $device_target_vers in
|
||||||
4* | 3* ) warn "Do not uninstall Cydia Substrate and Substrate Safe Mode in Cydia!";;
|
3* | 4* ) warn "Do not uninstall Cydia Substrate and Substrate Safe Mode in Cydia!";;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
@ -3491,11 +3524,10 @@ restore_prepare() {
|
|||||||
case $device_proc in
|
case $device_proc in
|
||||||
1 )
|
1 )
|
||||||
device_enter_mode DFU
|
device_enter_mode DFU
|
||||||
if [[ $ipsw_jailbreak == 1 ]]; then
|
if [[ $ipsw_jailbreak != 1 ]]; then
|
||||||
restore_latest custom
|
ipsw_custom="$ipsw_path"
|
||||||
else
|
|
||||||
restore_latest
|
|
||||||
fi
|
fi
|
||||||
|
restore_latest custom
|
||||||
;;
|
;;
|
||||||
|
|
||||||
4 )
|
4 )
|
||||||
@ -4481,16 +4513,16 @@ menu_restore() {
|
|||||||
iPhone1,2 | iPod2,1 )
|
iPhone1,2 | iPod2,1 )
|
||||||
menu_items+=("4.1" "3.1.3");;
|
menu_items+=("4.1" "3.1.3");;
|
||||||
esac
|
esac
|
||||||
|
case $device_type in
|
||||||
|
iPhone3,[13] | iPad1,1 | iPod3,1 )
|
||||||
|
menu_items+=("powdersn0w (any iOS)");;
|
||||||
|
esac
|
||||||
if (( device_proc < 7 )); then
|
if (( device_proc < 7 )); then
|
||||||
menu_items+=("Latest iOS ($device_latest_vers)")
|
menu_items+=("Latest iOS ($device_latest_vers)")
|
||||||
fi
|
fi
|
||||||
case $device_type in
|
case $device_type in
|
||||||
iPhone4,1 | iPhone5,[1234] | iPad2,4 | iPad3,[456] | iPod5,1 )
|
iPhone4,1 | iPhone5,[1234] | iPad2,4 | iPad3,[456] | iPod5,1 )
|
||||||
menu_items+=("Other (powdersn0w 7.x blobs)");;
|
menu_items+=("Other (powdersn0w 7.x blobs)");;
|
||||||
iPhone3,[13] | iPad1,1 | iPod3,1 )
|
|
||||||
menu_items+=("powdersn0w (any iOS)");;
|
|
||||||
esac
|
|
||||||
case $device_type in
|
|
||||||
iPhone1,[12] | iPhone2,1 | iPod[12],1 )
|
iPhone1,[12] | iPhone2,1 | iPod[12],1 )
|
||||||
if [[ -z $1 ]]; then
|
if [[ -z $1 ]]; then
|
||||||
menu_items+=("Other (Custom IPSW)")
|
menu_items+=("Other (Custom IPSW)")
|
||||||
@ -4505,7 +4537,8 @@ menu_restore() {
|
|||||||
menu_items+=("Other (Tethered)")
|
menu_items+=("Other (Tethered)")
|
||||||
fi
|
fi
|
||||||
case $device_type in
|
case $device_type in
|
||||||
iPhone3,2 | iPod4,1 ) menu_items+=("Other (Tethered)");;
|
iPhone3,2 | iPod4,1 )
|
||||||
|
menu_items+=("Other (Tethered)");;
|
||||||
esac
|
esac
|
||||||
if (( device_proc < 7 )); then
|
if (( device_proc < 7 )); then
|
||||||
menu_items+=("DFU IPSW")
|
menu_items+=("DFU IPSW")
|
||||||
@ -4518,6 +4551,17 @@ menu_restore() {
|
|||||||
else
|
else
|
||||||
print " > Main Menu > Restore/Downgrade"
|
print " > Main Menu > Restore/Downgrade"
|
||||||
fi
|
fi
|
||||||
|
if [[ -z $1 ]]; then
|
||||||
|
if [[ $device_proc == 1 ]]; then
|
||||||
|
print "* Select \"Other (Custom IPSW)\" to restore to any iOS version"
|
||||||
|
print "* iOS 1 may require the usage of ZiPhone: https://nitter.net/tihmstar/status/1734620913071542435"
|
||||||
|
echo
|
||||||
|
fi
|
||||||
|
if [[ $device_type == "iPod2,1" ]]; then
|
||||||
|
print "* Select \"Other (Custom IPSW)\" to restore to any iOS version (2.1.1 to 3.0)"
|
||||||
|
echo
|
||||||
|
fi
|
||||||
|
fi
|
||||||
input "Select an option:"
|
input "Select an option:"
|
||||||
select opt in "${menu_items[@]}"; do
|
select opt in "${menu_items[@]}"; do
|
||||||
selected="$opt"
|
selected="$opt"
|
||||||
@ -5128,18 +5172,16 @@ device_jailbreakrd() {
|
|||||||
print "* Supported versions are: 3.1.3 to 9.3.4 (excluding 9.0.x)"
|
print "* Supported versions are: 3.1.3 to 9.3.4 (excluding 9.0.x)"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
if [[ $device_proc == 5 ]]; then
|
case $device_vers in
|
||||||
case $device_vers in
|
8.2 | 8.1* | 8.0* )
|
||||||
8.2 | 8.1* | 8.0* )
|
if [[ $device_proc == 5 ]]; then
|
||||||
warn "This version ($device_vers) is broken for daibutsu A5(X)."
|
warn "This version ($device_vers) is broken for daibutsu A5(X)."
|
||||||
print "* Supported iOS 8 versions for A5(X) are 8.3 to 8.4.1 only for now."
|
print "* Supported iOS 8 versions for A5(X) are 8.3 to 8.4.1 only for now."
|
||||||
print "* For this version, use Home Depot patched with ohd."
|
print "* For this version, use Home Depot patched with ohd."
|
||||||
print "* https://ios.cfw.guide/installing-homedepot/"
|
print "* https://ios.cfw.guide/installing-homedepot/"
|
||||||
return
|
return
|
||||||
;;
|
fi
|
||||||
esac
|
;;
|
||||||
fi
|
|
||||||
case $device_vers in
|
|
||||||
9.0* )
|
9.0* )
|
||||||
print "* For this version, use Pangu9, or download openpwnage and sideload it to your device."
|
print "* For this version, use Pangu9, or download openpwnage and sideload it to your device."
|
||||||
print "* https://ios.cfw.guide/installing-pangu9/"
|
print "* https://ios.cfw.guide/installing-pangu9/"
|
||||||
@ -5261,14 +5303,13 @@ restore_customipsw() {
|
|||||||
if [[ -z $ipsw_path ]]; then
|
if [[ -z $ipsw_path ]]; then
|
||||||
error "No IPSW selected, cannot continue."
|
error "No IPSW selected, cannot continue."
|
||||||
fi
|
fi
|
||||||
device_enter_mode pwnDFU
|
if [[ $device_target_vers == "1"* ]]; then
|
||||||
ipsw_extract
|
device_enter_mode WTFreal
|
||||||
log "Running idevicerestore with command: $idevicerestore -ce \"$ipsw_path.ipsw\""
|
else
|
||||||
$idevicerestore -ce "$ipsw_path.ipsw"
|
device_enter_mode pwnDFU
|
||||||
log "Restoring done!"
|
fi
|
||||||
case $device_target_vers in
|
ipsw_custom="$ipsw_path"
|
||||||
3* | 4* ) print "* For device activation, go to: Other Utilities -> Attempt Activation";;
|
restore_latest custom
|
||||||
esac
|
|
||||||
}
|
}
|
||||||
|
|
||||||
restore_dfuipsw() {
|
restore_dfuipsw() {
|
||||||
|
Loading…
Reference in New Issue
Block a user