diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 84a2262..bdc34de 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -41,6 +41,14 @@ jobs: - name: Move linux binaries and other files run: | rm -r ./bin/linux/x86_64 ./resources/lib/* + cp -R ./exclude/bin/linux/arm ./bin/linux + + - name: Zip linux arm files + run: zip -r ${{ github.event.repository.name }}_linux_arm_${{ env.DATE }}-${{ env.SHA_SHORT }}.zip bin/ LICENSE resources/ restore.sh README.md + + - name: Move linux arm binaries and other files + run: | + rm -r ./bin/linux cp -R ./exclude/bin/windows ./bin - name: Zip win files @@ -64,5 +72,6 @@ jobs: files: | ${{ github.event.repository.name }}_complete_${{ env.DATE }}-${{ env.SHA_SHORT }}.zip ${{ github.event.repository.name }}_macos_${{ env.DATE }}-${{ env.SHA_SHORT }}.zip + ${{ github.event.repository.name }}_linux_arm_${{ env.DATE }}-${{ env.SHA_SHORT }}.zip ${{ github.event.repository.name }}_linux_x86_64_${{ env.DATE }}-${{ env.SHA_SHORT }}.zip ${{ github.event.repository.name }}_windows_${{ env.DATE }}-${{ env.SHA_SHORT }}.zip diff --git a/README.md b/README.md index 0bc20ef..06bbe77 100644 --- a/README.md +++ b/README.md @@ -1,29 +1,30 @@ # iOS-OTA-Downgrader - **A multi-purpose script to downgrade/restore and jailbreak supported legacy iOS devices** -- **iPhone4Down: Downgrade your iPhone 4 on Linux/Windows (using powdersn0w)** +- **iPhone4Down: Downgrade iPhone 4 GSM on Linux/Windows (using powdersn0w)** - **Linux, macOS, and Windows** are supported - Windows usage is not recommended - - iPhone4Down focuses on Linux support - use [cherryflowerJB](https://web.archive.org/web/20210322151509/https://dora2ios.web.app/CFJB/) or [powdersn0w](https://web.archive.org/web/20221213010446/https://dora2ios.web.app/konayuki/index.html) on macOS instead + - iPhone4Down focuses on Linux support only - use [cherryflowerJB](https://web.archive.org/web/20210322151509/https://dora2ios.web.app/CFJB/) or [powdersn0w](https://web.archive.org/web/20221213010446/https://dora2ios.web.app/konayuki/index.html) on macOS instead - **Read the ["How to Use" wiki page](https://github.com/LukeZGD/iOS-OTA-Downgrader/wiki/How-to-Use) for a step-by-step tutorial** - **Read the ["Troubleshooting" wiki page](https://github.com/LukeZGD/iOS-OTA-Downgrader/wiki/Troubleshooting) for tips, frequent questions, and troubleshooting** ## Other features -- iOS 6.1.3 and 8.4.1 downgrades have the option to **jailbreak** the install +- Option to **jailbreak** iOS 6.1.3 and 8.4.1 downgrades - For iOS 10.3.3 downgrades, use [TotallyNotSpyware](https://totally-not.spyware.lol) -- This script can also restore your device to other iOS versions that you have SHSH blobs for (32-bit/A7/A8 devices, iOS 5 to 12) -- The latest baseband will always be used for 32-bit devices that have baseband. For iPhone 5C and A7 devices, iOS 10.3.3 baseband will be used -- This script can also be used to enter kDFU mode for 32-bit devices -- This script can also be used to restore your iPhone 4 back to iOS 7.1.2 with the option to jailbreak the install -- This script can also be used to restore supported devices to their latest versions -- This script can also be used to save on-board SHSH blobs for 32-bit devices +- Restore to other iOS versions with SHSH blobs (32-bit/A7/A8 devices, iOS 5 to 12) +- The latest baseband will be used for 32-bit devices if applicable +- Place device to pwned iBSS/kDFU mode for 32-bit devices +- Clear NVRAM for iPhone 4 GSM (Disable/Enable Exploit) +- Restore iPhone 4 to iOS 7.1.2 with the option to jailbreak +- Restore supported devices to their latest iOS version +- Save on-board SHSH blobs for 32-bit devices ## Supported devices - [Identify your device here](https://ipsw.me/device-finder) -- **iPhone 5C and iPad mini 3 devices are NOT supported!** - - iPhone 5C can still be restored to versions that you have SHSH blobs for - - iPhone 4 devices also support restoring with SHSH blobs -- **iPhone4Down supports iPhone 4 GSM only (iPhone3,1)** +- **iPhone 5C and iPad mini 3 devices are NOT supported by OTA downgrades** + - These devices still support restoring to other iOS versions with SHSH blobs +- **iPhone4Down (downgrading without blobs) supports iPhone 4 GSM only (iPhone3,1)** + - All iPhone 4 models still support restoring with SHSH blobs and to iOS 7.1.2 @@ -71,6 +72,9 @@ ## Supported OS versions/distros + +#### Supported architectures: x86_64, armhf (Linux), arm64 + - [**Ubuntu**](https://ubuntu.com/) 22.04 and newer, and Ubuntu-based distros like [Linux Mint](https://www.linuxmint.com/) - [**Arch Linux**](https://www.archlinux.org/) and Arch-based distros like [EndeavourOS](https://endeavouros.com/) - [**Fedora**](https://getfedora.org/) 36 and newer diff --git a/bin/linux/arm/futurerestore_new b/bin/linux/arm/futurerestore_new new file mode 100755 index 0000000..6a2956f Binary files /dev/null and b/bin/linux/arm/futurerestore_new differ diff --git a/bin/linux/arm/futurerestore_old b/bin/linux/arm/futurerestore_old new file mode 100755 index 0000000..f00f562 Binary files /dev/null and b/bin/linux/arm/futurerestore_old differ diff --git a/bin/linux/arm/hfsplus b/bin/linux/arm/hfsplus index e01b770..360eff8 100755 Binary files a/bin/linux/arm/hfsplus and b/bin/linux/arm/hfsplus differ diff --git a/bin/linux/arm/idevicererestore b/bin/linux/arm/idevicererestore index 188eb1a..ae60dd1 100755 Binary files a/bin/linux/arm/idevicererestore and b/bin/linux/arm/idevicererestore differ diff --git a/bin/linux/arm/idevicerestore b/bin/linux/arm/idevicerestore index 66ca7c1..a481b7d 100755 Binary files a/bin/linux/arm/idevicerestore and b/bin/linux/arm/idevicerestore differ diff --git a/bin/linux/arm/ipsw b/bin/linux/arm/ipsw index 957d393..d93c743 100755 Binary files a/bin/linux/arm/ipsw and b/bin/linux/arm/ipsw differ diff --git a/bin/linux/arm/irecovery2 b/bin/linux/arm/irecovery2 new file mode 100755 index 0000000..8d400ee Binary files /dev/null and b/bin/linux/arm/irecovery2 differ diff --git a/bin/linux/arm/ticket b/bin/linux/arm/ticket new file mode 100755 index 0000000..4255254 Binary files /dev/null and b/bin/linux/arm/ticket differ diff --git a/bin/linux/arm/validate b/bin/linux/arm/validate new file mode 100755 index 0000000..72cf199 Binary files /dev/null and b/bin/linux/arm/validate differ diff --git a/bin/linux/arm/xpwntool b/bin/linux/arm/xpwntool index fda3538..ff129c3 100755 Binary files a/bin/linux/arm/xpwntool and b/bin/linux/arm/xpwntool differ diff --git a/restore.sh b/restore.sh index 31291d0..1d7352c 100755 --- a/restore.sh +++ b/restore.sh @@ -134,18 +134,17 @@ set_tool_paths() { xmlstarlet="$(which xmlstarlet)" zenity="$(which zenity)" - if [[ -e ../resources/sudoloop && $device_argmode != "sudoloop" ]]; then + if [[ -e ../resources/sudoloop && $device_sudoloop != 1 ]]; then local opt log "Previous run failed to detect iOS device." print "* You may enable sudoloop mode, which will run some tools as root." read -p "$(input 'Enable sudoloop mode? (y/N) ')" opt if [[ $opt == 'Y' || $opt == 'y' ]]; then - device_argmode="sudoloop" + device_sudoloop=1 fi - rm ../resources/sudoloop fi - if [[ $(uname -m) == "a"* || $device_argmode == "sudoloop" || $(id -u $USER) == 999 ]]; then + if [[ $(uname -m) == "a"* || $device_sudoloop == 1 || $(id -u $USER) == 999 ]]; then print "* Enter your user password when prompted" sudo -v (while true; do sudo -v; sleep 60; done) & @@ -218,6 +217,7 @@ set_tool_paths() { error "Your platform ($OSTYPE) is not supported." "* Supported platforms: Linux, macOS, Windows" fi log "Running on platform: $platform ($platform_ver)" + rm ../resources/sudoloop 2>/dev/null # common if [[ $platform != "macos" ]]; then @@ -604,7 +604,8 @@ device_find_mode() { if [[ $device_in != 1 ]]; then if [[ $timeout != 1 ]]; then - error "Failed to find device in $1 mode (Timed out)." + touch ../resources/sudoloop + error "Failed to find device in $1 mode (Timed out). Please run the script again." fi return 1 fi @@ -1010,7 +1011,7 @@ download_file() { local sha1=$($sha1sum $2 | awk '{print $1}') if [[ $sha1 != "$3" ]]; then error "Verifying $filename failed. The downloaded file may be corrupted or incomplete. Please run the script again" \ - "SHA1sum mismatch. Expected $3, got $sha1" + "* SHA1sum mismatch. Expected $3, got $sha1" fi } @@ -1390,7 +1391,7 @@ shsh_save() { log "Successfully saved $version blobs: $shsh_path" else error "Saving $version blobs failed. Please run the script again" \ - "It is also possible that $version for $device_type is no longer signed" + "* It is also possible that $version for $device_type is no longer signed" fi } @@ -1460,6 +1461,8 @@ ipsw_prepare_1033() { mv $iBECb.im4p $iBECb.orig $bspatch $iBSSb.orig $iBSSb.im4p ../resources/patch/$iBSSb.patch $bspatch $iBECb.orig $iBECb.im4p ../resources/patch/$iBECb.patch + fi + if [[ $device_type == "iPad4,4" || $device_type == "iPad4,5" ]]; then cp $iBSSb.im4p $iBECb.im4p ../saved/$device_type else cp $iBSS.im4p $iBEC.im4p ../saved/$device_type @@ -1692,7 +1695,7 @@ ipsw_prepare_powder() { if [[ ! -e "$ipsw_custom.ipsw" ]]; then error "Failed to find custom IPSW. Please run the script again" \ - "You may try selecting N for memory option" + "* You may try selecting N for memory option" fi } @@ -1769,7 +1772,7 @@ ipsw_prepare_cherry() { if [[ ! -e "$ipsw_custom.ipsw" ]]; then error "Failed to find custom IPSW. Please run the script again" \ - "You may try selecting N for memory option" + "* You may try selecting N for memory option" fi log "iOS 4 Fix" # From ios4fix @@ -2353,7 +2356,7 @@ for i in "$@"; do "--ipsw-verbose" ) ipsw_verbose=1;; "--jailbreak" ) ipsw_jailbreak=1;; "--memory" ) ipsw_memory=1;; - "--sudoloop" ) device_argmode="sudoloop";; + "--sudoloop" ) device_sudoloop=1;; esac done