[Request] How to Create Patched Boot Image - OnePlus 7 Pro Questions & Answers

I am looking to learn how to extract a boot image to patch. The last source for patched boot images has not updated since 9.5.10. I would like to be less dependent and be able to do it on my own.
Can someone put together a quick tutorial on how to extract a boot.img so I can run it though Magisk and create a patched one?

https://forum.xda-developers.com/showpost.php?p=79548858&postcount=6

I have the current rooted AA boot image in the guide in my signature. I extract them directly from the phone.

ozfive said:
I am looking to learn how to extract a boot image to patch. The last source for patched boot images has not updated since 9.5.10. I would like to be less dependent and be able to do it on my own.
Can someone put together a quick tutorial on how to extract a boot.img so I can run it though Magisk and create a patched one?
Click to expand...
Click to collapse
1)Download payload dumper.
2)Extract payload file from rom zip.
3)Put payload file in payload_input folder.
4)Run exe file.
5)After process complete check payload_output folder. All extracted there.
Download payload dumper from here :- https://forum.xda-developers.com/attachment.php?attachmentid=4760222&d=1558078935

Patched boot images are irrelevant and only necessary for devices without a working TWRP recovery. If you want to root, either boot TWRP once or boot and install TWRP (recommended) and then install the magisk zip from there.

larsdennert said:
I have the current rooted AA boot image in the guide in my signature. I extract them directly from the phone.
Click to expand...
Click to collapse
How do you extract the boot.img from the phone? I have the tmo version and would like to say on the stock room with root.
Sent from my GM1915 using Tapatalk

You need root to extract a partition, but if you have root then you have no need for it except to share it so someone else can get root.
In other words are you rooted already? If not, you'll need to use the other instructions or get a rooted or non rooted image from someone with a T-Mobile phone.
I'm going to guess you could fastboot boot boot.img to any rooted boot image for the one plus 7 pro, have root and then install magisk.

larsdennert said:
You need root to extract a partition, but if you have root then you have no need for it except to share it so someone else can get root.
In other words are you rooted already? If not, you'll need to use the other instructions or get a rooted or non rooted image from someone with a T-Mobile phone.
I'm going to guess you could fastboot boot boot.img to any rooted boot image for the one plus 7 pro, have root and then install magisk.
Click to expand...
Click to collapse
Not rooted yet, but everything I have read so far is that you need a patched boot.img to root, or you can create one from the boot.img in an oos package with magisk manager. The problem is, there isn't a tmo oos package out there yet, so it looks like rooting the tmo software isn't possible at the moment. Is this correct?
Sent from my SM-T550 using Tapatalk

Is your bootloader unlocked? That would be step one. Read up on the thread for that.

Not yet, but will be....trying to get my research done before I go for it... don't want to mess it up, been a few years since I rooted a phone.
Sent from my GM1915 using Tapatalk

Related

Patched Phoenix 2 boot image with Magisk (NOT WORKING ROOT YET)

Now first off, this Magisk image would technically not work due to the small issue that the LG Phoenix 2's bootloader can't be unlocked. However, you could still, if you somehow manage to force a bootloader unlock and get into fastboot mode, flash this boot.img file and achieve Magisk root. The files needed (excluding adb) are below in a .rar file, sadly I cannot give you a guide on how to flash this image file, as I cannot access fastboot, and I have mostly stopped using my Phoenix 2. If you manage to get Magisk working on the Phoenix 2, post below!
Root files on MediaFire (will be reuploaded on AFH when possible)
Judging by the lack of replies I'm guessing no one else got root either :\
Hi,
I see there are no replies for this thread, quite old thread. I still have this phone but I retired it so I looked recently how this can be rooted.
I want to ask you how did you read the boot.img that you attached to the link? Or did you extract it from a firmware?
One idea how you might write patched boot back to the phone is using QFIL app. I did not try it, but I guess it should be possible to put the phone in Download mode and use QFIL with it. I will look into it when I have some time.
BR

T-Mobile IN2017 Root Method?

All of the similar threads just end after a few replies (I think because people didn't have unlocked bootloaders) so I thought I'd try to ask again. I have a T-Mo OP8 (IN2017) on 10.5.22IN55CB. I already have the bootloader unlocked. But all of the root methods I can find need a payload.bin from the stock firmware, and I can't seem to find that. Is there another method or a source for branded firmware? I wasn't sure if I could do it by just booting the TWRP found on this board without flashing the recovery.
TIA.
SilverZero said:
All of the similar threads just end after a few replies (I think because people didn't have unlocked bootloaders) so I thought I'd try to ask again. I have a T-Mo OP8 (IN2017) on 10.5.22IN55CB. I already have the bootloader unlocked. But all of the root methods I can find need a payload.bin from the stock firmware, and I can't seem to find that. Is there another method or a source for branded firmware? I wasn't sure if I could do it by just booting the TWRP found on this board without flashing the recovery.
TIA.
Click to expand...
Click to collapse
I booted into TWRP and took a backup of the device. I then transferred the backup to my local PC and took the boot file from the backup, renaming the extension to .img. I then put this boot image on my device and downloaded magisk manager and set magisk manager to install magisk by patching a file. Once completed, I downloaded the patched file to my PC and booted to fastboot. While in fastboot, I flashed the magisk_patched boot image to both boot slots (boot_a, and boot_b). Upon rebooting, I had root. One thing, as soon as you have root, I recommend taking an image of your persist file (for fingerprint) to prevent any issues if the persist partition gets corrupted on your device. Search the forum for instructions on how to do this.
Cheers,
B.D.
You literally don't have to do anything special. Boot TWRP, flash Magisk zip in TWRP, reboot. Done.
stompysan said:
You literally don't have to do anything special. Boot TWRP, flash Magisk zip in TWRP, reboot. Done.
Click to expand...
Click to collapse
Works great. Thanks!
BostonDan said:
I booted into TWRP and took a backup of the device. I then transferred the backup to my local PC and took the boot file from the backup, renaming the extension to .img. I then put this boot image on my device and downloaded magisk manager and set magisk manager to install magisk by patching a file. Once completed, I downloaded the patched file to my PC and booted to fastboot. While in fastboot, I flashed the magisk_patched boot image to both boot slots (boot_a, and boot_b). Upon rebooting, I had root. One thing, as soon as you have root, I recommend taking an image of your persist file (for fingerprint) to prevent any issues if the persist partition gets corrupted on your device. Search the forum for instructions on how to do this.
Cheers,
B.D.
Click to expand...
Click to collapse
Post below yours worked for me but I appreciate the advice on backups and what to watch for. I haven't installed TWRP yet, just booted it and installed.
SilverZero said:
Works great. Thanks!
Click to expand...
Click to collapse
I should state one thing that I didn't in my original post. Booting TWRP and flashing that way ONLY works if you are still running Android 10. Since you have a T-Mobile variant, I knew this was a non-issue (we STILL don't have official A11). For those running Android 11, you do have to patch the boot image and flash it like stated above. Also note that this will likely change if we get TWRP on A11. Once we have that working, flashing Magisk from it should work fine.
stompysan said:
I should state one thing that I didn't in my original post. Booting TWRP and flashing that way ONLY works if you are still running Android 10. Since you have a T-Mobile variant, I knew this was a non-issue (we STILL don't have official A11). For those running Android 11, you do have to patch the boot image and flash it like stated above. Also note that this will likely change if we get TWRP on A11. Once we have that working, flashing Magisk from it should work fine.
Click to expand...
Click to collapse
Following up on this just in case you know anything new. My IN2017 just updated to A11 without any action on my part, and I lost root. Is there a TWRP or patched boot img that you know of for us on TMo now?
There is no working twrp for us on Android 11. I also haven't seen a patched boot image of 11.0.1.3.IN55CB around yet. I have that firmware extracted on my laptop so I could grab the boot image and patch it for you, but I won't be able to do that until later tomorrow. If no one else has it out or if you don't find it before I can get to it, I'll post it up.
Edit: Here's the patched boot image: Magisk Patched Boot IMG TMO 11.0.1.3

[FASTBOOT] [daisy] Patched boot.img for V11.0.18.0 (Android 10)

Xiaomi Mi A2 Lite 11.0.18.0 / Magisk 21.4
or
Hi, big thanks for this. I'd rather patch the image myself, using a tutorial like this one – https://www.thecustomdroid.com/root-xiaomi-mi-a2-a2-lite-android-pie-magisk/. Where do you get the stock images?
Is this the right place? https://c.mi.com/oc/miuidownload/detail?guide=2 (search for "Mi A2 Lite")
Or this one? https://c.mi.com//miuidownload/detail?device=1700354
Thanks, I figured it out. The newest version can be downloaded at https://c.mi.com/oc/miuidownload/detail?guide=2, extract it using `tar xvzf daisy_global_images_V11.0.18.0.QDLMIXM_20210126.0000.00_10.0_286d778cee.tgz` on Linux and the boot.img is located in the images/ directory. Then you can follow the guide at https://www.thecustomdroid.com/root-xiaomi-mi-a2-a2-lite-android-pie-magisk/ to create the patched image and boot from it.
mariansam said:
Hi, big thanks for this. I'd rather patch the image myself, using a tutorial like this one – https://www.thecustomdroid.com/root-xiaomi-mi-a2-a2-lite-android-pie-magisk/. Where do you get the stock images?
Is this the right place? https://c.mi.com/oc/miuidownload/detail?guide=2 (search for "Mi A2 Lite")
Or this one? https://c.mi.com//miuidownload/detail?device=1700354
Click to expand...
Click to collapse
you can find updates here https://xiaomifirmwareupdater.com/miui/daisy/
depends how everyone uses to update his phone, but i always use fastboot file with xiaomiflash, it's only 2 clics and avoids me to care about uninstall magisk.
also the original boot.img is inside so just copy it on phone, magisk patch the file and then i fastboot boot the patched
hi! thanks for your work!
I've tried to update my phone, like I always do, restoring 11.0.17 boot stock image first, but I get an update error.
Any suggest?
u can try as i use to do, explained in message above
I tried but Xiaomi Flash doesn't work properly on my PC, I am afraid of losing data on phone.
Why am i unable to update after flashing stock boot image, like I always do??
Anyone having trouble?

BLU V50

Anyone have a root method for the BLU V50? Thanks in advance
Look inside here:
Root Spreadtrum Devices via Magisk Patched boot.img
This guide will show you the steps to root your Spreadtrum device via Magisk patched boot.img file, which we will extract from PAC firmware.
www.droidwin.com
jwoegerbauer said:
Look inside here:
Root Spreadtrum Devices via Magisk Patched boot.img
This guide will show you the steps to root your Spreadtrum device via Magisk patched boot.img file, which we will extract from PAC firmware.
www.droidwin.com
Click to expand...
Click to collapse
jwoegerbauer said:
Look inside here:
Root Spreadtrum Devices via Magisk Patched boot.img
This guide will show you the steps to root your Spreadtrum device via Magisk patched boot.img file, which we will extract from PAC firmware.
www.droidwin.com
Click to expand...
Click to collapse
I managed to find a way. Lol I'm just going to have to squeeze the old brain to to get this done it looks like. Thanks for the tip. The methods provided all require a system dump of stock firmware to patch TWRP for the phones recovery partition. I may have to cross my fingers and flash the generic unofficial boot image TWRP for android 10 and hope it fits lol. There are absolutely no custom fits at the moment. Of course I accepted the security patch update which made this a bit more tricky. QP1A.190711.020. I found a thread talking about almost the same update except it was two digits more than the version I got. It's been 6 or 7 years since I stopped theming for the galaxy s3. Course I was only changing xmls and pngs for custom roms back then. None of my old team are active anymore. Team Venum and team nOObz are long history. I even lost my log in info for my old profile. Anyways. Wish me luck. I'm going to learn how to port and develope this time around.
jwoegerbauer said:
Look inside here:
Root Spreadtrum Devices via Magisk Patched boot.img
This guide will show you the steps to root your Spreadtrum device via Magisk patched boot.img file, which we will extract from PAC firmware.
www.droidwin.com
Click to expand...
Click to collapse
Hello. Thanks again in advance. I've tried several command prompt methods to unlock this boot loader with no luck including the Magisk method. I have however managed to patch the TWRP file.
jwoegerbauer said:
Look inside here:
Root Spreadtrum Devices via Magisk Patched boot.img
This guide will show you the steps to root your Spreadtrum device via Magisk patched boot.img file, which we will extract from PAC firmware.
www.droidwin.com
Click to expand...
Click to collapse
I managed to patch the TWRP boot image using the Magisk apk and patch tools but I have no luck unlocking the boot loader..
1. find your firmware file by searching this forum for blu stock firmware repository
2. extract your boot/recovery img file using spd flash tool
3. patch img file with magisk, re-sign it with avbtools
4. patch vbmeta file with avbtools
5. re-flash both vbmeta and boot/recovery using spd research tool
rooted my blu advance l5 with these steps learned from hovatek. ymmv
luridphantom said:
1. find your firmware file by searching this forum for blu stock firmware repository
2. extract your boot/recovery img file using spd flash tool
3. patch img file with magisk, re-sign it with avbtools
4. patch vbmeta file with avbtools
5. re-flash both vbmeta and boot/recovery using spd research tool
rooted my blu advance l5 with these steps learned from hovatek. ymmv
Click to expand...
Click to collapse
Can anyone quickly tell me the easiest way to brick this device? My wife will buy me a new phone "when this one stops working"
Did anyone manage to root this device without bricking it? Firmware is not available in the Blu Repo (at least not yet). Our team would love to find a workable method for this phone. We have access to a bunch and want to be able to run Linux Deploy on them and also write app to automatically reboot the phone if the network connectivity is loss.
Hey, I was able to figure out how to deal with this bootloader stuff after many hours of work
Give this thread a look, it pretty much details every step needed to unlock the bootloader: https://forum.hovatek.com/thread-32287.html
Keep in mind that the OP of that thread is using a way older version of fastboot. For me, r26.0.1 worked best:
Windows: https://dl.google.com/android/repository/platform-tools_r26.0.1-windows.zip
Mac: https://dl.google.com/android/repository/platform-tools_r26.0.1-darwin.zip
Linux: https://dl.google.com/android/repository/platform-tools_r26.0.1-linux.zip
The above step is essential as newer versions of fastboot do NOT have the "fastboot flashing unlock_bootloader <bin>" step
again YMMV, but good luck
Me again, 6 hrs after the fact
Trial and Error enabled root on the V50 - follow these steps
1. Unlock bootloader as above
2. Create a custom signed vbmeta https://forum.hovatek.com/thread-32664.html (I used the same .pem from https://forum.hovatek.com/thread-32287.html to do this) - Make sure the VBMETA IS ANDROID 10 despite G0350WW firmware saying it's Android 9
3. Create custom boot with magisk (plenty of instructions to do this online, go with the github instructions)
4. Sign the custom magisk boot with THE SAME PUB KEY FROM STEP 2
5. Flash your new vbmeta and boot onto your phone via fastboot
6. Reboot, hope and pray it turns on
This is what worked for me, but again YMMV.
njoaquin said:
Me again, 6 hrs after the fact
Trial and Error enabled root on the V50 - follow these steps
1. Unlock bootloader as above
2. Create a custom signed vbmeta https://forum.hovatek.com/thread-32664.html (I used the same .pem from https://forum.hovatek.com/thread-32287.html to do this) - Make sure the VBMETA IS ANDROID 10 despite G0350WW firmware saying it's Android 9
3. Create custom boot with magisk (plenty of instructions to do this online, go with the github instructions)
4. Sign the custom magisk boot with THE SAME PUB KEY FROM STEP 2
5. Flash your new vbmeta and boot onto your phone via fastboot
6. Reboot, hope and pray it turns on
This is what worked for me, but again YMMV.
Click to expand...
Click to collapse
to be clear, the v50 uses the same firmware as the g50 plus?
dtingley11222 said:
to be clear, the v50 uses the same firmware as the g50 plus?
Click to expand...
Click to collapse
Correct, you can see it when you go to the firmware details of the v50 itself. You can get the firmware files when you search this forum for blu stock firmware repository
V50 is essentially a re-wrapped g50
njoaquin said:
Correct, you can see it when you go to the firmware details of the v50 itself. You can get the firmware files when you search this forum for blu stock firmware repository
V50 is essentially a re-wrapped g50
Click to expand...
Click to collapse
Hey, is there any way you could get me a rooted image and signed vbmeta? I have all the information that you would need, I just can't do the steps because im stupid. I would pay you to do it if you wanted
If the BLU V50 uses the same stock rom as the blu g50, if someone were to give out their patched vb meta and boot img, wouldn't it work for anyones BLU V50 if they just flashed it?
dtingley11222 said:
If the BLU V50 uses the same stock rom as the blu g50, if someone were to give out their patched vb meta and boot img, wouldn't it work for anyones BLU V50 if they just flashed it?
Click to expand...
Click to collapse
you need to patch recovery flash it back using the spreadtrum research tool and use the key combo to boot into root
luridphantom said:
you need to patch recovery flash it back using the spreadtrum research tool and use the key combo to boot into root
Click to expand...
Click to collapse
If I unlock the Bootloader, could I just flash it back with Fastboot?
Just tried flashing recovery and it bricked my phone
dtingley11222 said:
If I unlock the Bootloader, could I just flash it back with Fastboot?
Click to expand...
Click to collapse
you cant unlock the bootloader. follow this tutorial or you'll keep bricking your v50
How to create a custom signed vbmeta.img for Unisoc using AVBtool
If you're into rooting and flashing custom recoveries then Android Verified Boot (AVB) or dmverity is something you should be aware of. We'd dropped a blog post on why dmverity could be causing your p
forum.hovatek.com
luridphantom said:
you cant unlock the bootloader. follow this tutorial or you'll keep bricking your v50
How to create a custom signed vbmeta.img for Unisoc using AVBtool
If you're into rooting and flashing custom recoveries then Android Verified Boot (AVB) or dmverity is something you should be aware of. We'd dropped a blog post on why dmverity could be causing your p
forum.hovatek.com
Click to expand...
Click to collapse
Actually you can unlock the Bootloader. I already did. I don't know how to follow that tutorial. If I gave you my boot and vbmeta could you do it for me?
https://drive.google.com/file/d/1q1vt6f6-0Wg6iF4prOJS2o9ZauWM4qNy/view?usp=sharing : vbmeta
https://drive.google.com/file/d/1gEV2jxhnmmjKuUaqVhqPnH9oZNmzZBGi/view?usp=sharing : boot
dtingley11222 said:
Actually you can unlock the Bootloader. I already did. I don't know how to follow that tutorial. If I gave you my boot and vbmeta could you do it for me?
Click to expand...
Click to collapse
oh weird i thought blu doesnt even support bootloader unlocking
can you access fastboot? with an unlocked bootloader you can flash an empty vbmeta and dont have to go through the above steps

Extracted Stock Files

So I see a lot of people using magisk patched boot images that are really old. It'd be better to patch the image yourself from magisk and use that. The problem might be that it's not that easy to extract it.
You can find most of the stuff from stock rom extracted by me here. The files were extracted from the Indian varient. Make sure to use the appropriate files for your stock rom. The index site does have other files like some old and unstable kernels so don't go flashing everything you see from the root directory. This just started as a personal archive. The domain is free, so idk how long it'll stay active either.
As always, use everything at your own risk.​
Do Magisk versions newer than v24.3 work this way?
newt23 said:
Do Magisk versions newer than v24.3 work this way?
Click to expand...
Click to collapse
Yes, patching the boot image is the recommended way to install Magisk.
The official guide does ask to patch AP wholly for samsung devices, but patching the boot image itself is faster.
Official Guide
I don't understand why I get bootloops if I update to v25.x from v24.3 from the Magisk app (using direct method). As I understand it, it also (re-)patches the boot image.
newt23 said:
I don't understand why I get bootloops if I update to v25.x from v24.3 from the Magisk app (using direct method). As I understand it, it also (re-)patches the boot image.
Click to expand...
Click to collapse
That's how I updated too. Try flashing the magisk zip directly.
Or, only update the magisk app, patch the boot image, rename it as boot.img, put it in a tar file, and then flash it to "AP" using Odin.
Hmm... this is funny. I patched the stock boot image and flashed it using Odin and still got bootloops. I took a full nandroid backup beforehand so I was able to get everything working by flashing TWRP again and restoring the previous boot image.
I get bootloops if I install v25.x from TWRP after installing a rom or update to v25.x from v24.3 directly or by patching the stock boot image. The only one that's left now is flashing v25.x zip from TWRP (while having a functioning system with v24.3) but something tells me it's going to end in bootloops too.

Categories

Resources