Question Questions about unlocking bootloader on a brand new phone. - Google Pixel 7 Pro

I plan to root this phone at some point. When I first get the phone, can I bypass the setup and just get to the settings so I can unlock the bootloader? Also I got some old stripped down adb/fastboot installed from way back. Will installing new Android tools cause any problems? Any other suggestions would be appreciated. Thanks!

Old fastboot and adb probably won't work properly anymore. People have also had some issue with a recent version 34 of the platform tools. I would reccomend updating updating to platform tools 33.0.3 for now in Android Studio.
I think there is an option to skip the initial Android Setup, but I don't remember.

You can skip most parts of setup, though it will still make you agree to terms and arbitration (if applicable). This will let you get to the home screen, the settings, and developer options. As for the old adb package, I would go ahead and remove it and manually install. Grab 33.0.3 from either Android Studio (as mentioned above) or through a download package. Once you have the tools, drop them in a folder somewhere easily remembered (I just use C:\adb). Add the folder as an environment variable, reboot, and you are golden. If you ever need to update your platform-tools, you can typically just kill the ADB server if it is running (adb kill-server), drop in the replacement files, and be back up and running.
Alternatively, if the minimal package you have already has a folder and environment variables set up, find that folder, clean it out, and replace the files with the 33.0.3 platform-tools. Should be set after that.

stompysan said:
You can skip most parts of setup, though it will still make you agree to terms and arbitration (if applicable). This will let you get to the home screen, the settings, and developer options. As for the old adb package, I would go ahead and remove it and manually install. Grab 33.0.3 from either Android Studio (as mentioned above) or through a download package. Once you have the tools, drop them in a folder somewhere easily remembered (I just use C:\adb). Add the folder as an environment variable, reboot, and you are golden. If you ever need to update your platform-tools, you can typically just kill the ADB server if it is running (adb kill-server), drop in the replacement files, and be back up and running.
Alternatively, if the minimal package you have already has a folder and environment variables set up, find that folder, clean it out, and replace the files with the 33.0.3 platform-tools. Should be set after that.
Click to expand...
Click to collapse
Thanks for the replies. I think someone had created a stripped down android development package that only included necessary stuff for the phones. I really can't remember because it's been so long. I think the old package does have the environment variables because I don't have to type the path to adb. I have C:\adb which has four files in it (adb.exe, AdbWinApi.dll, AdbWinUsbApi.dll, and fastboot.exe). I also use this to connect to my firesticks.

I don't really suggest using the minimal adb and fastboot -- especially for unlocking the bootloader and flashing -- and I suggest using the platform tools from the official source from Google which can be found here: https://developer.android.com/studio/releases/platform-tools
Also, this way, you don't have to download the whole SDK or Studio package just for the platform tools/adb;fastboot.
BUT THE CURRENT RELEASE HAS BEEN KNOWN TO CAUSES ISSUES so until it's confirmed that r34.0.1 doesn't (as no one has tried with .1 nor has it been used for the March images yet), I suggest downloading from THIS POST (version r33.0.3) using the last known version that had the least amount of issues...

Related

Easier 1-2-3 Droid 2 Root for Windows / Linux / Mac

For Droid 2's on Gingerbread, click link below to find info to Root your phone
http://www.droid-life.com/2011/09/0...roidx2-droidx-and-droid3-running-gingerbread/
One Click Root Version for Linux and Works for Mac, too!
This is still a work in progress! Gonna call it 3.3 (I went through 3 previous versions). It takes the 2.2.1 version and adds a user interface. Nice, easy, clean. In order to run this script, you need to chmod (change permission) of the .sh file, and then execute it.
Download the file here: http://kimete.com/droid/beta/dorootv3.sh
It is good for both Linux and Mac. All you have to do is execute it and the script will download all the appropriate files for you!
How to run this in Ubuntu/Linux
How-to video here: http://www.youtube.com/watch?v=gvlB3e_UE8I
Note: General idea. You no longer need to update android-sdk, though.
1. Download the file.
2. Right-click the file, choose properties, choose the permission tab, and check executing file as program, close window
3. Double-click the file, choose Run in Terminal, and it'll start.
4. Choose 1 for install and root. Choose 2 for root process only. Only good if you've rooted using this method before, or you need to reroot your phone. Choose 3 to unroot. Choose 4 for credits/donation information. Choose 5 to exit. Choosing other numbers...
How-to for Mac
How-to video here: http://www.youtube.com/watch?v=d7s8dtfYyHI
Note: General idea. You no longer need to download and install android-sdk anymore.
1. Download dorootv3.sh. Best to put it on your desktop.
2. Open a terminal. Go to the magnifying glass and type in terminal, and then select it.
3. Next, you need to change permissions. Type in the terminal chmod 0755 followed with a single space. Then drag the dorootv3.sh into terminal.
You should see something like this chmod 0755 /user/(file path)/dorootv3.sh. Press enter.
4. Now run your file by dragging the file into the terminal again and pressing enter!
5. Now choose and option...
New version of rooting for Linux and Mac! Version 2.2.1!
Linux 2.2.1: http://www.kimete.com/droid/beta/DoRootLinux_221.zip
Mac 2.2.1: http://www.kimete.com/droid/beta/DoRootMac_221.zip
General Instructions:
1. Extract the files.
2. Change the permissions on the doroot.sh file
3. Run doroot.sh file.
Instructions for Linux and Mac
1. Extract the respective files to somewhere accessible. Your home directory or desktop is idea. The file comes in a .zip file. Just open it up and drag and drop the DoRootMac or DoRootLinux folder.
2. Make sure you phone is in PC Mode with USB Debugging enabled
PC Mode: Notification blind -> USB connection -> PC Mode
USB Debugging: Settings -> Applications -> Development -> USB debugging
You need USB debugging icon showing in notifications. Try Charge Only if you can't get PC Mode to show USB debugging.
3. Navigate to the folder in terminal.
example: [cd /DoRootMac or cd /DoRootLinux]
4. enter [chmod 0755 doroot.sh] then run it [./doroot.sh]
5. Let it run.
6. That's it, you are done.
One Click Root for Windows
Here's the Windows version. Facelessuser pushed this through and worked his magic. Give it a try. Very exciting stuff. I haven't used it yet, but according to him, it should work!
Download here, Ver. 2.1.4:
http://www.kimete.com/droid/beta/DoRootWin_2.1.4.zip
Instruction for Windows:
How-to video here: http://www.youtube.com/watch?v=B7RGVikpQ8o
1. Extract the folder from the DORoot zip file to your desktop. You should be moving 7 or 8 files into the tools folder.
2. Install Motorola Drivers
(Tip, to stop the launching of the Verizon/Motorola site, go to the MotoConnect icon in the bottom righ, right click, when phone connects, nothing.)
3. Make sure you phone is in PC Mode with USB Debugging enabled
PC Mode: Notification blind -> USB connection -> PC Mode
USB Debugging: Settings -> Applications -> Development -> USB debugging
You need USB debugging icon showing in notifications. Try Charge Only if you can't get PC Mode to show USB debugging.
4. Double-click and run doroot.bat
5. Let it run.
6. That's it, you are done.
Motorola Drivers (if you are using Windows) which can be found here:
http://www.motorola.com/Support/US-...tware_and_Drivers/USB-and-PC-Charging-Drivers
Many thanks to facelessuser for working his magic!
====
====
How-to Videos
Video of the Rooting Process for D2 and DX by [email protected]
For Windows/Mac/Linux
http://www.youtube.com/watch?v=u5l3MDomDSc
Video of the Rooting Process for D2 and DX by DarkOnion
For Windows
New: http://www.youtube.com/watch?v=B7RGVikpQ8o
Old: http://www.youtube.com/watch?v=gzlg9a-H42w
How to use the ADBDL.sh file by DarkOnion
For Mac and Linux
http://www.youtube.com/watch?v=9cHpGXfEudM
=====
=====
Frequently Asked Questions
Why does my anti-virus tell me that the files contain Trojan's?
The files are exploits and hack your phone. Don't worry, they are clean. However, to be safe, do not download from any other source than the ones linked in this post.
I've gotten countless hate mail and comments on Youtube users about rageagainstthecage-arm5.bin being detected as a trojan. It is an EXPLOIT. If you are scared that the files I hosted are going to give your computer a virus. Look else where, like Z4Root, though, my understanding is that Z4Root also uses rage.
http://forum.xda-developers.com/showthread.php?t=853704
What is do these files/programs/scripts do?
These scripts will root your Droid 2 or Droid X phone with the least amount of user input as possible.
Why should we use this method and not another method?
All the methods are based off the same process/procedure. If you feel like doing MORE work, we can't stop you. The reason why we wrote all these scripts is to expedite the process, make the procedure easier, and to reduce human input which reduces the chance of human error.
Is there anything I need to know in order to successfully root my phone?
Yes. READ THE DIRECTIONS. Read the directions first. A lot of people make errors because they don't read the directions. I've also provided links to my video and another video which outlines the root process. Both are only a few minutes long.
Root failed! What do I do?
Run the script again! Most people succeed on the first or second try. Usually the rest by the third try.
Do I have to install Android SDK and update it?
It depends. The new Linux/Mac version does not require you to. The windows one, we are still working on.
Does this work on other phones?
I can't answer that. I know it works for Droid 2 and Droid X.
Wait a minute, this isn't really one-click! What's the deal?
Deal with it. Don't like it, try the 25+ step process.
When I open up the Superuser app, I get a blank screen.
That is NORMAL. Superuser lists the processes/applications that you've allowed superuser access to. If you haven't allowed anything, then it will be blank.
How do I test if I have root or not?
Try downloading an app like Wireless Tether (published by Google), and running it.
What USB connection mode do I set my phone to?
PC Mode or Charge Only. Choose the one that comes up with USB Debugging.
I am not very good with computers. Is this something I can do?
Oh yes! The key to success is following the directions.
How do I update Android SDK?
On Windows, you just need to double click the SDK Manager.exe. On Linux/Mac, you need to go into terminal, navigate to the tools folder in the android sdk folder, and run this command ./android update sdk. More information can be found in the SDK Readme text file. On Windows, double-click and run the SDK Manager.
I am getting stuck at the "daemon not found/daemon is starting" part. What do I do?
You need to fumble with the settings on your phone. You don't need to close the terminal. Change between PC Mode and Charge Only mode until it starts to continue. If that still doesn't work, also try disabling then enabling USB debugging for each mode.
=====
=====
Reporting an Error or a Problem
You can report errors right here in this thread. Make sure you give us as much information as possible. List what operating system you are on, what phone you have, at what part of the script you had errors, and anything else you may have tried or done. The more information you provide us, the better we understand situations. Posting up pics or logs of the terminal is extremely helpful.
=====
=====
Change log for 1-2-3 Root
Version 0.0 - 25+ step tutorial on how to root D2 on Windows and Mac
Version 1.0 - Initial scripts to streamline processes and reduce user error in Ver. 0.0.
Version 2.0 - Streamline of multiple scripts into 1 script. Minimal commands. Minimal work. With error checking and reporting.
Version 2.1 - addressed issue where remnants of a previous root would not allow root to complete
Version 2.1.1 -
-Cleanup code.
-Address issue where I thought I was killing a hanging rage, but I wasn't (It was a syntax thing)
-Fix for ERROR6 or ERROR5 (this was drastically different than what I did in windows. I wasn't returning exactly a string in format I thought when doing the check, so I had to do some ridiculous stuff to process it.)
-Better error resolution. (more error checking)
-Refined unroot.
-Reboot if you had files from a previous root
-Now the script will automagically download needed root files if they are not in your folder. (If you are behind a proxy, make sure your mac or linux has curl or wget configured for proxies respectively)
-Longer wait before remount (I had it not remount because it was busy once)
Version 2.1.2 -
Linux and Mac
Contains everything windows 2.1.1
Unroots non bootstrapped phones too
All
Contains option to unroot
Version 2.1.3 - Added dounroot.bat
Vesion 2.1.4 -
-Fix bug where people were getting a false ERROR5 because they already had Superuser.apk
-Hide killing of busybox before unroot
Version 2.1.4 - Files are standalone. No need to download Android SDK anymore.
Version 2.2.0 -
-adb included, no SDK needed
-abort if cannot find adb
-remove alternate busybox at /system/xbin and /system/bin when unrooting
-remove alternate busybox at /system/xbin when rooting and installing busybox at /system/bin
-No more hang in exploit...I hope
-Clean up code
Version 2.2.1 - minor revision to code (curl related)
DarkOnion's DoRootv3
Version 3.0 - set-up menu's, added error checking, will detect which OS you are on
Version 3.1 - fixed issues with ADB SDK User interfaces
Version 3.2 - adapted to DoRoot 2.2.1
Version 3.3 - edited code for easier understanding and modifications
=====
=====
References:
Original procedure produced by Sebastian Krahmer
http://forum.xda-developers.com/showpost.php?p=7838000&postcount=1
Tutorial/How-to Root Droid 2 on Windows by DarkOnion
http://forum.xda-developers.com/showpost.php?p=7865824&postcount=164
Tutorial/How-to Root Droid 2 on Linux/Mac by DarkOnion
http://forum.xda-developers.com/showpost.php?p=8103311&postcount=340
====
====
Appreciate my work and/or help, feel free to send donations my way! Poor college student here who just got a speeding ticket! Doh!
This is outdated information and should be used as a reference only! All updated versions have moved to POST #1.
Hi all. Made it to the front page of XDA Developers.
http://www.xda-developers.com/android/easy-rooting-method-for-droid-2/
I just want to make sure credit is given where due. First of all, the original procedure was produced Sebastian Krahmer. From there I wrote an indepth tutorial to root the Droid 2. I took a vague instruction set and help it grown into something that the average person could understand. Understanding the need to simplify the process, I decided to write scripts to further streamline the process. What started out as a 3 part script that involved 8 or 9 commands eventually became a two part script that involved 3 or 4 commands. I have no programming background, by the way. Having trouble getting the process down into one part, facelessuser volunteered to take my work, and put a bunch of neat things into it to get it to work as one thing with error checking! So, with that said, I'd like to thank everyone that had a part in the project, especially facelessuser for his dark magic arts that made the script run, matt4542 for constantly testing my various scripts, and everyone who directly or indirectly ran the scripts!
We are moving forward!
===
Hi all.
We (me), facelessuser, and a few others are working furiously to get an easy one step program out for you guys. In the mean-time, I have a pretty safe, and clean, and easy 2 step method for Windows, Mac, and Linux. I am still cleaning stuff up, but for the most part, it all runs well.
What you need:
Android-SDK for your operating system which can be found here:
http://developer.android.com/sdk/index.html
Motorola Drivers (if you are using Windows) which can be found here:
http://www.motorola.com/Support/US-...tware_and_Drivers/USB-and-PC-Charging-Drivers
And the files/scripts/programs to root for your OS:
Want to try the one step process, go down to post #2!
Windows [1.0]: http://www.kimete.com/droid/DORootforD2Windows.zip
Mac/Linux [1.0]: http://www.kimete.com/droid/DORootforD2Linux.zip
Instruction for Windows:
GO DOWN TO POST #2 AND DOWNLOAD THE ONE STEP
1. Extract and Update Android SDK package to your computer. The file comes in a zip file. Just open it up and drag and drop the android-sdk-windows folder to your C drive. Next, extract the files from the DORoot zip file to the tools folder of Android SDK. You should be moving 7 or 8 files into the tools folder.
2. Install Motorola Drivers
(Tip, to stop the launching of the Verizon/Motorola site, go to the MotoConnect icon in the bottom right, right click, when phone connects, nothing.)
3. Make sure you phone is in PC Mode with USB Debugging enabled
PC Mode: Notification blind -> USB connection -> PC Mode
USB Debugging: Settings -> Applications -> Development -> USB debugging
You need USB debugging icon showing in notifications. Try Charge Only if you can't get PC Mode to show USB debugging.
4. Double-click and run doroot1.bat
5. Follow the instructions. You will enter into the shell and be prompted with a $.
6. enter [./data/local/tmp/rageagainstthecage-arm5.bin] and let it run. Can take up to 15 minutes before it boots you out.
6a. To check if rageagainstthecage worked it's magic, enter the shell with adb shell. You should see a # sign. If you don't, you need to run rageagainstthecage again by entering the command from step six.
6b. If you see the #, exit the shell by typing exit.
7. After being booted from shell and back to DOS, enter or double click doroot2.bat
8. That's it, you are done.
Instruction for Linux and Mac:
GO DOWN TO POST #2 AND DOWNLOAD THE 1-STEP!
1. Extract and Update Android SDK package to your computer. The file comes in a .tar.gz file. Just open it up and drag and drop the android-sdk-linux folder to your home directory or desktop. Next, extract the files from the DORoot zip file to the tools folder of Android SDK. You should be moving 7 or 8 files into the tools folder.
2. Make sure you phone is in PC Mode with USB Debugging enabled
PC Mode: Notification blind -> USB connection -> PC Mode
USB Debugging: Settings -> Applications -> Development -> USB debugging
You need USB debugging icon showing in notifications. Try Charge Only if you can't get PC Mode to show USB debugging.
3. Navigate to the tools folder of your android-sdk
[cd /android-sdk-linux_x86/tools]
4. enter [chmod 0755 doroot1.sh] then run it [./doroot1.sh]
5. Follow the instructions. You will enter into the shell and be prompted with a $.
6. enter [./data/local/tmp/rageagainstthecage-arm5.bin] and let it run. Can take up to 15 minutes.
6a. To check if rageagainstthecage worked it's magic, enter the shell with adb shell. You should see a # sign. If you don't, you need to run rageagainstthe cage again by entering the command from step six.
6b. If you see the #, exit the shell by typing exit.
7. After being booted from shell and back to command prompt, [./doroot2.sh]
8. That's it, you are done.
Enjoy my works? Want to show your gratitude? Just want to help a poor college student out, donate via PayPal to: [email protected]. All donations are greatly appreciated. Money will be spent on escorts, food, adult beverages, higher education and its bs fees, paying off my phone, and the wonderful speeding ticket I got this week!
Hey Thanks alot for writing this! I just tried it out and ran until completion.
A few things I found.
In the dos prompt, part2 the program asks user to input a few commands. Commands 2 and 3 should end in .sh. The program dosent mention this.
Thanks again
Typo in the 3rd step. You forgot to add '.sh'.
lockdownx1x said:
Typo in the 3rd step. You forgot to add '.sh'.
Click to expand...
Click to collapse
Doh. Good catch y'all. I will take care of that now!
Problem
Everytime i type: $ ./doroot2.sh
i get:
./doroot2.sh
./doroot2.sh: not found
thank for the help!
The " ./ " before doroot.sh tells linux to look in the current directory for the file to run. Make sure you in the tools directory of the sdk and that the script is there as well.
Sent from my DROID2 using XDA App
Yep i definitaly made sure of that but same error. It doesnt matter though i have rooted my droid 2 through the manual proccess
NiteSite said:
Everytime i type: $ ./doroot2.sh
i get:
./doroot2.sh
./doroot2.sh: not found
thank for the help!
Click to expand...
Click to collapse
Did you do cd data/local/tmp in adb shell before doing the chmod and ./doroot2.sh?
Yeah the chmod doroot2.sh worked without a problem. ./doroot2.sh did not tried it several times though
Sent from my DROID2 using XDA App
NiteSite said:
Yeah the chmod doroot2.sh worked without a problem. ./doroot2.sh did not tried it several times though
Sent from my DROID2 using XDA App
Click to expand...
Click to collapse
Weird. I am going to send you a PM. Hit me up on Google Talk.
-Kevin
Should turn this in to a one click root app for D2. Couldn't you essentially do some modifications and run it from the phone?
mjones1052 said:
Should turn this in to a one click root app for D2. Couldn't you essentially do some modifications and run it from the phone?
Click to expand...
Click to collapse
I am working on it. Hahaha. I don't have any programming background. So I am learning on the fly, but progress is being made.
Though, I have to say that the process is much much much easier than what it originally began as. So... moving in the right direction.
I'm not much of a programmer. I'm on Windows. Do I need to chmod the files, and if so, how would I do that?
Kenny Strife said:
I'm not much of a programmer. I'm on Windows. Do I need to chmod the files, and if so, how would I do that?
Click to expand...
Click to collapse
Just follow the instructions. Launch the doroot1.bat file. The .bat file will launch you into ADB shell. chmod the doroot2.sh file, then run it. adb shell again. chmod the doroot3.sh file and run that. Hope that helps. I am on google talk if you need help.
I'm stuck on the second step. Attempting to contact you through Google Talk...
Thanks, by the way.
please help!
i rooted manually and when i try to open superuser permissions icon i get a black screen...should i follow your steps to root now and will that work ??
chrismouro said:
i rooted manually and when i try to open superuser permissions icon i get a black screen...should i follow your steps to root now and will that work ??
Click to expand...
Click to collapse
You are okay. Superuser lists the program you've allowed superuser access to. You haven't given any apps access, therefore blank!
Kenny Strife said:
I'm stuck on the second step. Attempting to contact you through Google Talk...
Thanks, by the way.
Click to expand...
Click to collapse
Kenny, did you get this resolved? I am experiencing the same issue.
I'm getting kicked the ./doroot2.sh: not found as well. Anyone get past this point?

[Q] Having trouble installing adb for Windows

Problem getting adb installed.
Installed the JDK.
Installed the Android SDK, revision 15.
Now I am stuck, not sure how to install ADB, don't know if it's done from within the SDK manager.
I've got a Rogers i727R. It's running 2.3.5. It's the stock ROM, rooted. I was figuring that I would have to tick the checkbox in Android SDK Manager for 2.3.5 and download those components, and that would give me everything I need.
But there is no 2.3.5. There is 2.2, and 2.3.3, and of course Android 4.
I do have drivers for my phone installed through Kies if that matters. Any pointers in the right direction would be appriciated.
Harry
Thanks goes to Silver<<<<<<
1- Like always enable your Debugging. you can enable that by going to your Settings -> Application -> Development
2- Install the android SDK . you can download it Android SDK
3- Extract the SDK to any folder, Example : C:\Android
4- Make sure you have the drivers installed- In that way your OS can talk to your phone!
now that everything is installed we can go ahead and perform a command :
1. Open the 'run' dialog by pressing the 'Windows' + 'r' buttons on your keyboard (minimize the browser & other non-windows programs) 2. cmd (this will open a DOS prompt) 3. cd c:\Android\tools (go to the directory where you extracted the SDK) 4. adb shell 5. Now you'll see just a '$' 6. logcat
You can now just press the power button on your phone to see what happens. It displays everything the device is doing.
So the thing is: leave your device connected for a while and see what is actually going on when you're not using it. Boom
__________________
OP,
Just install the 'Tools' listed there in the sdk downloader. you dont need to worry about anything else
It seems to also want me to install the Google USB Driver package. Any reason to do that?
harry_fine said:
It seems to also want me to install the Google USB Driver package. Any reason to do that?
Click to expand...
Click to collapse
just do it, it wont affect anything negatively
By the way, it worked great. I can now talk to my phone using the emulator on my PC. I see the list of adb commands, lots of stuff. Seems I can even install apk files, run a remove shell. Very cool.
Lol good luck

[Tool] WhatsApp Key/DB Extractor | CRYPT6-12 | NON-ROOT | UPDATED OCTOBER 2016

** Version 4.7 Updated October 2016 - Supports Android 4.0-7.0 **
SUMMARY:
Allows WhatsApp users to extract their cipher key and databases on non-rooted Android devices.
UPDATE: This tool was last updated on October 12th 2016. and confirmed working on Android 4.0-7.0 using WhatsApp version v2.16.304 (latest available).
IMPORTANT: If you wish to extract media files or WhatsApp databases from Google Drive backups then you need: WhatsApp Google Drive Extractor instead.
TUTORIAL:
BRANCH UPDATES:
v4.0 - Fixed issues with Android API 14-17 (4.0-4.2 Jelly Bean).
v4.1 - Added support for Android API 23 (6.0-6.0.1 Marshmallow).
v4.2 - Added support for specifying adb backup passwords.
v4.3 - Added PowerShell version as optional alternative to bat version.
v4.4 - Changed primary mirror for legacy apk.
v4.5 - Fixed issue pushing cipher key to emulated storage.
v4.6 - Updated primary mirror for legacy apk (again).
v4.7 - Added new sanity checks and support for Android API 24 (7.0 Nougat).
PREREQUISITES:
O/S: Windows Vista, Windows 7, Windows 8, Windows 10, Mac OS X or Linux
Java - If not installed: Download Java
ADB (Android Debug Bridge) Drivers
USB Debugging* must be enabled on the target device. Settings -> Developer Options -> (Debugging) USB debugging
Android device with Android 4.0 or higher. I.E. Ice Cream Sandwich, Jelly Bean, KitKat, Lollipop, Marshmallow or Nougat.
*= If you cannot find Developer Options then please go to: Settings -> About phone/device and tap the Build number multiple times.
INSTRUCTIONS:
Extract WhatsApp-Key-DB-Extractor-master.zip maintaining the directory structure.
Click on WhatsAppKeyDBExtract.bat (Windows) or WhatsAppKeyDBExtract.sh (Mac OS X / Linux).
Connect your device via USB, unlock your screen and wait for Full backup to appear.
Enter your backup password or leave blank (if none set) and tap on Back up my data.
Confirm backup password in your command console and then check the "extracted" folder.
TROUBLESHOOTING:
If you have never used USB Debugging before, you may also need to verify the fingerprint.
If you have set a default backup password in your Android settings, then this MUST be the
backup password that you provide when prompted to backup your data. Else it WILL fail!
Linux and Mac OS X users may need to set the script permissions as executable. Depending on the
adb permissions, you may also need to sudo ./WhatsAppKeyDBExtract.sh from your command console.
If you're having issues with WhatsAppKeyDBExtract.bat then right click WhatsAppKeyDBExtract.ps1
and select Run with PowerShell. You may have to enter "y" at first run for script execution policy.
If you get an error saying "AES encryption not allowed" then you need to update your Oracle Java
Cryptography Extension (JCE) to Unlimited Strength Jurisdiction Policy Files.
DOWNLOAD: WhatsApp-Key-DB-Extractor-master.zip
AUTHOR: TripCode
THANKS: dragomerlin for Android Backup Extractor and Abinash Bishoyi for being cool.
alternatives
Yes, this is a normal backup method. There are automatic tools that do the same without using PC, just on device side.
Apart from normal ADB method, you could use ECLIPSE for that, using the memory module, you could transfer files from and in.
If you have physical access to the device, there are many solutions.
regards.
droopyar said:
Yes, this is a normal backup method. There are automatic tools that do the same without using PC, just on device side.
Apart from normal ADB method, you could use ECLIPSE for that, using the memory module, you could transfer files from and in.
If you have physical access to the device, there are many solutions.
regards.
Click to expand...
Click to collapse
The only way to access private application files (such as a WhatsApp's cipher key) without root is the ADB method. You can backup some files on the device without a PC (APK's etc...), but there is currently no way to access private files and folders. All the "My Big Fat Backup" style apps and tools will either require root or ADB. Eclipse also utilizes ADB. Basically, device side backups of application data require root. There are no other alternatives to this. If there was, then Android would be too infeasible and insecure as a viable operating system. Physical access translates into only two solutions. 1.) The ability to root and 2.) The ability to utilize ADB (Eclipse, Bats, Exe's doing nothing more than calling a simple command line). Of course if you are aware of a 3rd method (disregarding the user interface) and is not based on root or ADB then please feel free to share.
Thanks for this tool!
I've just tried to use it, but it installs the java constantly (while java is properly installed on computer as other applications uses it without any problem )
By any chance, do you have any idea how to pass that?
Thanks!!
Mia
PS I got JDK installed and still not working
MiaNet said:
I've just tried to use it, but it installs the java constantly (while java is properly installed on computer as other applications uses it without any problem )
By any chance, do you have any idea how to pass that?
Click to expand...
Click to collapse
The bat file automatically checks for the presence of java.exe on your system. If it's not found then it starts the install. It would appear that for some reason it's not finding Java and hence why you're stuck in this loop. Please find attached a bat file without the Java check. Just put it in the same folder as the original and run this one instead. Let me know how you get on. Java also needs to be callable from the command line. To check this is working you should click on Run... within Windows, type cmd, click OK and type "java -version" (without quotes) and press Enter. This will confirm java is in the command path and print out your JRE build number. I have also updated the release in the OP and removed the Java check, as I have had a couple of similar reports of the loop issue.
Thanks again.
still showing this message attached
TripCode said:
The bat file automatically checks for the presence of java.exe on your system. If it's not found then it starts the install. It would appear that for some reason it's not finding Java and hence why you're stuck in this loop. Please find attached a bat file without the Java check. Just put it in the same folder as the original and run this one instead. Let me know how you get on. Java also needs to be callable from the command line. To check this is working you should click on Run... within Windows, type cmd, click OK and type "java -version" (without quotes) and press Enter. This will confirm java is in the command path and print out your JRE build number. I have also updated the release in the OP and removed the Java check, as I have had a couple of similar reports of the loop issue.
Thanks again.
Click to expand...
Click to collapse
Still showing the attached message
mesho_alaa said:
Still showing the attached message
Click to expand...
Click to collapse
This sounds to me like you need to update your PATH Environment variable with the directory in which java is installed.
Open up a DOS window and type: "where java" (without quotes) to determine possible locations.
If it's located in: "C:\Windows\System32" then the following code should suffice:
Code:
set PATH=%PATH%;C:\Windows\System32
If it's located in: "C:\Program Files\Java\jre7\bin" then:
Code:
set PATH=%PATH%;C:\Program Files\Java\jre7\bin
The above needs to be added to the bat script BEFORE Java is called. You can edit the bat script by opening it with Notepad.
Alternatively, you could permanently update the PATH Environment (probably a better method).
To do this you would: Right click on "Computer" or "My Computer", within Windows Explorer, choose "Properties", click on the "Advanced system settings" and/or the "Advanced" tab, then click on the "Environment Variables" button. Select the "PATH" line, click the "Edit" button, and add the relevant directory to the end of any text that exists for PATH, prefixing the java path with a ";" (semicolon) if this line already contains other string paths. If PATH does not exist then you will need to add it. Sorry this paragraph is a little double-dutch (trying to cater for multiple versions of Windows).
Many thanks! I'll test when home and let you know.
Just to let know, the path command do not fix the prior version with Java check as I first thought this might be the problem.
Thanks!
Mia
Could even be use with ADB from phone to phone? without using the pc? Or I must install the app on the phone and do it offline?
I have find my way! Re-installed Java, manually clicked on java.exe stored in Java folder in Program files (or Program files (x86) ) I've clicked on Javacpl as well and enabled all options, not sure if this is necessary though.
I've then rerun the program without Java check (the Java check one is bugging now) and was able to do the back up.
Thanks!!
Best regards,
Melanie
Cannot tap button
Hi! i've done all the previous steps, but when i unlock the phone, to confirm the backup, i cant tap on "back up my data", it doesnt even grey at hover, just like the button wasn't there...
I can choose not to backup, that button works perfectly, and write the password too, i've tried all the screen, but nothing happends, so i can't backup the phone...
Does anyone think how to solve that? Thanks!
Permission denied
Hi, I followed all instructions and I generated this error.
I would appreciate your help.
Error
mesho_alaa said:
Still showing the attached message
Click to expand...
Click to collapse
I, too am showing the same error.
Curwens said:
Hi! i've done all the previous steps, but when i unlock the phone, to confirm the backup, i cant tap on "back up my data", it doesnt even grey at hover, just like the button wasn't there...
I can choose not to backup, that button works perfectly, and write the password too, i've tried all the screen, but nothing happends, so i can't backup the phone...
Does anyone think how to solve that? Thanks!
Click to expand...
Click to collapse
Try rebooting the device and trying again. If it is still greyed out, the backup feature maybe disabled on the device. Some manufacturers / service providers have specifically disabled usb backups.
kharloz_jc said:
Hi, I followed all instructions and I generated this error.
I would appreciate your help.
Click to expand...
Click to collapse
cardinalaa said:
I, too am showing the same error.
Click to expand...
Click to collapse
It would appear that the key was extracted, but the "copy" wasn't pushed to the sdcard. KitKat? You don't need a copy of the key on your sdcard unless you want to use a supported app. As the key was extracted successfully, you could attempt to copy it by other means.
TripCode said:
This sounds to me like you need to update your PATH Environment variable with the directory in which java is installed.
Open up a DOS window and type: "where java" (without quotes) to determine possible locations.
If it's located in: "C:\Windows\System32" then the following code should suffice:
Code:
set PATH=%PATH%;C:\Windows\System32
If it's located in: "C:\Program Files\Java\jre7\bin" then:
Code:
set PATH=%PATH%;C:\Program Files\Java\jre7\bin
The above needs to be added to the bat script BEFORE Java is called. You can edit the bat script by opening it with Notepad.
Alternatively, you could permanently update the PATH Environment (probably a better method).
To do this you would: Right click on "Computer" or "My Computer", within Windows Explorer, choose "Properties", click on the "Advanced system settings" and/or the "Advanced" tab, then click on the "Environment Variables" button. Select the "PATH" line, click the "Edit" button, and add the relevant directory to the end of any text that exists for PATH, prefixing the java path with a ";" (semicolon) if this line already contains other string paths. If PATH does not exist then you will need to add it. Sorry this paragraph is a little double-dutch (trying to cater for multiple versions of Windows).
Click to expand...
Click to collapse
Hi, I am receiving the "Cannot find the path specified" error. I have tried both changing the script and also the other method, in environment variables. I am curious if this has anything to do with the fact that its an ATT phone (since no one can even root it yet)? No other apps can access my phone, either. I have USB debugging enabled and all prerequisite programs installed. Tried on 2 computers, win7 and win 8.1
I wonder if i it is an error on my part..?
TripCode said:
Try rebooting the device and trying again. If it is still greyed out, the backup feature maybe disabled on the device. Some manufacturers / service providers have specifically disabled usb backups.
It would appear that the key was extracted, but the "copy" wasn't pushed to the sdcard. KitKat? You don't need a copy of the key on your sdcard unless you want to use a supported app. As the key was extracted successfully, you could attempt to copy it by other means.
Click to expand...
Click to collapse
I have reviewed the "Extract" folder and there was the key. I have managed to decrypt it.
Thanks for the help and the tool!
PD: sorry for my bad English, I use translator is haha.
Nothing happens
Hi, first, thanks for this iniciative. A lot of people would apreciate this
I think I did everything as u said, but when I open the WhatsAppKeyExtract,bat and then conect my phone in debuggin mode to PC, nothing happens. Ive waited for 10 minutes and.. nothing happens. Keep showing the initial message: "Please connect your Android device..." and in my phone nothing happens too. Just show a messagem at the upper tab saying: "USB debbugin conected".
Theres any kind of setting to do futher in the debbug options?
Thanks
Update: I had do install de universal adb driver for my phone, and now it starts the download, but now im having problem with java... the messagem says "'java' isnt a recognizable command". I tried all solutions in this post and nothing.. I need heeeelp!
Solution to path problem
Is working perfect. For someone else that can happen the same thing as me. I have to fix something (i am spanish) about:
java is not recognized as an internal or external command, operable program or batch file
Here is the solution:
java .com/en/download/help/path.xml
Or here:
1. Right-Click My Computer and select Properties
2. Then Click The Advanced Tab
3. Then Click Environment Variables
4. Select Path In The Bottom Box and Click Edit
5. Find Where You installed Java (E.g "C:\Program Files\Java\bin)
Its different on each computer
6. Make Sure to add a semicolon after the word bin in the path to seperate it from the other important paths
7. If this doesnt work then you may have to reinstall Java and Try Again
Setting Path on Windows
For Windows XP:
1. Start -> Control Panel -> System -> Advanced
2. Click on Environment Variables, under System Variables, find PATH, and click on it.
3. In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
4. Close the window.
5. Reopen Command prompt window, and run your java code.
https://www.dropbox.com/s/nm1goi6m0oob15u/Screenshot 2014-06-15 22.25.27.png
I am getting this error.
using java run time 7 update 60
any ideas?
Thanks!
tzuyang said:
https://www.dropbox.com/s/nm1goi6m0oob15u/Screenshot 2014-06-15 22.25.27.png
I am getting this error.
using java run time 7 update 60
any ideas?
Thanks!
Click to expand...
Click to collapse
Have seen this error before (not related to bat file). You may need to revert to an earlier Java version.

How To Guide How to extract boot.img from OnePlus 9 firmware packages to patch with Magisk & flash to your phone using Linux Mint 21.1

As a OnePlus 9 user who likes to root their phone mainly to allow Network Signal Guru to work (as well as a few other root things like AdAway) I had been trying to extract the boot.img the same way as I had done with a OnePlus 7T using Payload Dumper for Windows. However it looks like Payload Dumper has issues with extracting xx.img files (including boot.img) if the payload.bin file is bigger than 4.3 GB in size. So I've been looking to see if another method was possible that would work for our OnePlus 9 ROMs that are above this file size. As I use Linux Mint as my usual desktop OS & only fall back onto Windows for stuff that'll only run on that OS, I went to have a look to see if something could be done under Linux. Turns out there is an old thread elsewhere on XDA that almost nearly provides what is needed for this, and I thought I would gives details here that should work for the time of this post (March 2023).
This not only extracts the boot.img to patch in Magisk, but also extracts other xx.img files as well.
I'm using Linux Mint 21.1, but I'd assume that this will also work for similar Ubuntu builds or anything that is based on Debian.
Obligatory disclaimer: The following instructions I'm giving below have worked well for me several times in the past, however I am in no way responsible for screwing up or damaging your phone if you try and follow what I've written below. In extreme cases, a bad flash may require using the OnePlus MSM tool to completely reflash your phone. Back up anything important first before doing any of the following!​
1. You will need to ensure that you have downloaded packages to be able to do adb & fastboot from the command line. You can check by running the following commands - if it's already installed with the latest versions, the terminal interface will let you know...
Code:
sudo apt install adb
Code:
sudo apt install fastboot
2. You will need to go to your software manager in LM21.1 and install both Python 3 & the Python Protobuf compiler. Just search for "Python 3" & "Protobuf-compiler" in the software manager and the first option for each search is what you should need - if they are not installed, install them.
3. Create a read/writable directory that will hold your ROM that you've just downloaded & other files that I'll mention soon. I just use a folder calls "ROM" in my Downloads folder (e.g. /home/lawhec/Downloads/ROM ), but you can choose wherever you want that suits you.
4. If you have not done so already, make sure you have the FULL package of your OnePlus 9 ROM downloaded. As of right now (March 2023) it seems the best way is to download the package using the Oxygen Updater app which is available on Google Play - more info available at oxygenupdater.com - just download the ROM to your phone and transfer it on to your computer into the folder you've created for it.
5. Download and save the following two Python scripts/files ("Right click" & "Save Link As") into the folder you have just created for your ROM (all credit to Gregory Cyxx at github.com/cyxx )...
https://raw.githubusercontent.com/c...payload/master/extract_android_ota_payload.py
https://raw.githubusercontent.com/cyxx/extract_android_ota_payload/master/update_metadata_pb2.py
6. Make sure in your file browser (Nemo in my case as it is the default for LM21.1 Cinammon, yours may differ) the window is open in the ROM folder that contains the two Python scripts above that you've just downloaded as well as a ROM package (ZIP file) you've downloaded (in my case from Oxygen Updater mentioned in step 3). Create a new folder for the extracted images to be written to - in my case I just call the folder "output" which is located at "/home/lawhec/Downloads/ROM/output" but again you can call it what you wish.
7. After you've created your output folder, in your ROM directory in the file manager window right-click on your mouse in a white or free space and select "Open in Terminal" - a command terminal will pop up defaulting to your directory.
8. In the command terminal, type the following command and press enter/return...
Code:
sudo python3 extract_android_ota_payload.py <<Your ROM.zip>> <<Your Output Directory>>
...for example, in my case the command would be either...
Code:
sudo python3 extract_android_ota_payload.py LE2113_11_F-75.zip output
...or for handiness you can type "sudo python3 extract_android_ota_payload.py " (remember to leave a space) and simply drag the ROM zip file to the command terminal, press space and then drag the output foler to the terminal line, which will look like in my case...
Code:
sudo python3 extract_android_ota_payload.py '/home/lawhec/Downloads/ROM/LE2113_11_F-75.zip' '/home/lawhec/Downloads/ROM/output'
...this will now run the python script you downloaded earlier that will begin extracting the ROM you've specified and will output all relevant xx.img files into your output folder, including the one we want, "boot.img" - there is no need to extract paylod.bin beforehand, the script will automatically do this for you. Once all xx.img files have been extracted the script will stop, depending on your computer this will take anything from 1-5 minutes, maybe longer on some very old or low spec'd computers - but just let it run its course. Once it is done you can then close the terminal window.
9. Now with the boot.img we've extracted, transfer this file on to your phone (the Downloads folder is usually a good choice). Now open Magisk and patch the boot.img file - once this has been completed, it'll generate a patched boot.img file named something like "magisk_patched-25200_12345.img" - copy and paste this patched boot image back on to your computer (into the folder you've been using will be fine here).
10. If your OnePlus 9 phone is connected to your computer via USB cable, disconnect it now. Then shutdown your phone into a power-off state then reboot it into fastboot mode - this can be done by holding down the volume up & down buttons, then holding down the power button and keep holding down all three buttons until you feel a vibration from your phone. Your OnePlus 9 should then boot into fastboot mode.
11. Now reconnect your OnePlus 9 to your computer via the USB cable and then open up a new display terminal (preferably by right-clicking in the file window of the directory where you saved your Magisk patched boot.img file). Enter the following...
Code:
fastboot devices
...you should then get a line featuring a block of numbers that should match the serial number that is displayed on your phone's display, followed by "fastboot", for example...
Code:
85f53405 fastboot
...if you get anything else, double check your connections at try again - if more than one device is displayed, disconnect the and try again to make sure that only one device is listed. It might also be the case that you don't have the proper drivers installed on your computer for your phone though in my case LM21.1 automatically recognises my phone, so I'm not of any direct help here I'm afraid for this, sorry.
12. Now you will be flashing your patched boot.img to your phone - this is where things can be a little nervous though as long as you do everything right nothing should really go wrong. Type the following into the command terminal, assuming you did so by opening a command terminal from the folder your Magisk Patched boot.img file is located...
Code:
fastboot flash boot <<Magisk Patched boot.img>>
...for example in my case the command line would be...
Code:
fastboot flash boot magisk_patched-25200_12345.img
...otherwise you will need to provide the location of where your patched boot.img is, so in this case...
Code:
fastboot flash boot '/home/lawhec/Downloads/ROM/magisk_patched-25200_12345.img'
...either way, your phone will now be in the process of getting its boot image replaced with the one patched by Magisk. This should take no more than a few seconds and that should be it done! You can then close the terminal window again.
13. Once you've patched the boot image, disconnect the phone from the USB cable to the computer and make sure that the screen on your mobile says "START" in green at the top, if it doesn't, use the volume keys to change this. Then just simply press the power button and your phone will now reboot, this can take a little bit longer than before as your phone's firmware has changed so give it time - (however if it takes longer than 10 minutes or so you might have a problem here) - once your home screen becomes available, give it a few seconds once you've entered before selecting the Magisk app. Once you've done this, Magisk should say that it is installed however to double check, use an app that requires root permissions either to work (e.g. Network Signal Guru) or to do additional things, like a simple root checker app that you can download from wherever you download your apps. If everything is good, then you've rooted your OnePlus 9!
Notes: This process will probably work for other firmware packages for various phones where the boot.img can be extracted to be patched by Magisk and then flashed via fastboot (assuming the bootloader is unlocked) which includes the OnePlus 7T's stock firmware, but I can give no guarantees for this. Once again, try at your own risk.​
I would suggest to boot the magisk patched image and then doing a direct install from the app instead of flashing it directly. This way you can use the "Restore images" feature in the Magisk app that can be useful when doing incremental update.
Thank You for thinking of Us Linux Users !
Attempted to update to LOS 20 via ADB, and now my touch screen will not work. All the remedies here require a Windows system for the MSM tool, which I do not have...
barguybrady said:
Thank You for thinking of Us Linux Users !
Attempted to update to LOS 20 via ADB, and now my touch screen will not work. All the remedies here require a Windows system for the MSM tool, which I do not have...
Click to expand...
Click to collapse
You have a computer you can install windows on another partition it's not like you don't have the ability to use msm
stez827 said:
You have a computer you can install windows on another partition it's not like you don't have the ability to use msm
Click to expand...
Click to collapse
no comment
barguybrady said:
Yup.
Just gonna spend another 4 or 5 hours prepping a drive to somehow install windows just to fix a phone.
Maybe - No....
Click to expand...
Click to collapse
It does not take that long as a Linux user who has had to install for that exact reason it took maybe an hour or 2
lawhec said:
As a OnePlus 9 user who likes to root their phone mainly to allow Network Signal Guru to work (as well as a few other root things like AdAway) I had been trying to extract the boot.img the same way as I had done with a OnePlus 7T using Payload Dumper for Windows. However it looks like Payload Dumper has issues with extracting xx.img files (including boot.img) if the payload.bin file is bigger than 4.3 GB in size. So I've been looking to see if another method was possible that would work for our OnePlus 9 ROMs that are above this file size. As I use Linux Mint as my usual desktop OS & only fall back onto Windows for stuff that'll only run on that OS, I went to have a look to see if something could be done under Linux. Turns out there is an old thread elsewhere on XDA that almost nearly provides what is needed for this, and I thought I would gives details here that should work for the time of this post (March 2023).
This not only extracts the boot.img to patch in Magisk, but also extracts other xx.img files as well.
I'm using Linux Mint 21.1, but I'd assume that this will also work for similar Ubuntu builds or anything that is based on Debian.
Obligatory disclaimer: The following instructions I'm giving below have worked well for me several times in the past, however I am in no way responsible for screwing up or damaging your phone if you try and follow what I've written below. In extreme cases, a bad flash may require using the OnePlus MSM tool to completely reflash your phone. Back up anything important first before doing any of the following!​
1. You will need to ensure that you have downloaded packages to be able to do adb & fastboot from the command line. You can check by running the following commands - if it's already installed with the latest versions, the terminal interface will let you know...
Code:
sudo apt install adb
Code:
sudo apt install fastboot
2. You will need to go to your software manager in LM21.1 and install both Python 3 & the Python Protobuf compiler. Just search for "Python 3" & "Protobuf-compiler" in the software manager and the first option for each search is what you should need - if they are not installed, install them.
3. Create a read/writable directory that will hold your ROM that you've just downloaded & other files that I'll mention soon. I just use a folder calls "ROM" in my Downloads folder (e.g. /home/lawhec/Downloads/ROM ), but you can choose wherever you want that suits you.
4. If you have not done so already, make sure you have the FULL package of your OnePlus 9 ROM downloaded. As of right now (March 2023) it seems the best way is to download the package using the Oxygen Updater app which is available on Google Play - more info available at oxygenupdater.com - just download the ROM to your phone and transfer it on to your computer into the folder you've created for it.
5. Download and save the following two Python scripts/files ("Right click" & "Save Link As") into the folder you have just created for your ROM (all credit to Gregory Cyxx at github.com/cyxx )...
https://raw.githubusercontent.com/c...payload/master/extract_android_ota_payload.py
https://raw.githubusercontent.com/cyxx/extract_android_ota_payload/master/update_metadata_pb2.py
6. Make sure in your file browser (Nemo in my case as it is the default for LM21.1 Cinammon, yours may differ) the window is open in the ROM folder that contains the two Python scripts above that you've just downloaded as well as a ROM package (ZIP file) you've downloaded (in my case from Oxygen Updater mentioned in step 3). Create a new folder for the extracted images to be written to - in my case I just call the folder "output" which is located at "/home/lawhec/Downloads/ROM/output" but again you can call it what you wish.
7. After you've created your output folder, in your ROM directory in the file manager window right-click on your mouse in a white or free space and select "Open in Terminal" - a command terminal will pop up defaulting to your directory.
8. In the command terminal, type the following command and press enter/return...
Code:
sudo python3 extract_android_ota_payload.py <<Your ROM.zip>> <<Your Output Directory>>
...for example, in my case the command would be either...
Code:
sudo python3 extract_android_ota_payload.py LE2113_11_F-75.zip output
...or for handiness you can type "sudo python3 extract_android_ota_payload.py " (remember to leave a space) and simply drag the ROM zip file to the command terminal, press space and then drag the output foler to the terminal line, which will look like in my case...
Code:
sudo python3 extract_android_ota_payload.py '/home/lawhec/Downloads/ROM/LE2113_11_F-75.zip' '/home/lawhec/Downloads/ROM/output'
...this will now run the python script you downloaded earlier that will begin extracting the ROM you've specified and will output all relevant xx.img files into your output folder, including the one we want, "boot.img" - there is no need to extract paylod.bin beforehand, the script will automatically do this for you. Once all xx.img files have been extracted the script will stop, depending on your computer this will take anything from 1-5 minutes, maybe longer on some very old or low spec'd computers - but just let it run its course. Once it is done you can then close the terminal window.
9. Now with the boot.img we've extracted, transfer this file on to your phone (the Downloads folder is usually a good choice). Now open Magisk and patch the boot.img file - once this has been completed, it'll generate a patched boot.img file named something like "magisk_patched-25200_12345.img" - copy and paste this patched boot image back on to your computer (into the folder you've been using will be fine here).
10. If your OnePlus 9 phone is connected to your computer via USB cable, disconnect it now. Then shutdown your phone into a power-off state then reboot it into fastboot mode - this can be done by holding down the volume up & down buttons, then holding down the power button and keep holding down all three buttons until you feel a vibration from your phone. Your OnePlus 9 should then boot into fastboot mode.
11. Now reconnect your OnePlus 9 to your computer via the USB cable and then open up a new display terminal (preferably by right-clicking in the file window of the directory where you saved your Magisk patched boot.img file). Enter the following...
Code:
fastboot devices
...you should then get a line featuring a block of numbers that should match the serial number that is displayed on your phone's display, followed by "fastboot", for example...
Code:
85f53405 fastboot
...if you get anything else, double check your connections at try again - if more than one device is displayed, disconnect the and try again to make sure that only one device is listed. It might also be the case that you don't have the proper drivers installed on your computer for your phone though in my case LM21.1 automatically recognises my phone, so I'm not of any direct help here I'm afraid for this, sorry.
12. Now you will be flashing your patched boot.img to your phone - this is where things can be a little nervous though as long as you do everything right nothing should really go wrong. Type the following into the command terminal, assuming you did so by opening a command terminal from the folder your Magisk Patched boot.img file is located...
Code:
fastboot flash boot <<Magisk Patched boot.img>>
...for example in my case the command line would be...
Code:
fastboot flash boot magisk_patched-25200_12345.img
...otherwise you will need to provide the location of where your patched boot.img is, so in this case...
Code:
fastboot flash boot '/home/lawhec/Downloads/ROM/magisk_patched-25200_12345.img'
...either way, your phone will now be in the process of getting its boot image replaced with the one patched by Magisk. This should take no more than a few seconds and that should be it done! You can then close the terminal window again.
13. Once you've patched the boot image, disconnect the phone from the USB cable to the computer and make sure that the screen on your mobile says "START" in green at the top, if it doesn't, use the volume keys to change this. Then just simply press the power button and your phone will now reboot, this can take a little bit longer than before as your phone's firmware has changed so give it time - (however if it takes longer than 10 minutes or so you might have a problem here) - once your home screen becomes available, give it a few seconds once you've entered before selecting the Magisk app. Once you've done this, Magisk should say that it is installed however to double check, use an app that requires root permissions either to work (e.g. Network Signal Guru) or to do additional things, like a simple root checker app that you can download from wherever you download your apps. If everything is good, then you've rooted your OnePlus 9!
Notes: This process will probably work for other firmware packages for various phones where the boot.img can be extracted to be patched by Magisk and then flashed via fastboot (assuming the bootloader is unlocked) which includes the OnePlus 7T's stock firmware, but I can give no guarantees for this. Once again, try at your own risk.​
Click to expand...
Click to collapse
If Using the t-Mobile Variant - LE2117 - we are Unable to Install any OTA Updates with OxygenUpdater, and are promptly warned of this limitation upon install. Nevertheless, I forged ahead and,
Following this Method, I downloaded a LE2115_11_F.17.zip, and proceeded to use your helpful .py scripts to extract the boot.img file, and Flash it - promptly sending me to a Qualcomm CrashDump mode.
Having a chance to MSM back to "stock" LE2117 - 11.2.2.2 LE54CB, I am wondering if I should just let the t-Mobile Update, through "Settings >> System >> System update" to Update the Stock ( bloated !? ) OS with all that are available,
Then attempt to Extract a boot.img and Magisk patch it ?
Any Advice?
TIA

Guide to Rooting the Infinix Hot 30 Play, With Magisk

Preface​Luckily, it looks like Infinix is following the general trend of Android root solutions being more straightforward than in the recent past. Besides the usual spiel about your warranty being voided, and the annoying chirp each time you boot your phone, this hopefully won't present any problems for you if you do end up rooting your phone.
Notices​
Still, I'm not responsible for anything bad that will happen to your phone if you do this, and there's no support guaranteed either from me or your OEM/support centre.
There's quite a few steps to this, and naturally you're gonna need a few more things to setup before you even start.
Your phone's data will be reset, please backup everything you'd like to keep before rooting your phone (now and in general).
You do need to know some things already, mainly what ADB and Fastboot are, and how to keep your working environment clean and straightforward.
Please do review all the tools you're working with, be sure that you personally trust all the software you're running.
And last but not least, you won't be able to update your phone through OTA updates anymore unless you go back to stock firmware.
The process​
Make an environment for easy access:
Setup ADB and Fastboot (either as a local executable or a global environment variable to that executable).
Setup an easy to access directory with the Google Fastboot driver in it.
Grab your firmware's boot.img file, or grab the one attached to this post, or from here (and skip to the preliminary work section):
1. Download your phone's current ROM.
2. Extract it, as it should be a simple .zip file.
3. Look for the file of the same name (boot.img).
4. Copy it to your phone's storage, anywhere works.
Install the Magisk APK (from their Github).
Once it's installed, Magisk's app frontend allows you to patch your stock boot.img with itself, the gist of it is:
Click on Install within the app, in the "Magisk" section of the main menu.
Click "Select and patch a file", a file selection menu will show up, select the stock boot.img, then start the installation.
Magisk should spit out a patched boot.img named in the format of magisk_patched_[random_strings].img, in your phone's /sdcard/Download/ directory.
Copy that back into our working directory, and rename it to magisk_patched.img for easier usage.
Now, let's do some preliminary work, in any order, really:
Have Powershell or CMD open in the directory of all your tools, alongside the patched image.
Click to expand...
Click to collapse
From here on out, if you have to use adb as a command, and it's not a global environment variable, use ./adb while in the working directory instead, the same goes for fastboot.
Click to expand...
Click to collapse
Make sure that the adb daemon (adbd) is properly detecting your phone:
Enable developer options.
Enable ADB debugging.
Run adb devices to start the server daemon for ADB, and see if ADB detects your phone.
Authorize your PC for ADB debugging if it prompts you to.
Click to expand...
Click to collapse
Infinix's implementation of Fastboot will exit back out of itself and into normal boot after 60 seconds of inactivity, which makes this a tad annoying, although you can simply send it any input to reset that timer.
Click to expand...
Click to collapse
Let's start:
Restart the phone into Fastboot, adb reboot bootloader loader, it'll take a second, the phone is slow.
Unlock flashing 3rd party software, fastboot flashing unlock, the phone will prompt you on the screen to confirm doing this. Yes, this will void your warranty.
Flash magisk_patched.img to both A and B virtual partitions, fastboot flash boot_a magisk_patched.img and then fastboot flash boot_b magisk_patched.img.
That should be it! fastboot reboot to boot normally!
Be sure to also run the Magisk app so it finishes setting itself up, with another reboot, naturally.
Technicalities​The Infinix Hot 30 Play does have a dedicated vbmeta partition, it's advised that you also flash it alongside flashing the patched boot.img for Verified Boot, but that's not necessary if you don't want to tinker with your super partition's crypto keys.
Thank yous​- topjohnwu for their work on Magisk.
- ansh_/ and their post/guide on rooting the Infinix Hot 11, that I used originally.
Addendum​
Using fastboot with MediaTek SoCs will be a bit of a pain as their driver availibilty is limited, if it doesn't get installed by Windows automatically, you have a few options:
Grab the Google's Pixel driver, and install it in realtime during fastboot.
Try to install the VCOM driver from a source you trust.
For grabbing the Google one, you'll have to:
Extract the driver somewhere easy to access.
Open Windows' Device Manager.
Plug in your phone during fastboot to your Windows PC.
Replace the "Unknown" entry for your phone with the Google driver in device manager, within the 60 second window it stays open in.
Note that you'll have to do this every time you go into fastboot.

Categories

Resources