Skip to content

Commit 3e54e14

Browse files
committed
more powder and dra v6 fixes
- try fix 4.1/4.2.1 for the dra v6 for real this time - fix touch 4 ios 7 not using aquila after switching over to dra v6 untether
1 parent 135ecbb commit 3e54e14

1 file changed

Lines changed: 32 additions & 38 deletions

File tree

restore.sh

Lines changed: 32 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -3793,8 +3793,6 @@ ipsw_prepare_bundle() {
37933793
local key="$device_fw_key"
37943794
local vers="$device_target_vers"
37953795
local build="$device_target_build"
3796-
local hw="$device_model"
3797-
local base_build="11D257"
37983796
local RootSize
37993797
local daibutsu
38003798
FirmwareBundle="FirmwareBundles/"
@@ -3894,21 +3892,7 @@ ipsw_prepare_bundle() {
38943892
fi
38953893

38963894
if [[ $1 == "base" ]]; then
3897-
case $device_type in
3898-
iPhone5,[12] ) hw="iphone5";;
3899-
iPhone5,[34] ) hw="iphone5b";;
3900-
iPad2,[123] ) hw="ipad2";;
3901-
iPad2,[567] ) hw="ipad2b";;
3902-
iPad3,[123] ) hw="ipad3";;
3903-
iPad3,[456] ) hw="ipad3b";;
3904-
esac
3905-
case $device_base_build in
3906-
11[AB]* ) base_build="11B554a";;
3907-
10* ) base_build="$device_base_build";;
3908-
9B* ) base_build="9B206";;
3909-
9A* ) base_build="9A405";;
3910-
esac
3911-
device_powder_exploit="src/target/$hw/$base_build/exploit"
3895+
ipsw_prepare_powder_exploit
39123896
echo "<key>RamdiskExploit</key><dict>" >> $NewPlist
39133897
echo "<key>exploit</key><string>$device_powder_exploit</string>" >> $NewPlist
39143898
echo "<key>inject</key><string>partition</string></dict>" >> $NewPlist
@@ -4778,16 +4762,21 @@ ipsw_prepare_specialios7() {
47784762
"$dir/hfsplus" ramdisk.dec chown 0:0 private/etc/rc.boot
47794763
"$dir/hfsplus" ramdisk.dec add $sundance/exploit/exploit-k48.dmg exploit.dmg
47804764
elif [[ $ipsw_jailbreak == 1 ]]; then # touch 4 only
4781-
local exploit="src/target/n81/10B500/exploit"
4782-
ipsw_prepare_partition_script
4765+
touch ios7
4766+
"$dir/hfsplus" ramdisk.dec add ios7 ios7
4767+
fi
4768+
4769+
if [[ $device_type == "iPod4,1" ]]; then # dra v6 to untether
47834770
log "Adding exploit and partition stuff"
4771+
ipsw_prepare_powder_exploit
4772+
ipsw_prepare_partition_script
47844773
cp -R ../resources/firmware/src .
47854774
"$dir/hfsplus" ramdisk.dec untar src/bin.tar
47864775
"$dir/hfsplus" ramdisk.dec mv sbin/reboot sbin/reboot_
47874776
"$dir/hfsplus" ramdisk.dec add partition sbin/reboot
47884777
"$dir/hfsplus" ramdisk.dec chmod 755 sbin/reboot
47894778
"$dir/hfsplus" ramdisk.dec chown 0:0 sbin/reboot
4790-
"$dir/hfsplus" ramdisk.dec add $exploit exploit
4779+
"$dir/hfsplus" ramdisk.dec add $device_powder_exploit exploit
47914780
fi
47924781

47934782
log "Repack Restore Ramdisk"
@@ -5040,6 +5029,26 @@ ipsw_prepare_sundanceinh2a() {
50405029
mv temp.ipsw "$ipsw_custom.ipsw"
50415030
}
50425031

5032+
ipsw_prepare_powder_exploit() {
5033+
local hw="$device_model"
5034+
local base_build="11D257"
5035+
case $device_type in
5036+
iPhone5,[12] ) hw="iphone5";;
5037+
iPhone5,[34] ) hw="iphone5b";;
5038+
iPad2,[123] ) hw="ipad2";;
5039+
iPad2,[567] ) hw="ipad2b";;
5040+
iPad3,[123] ) hw="ipad3";;
5041+
iPad3,[456] ) hw="ipad3b";;
5042+
esac
5043+
case $device_base_build in
5044+
11[AB]* ) base_build="11B554a";;
5045+
10* ) base_build="$device_base_build";;
5046+
9B* ) base_build="9B206";;
5047+
9A* ) base_build="9A405";;
5048+
esac
5049+
device_powder_exploit="src/target/$hw/$base_build/exploit"
5050+
}
5051+
50435052
ipsw_prepare_partition_script() {
50445053
local file="partition"
50455054
log "Preparing partition script"
@@ -5291,6 +5300,7 @@ ipsw_prepare_multipatch() {
52915300
:
52925301
elif [[ $device_target_powder == 1 && $device_target_vers == "4"* ]]; then
52935302
log "Adding exploit and partition stuff"
5303+
ipsw_prepare_powder_exploit
52945304
cp -R ../resources/firmware/src .
52955305
"$dir/hfsplus" RestoreRamdisk.dec untar src/bin4.tar
52965306
"$dir/hfsplus" RestoreRamdisk.dec mv sbin/reboot sbin/reboot_
@@ -5299,25 +5309,9 @@ ipsw_prepare_multipatch() {
52995309
"$dir/hfsplus" RestoreRamdisk.dec chmod 755 sbin/reboot
53005310
"$dir/hfsplus" RestoreRamdisk.dec chown 0:0 sbin/reboot
53015311
elif [[ $device_target_powder == 1 ]]; then
5302-
local hw="$device_model"
5303-
local base_build="11D257"
5304-
case $device_type in
5305-
iPhone5,[12] ) hw="iphone5";;
5306-
iPhone5,[34] ) hw="iphone5b";;
5307-
iPad2,[123] ) hw="ipad2";;
5308-
iPad2,[567] ) hw="ipad2b";;
5309-
iPad3,[123] ) hw="ipad3";;
5310-
iPad3,[456] ) hw="ipad3b";;
5311-
esac
5312-
case $device_base_build in
5313-
11[AB]* ) base_build="11B554a";;
5314-
10* ) base_build="$device_base_build";;
5315-
9B* ) base_build="9B206";;
5316-
9A* ) base_build="9A405";;
5317-
esac
5318-
device_powder_exploit="src/target/$hw/$base_build/exploit"
5319-
ipsw_prepare_partition_script
53205312
log "Adding exploit and partition stuff"
5313+
ipsw_prepare_powder_exploit
5314+
ipsw_prepare_partition_script
53215315
"$dir/hfsplus" RestoreRamdisk.dec untar src/bin.tar
53225316
"$dir/hfsplus" RestoreRamdisk.dec mv sbin/reboot sbin/reboot_
53235317
"$dir/hfsplus" RestoreRamdisk.dec add partition sbin/reboot

0 commit comments

Comments
 (0)