How to root a device like this? - Android Software/Hacking General [Developers Only]

A friend of mine bought an Alcatel OT895, which is a not so famous phone, and I don't know how can I root it, is it even possible?
And if rooting is possible, can I install a custom ROM (especially CM7.2) on it? I couldn't find anything useful anywhere.

Someone has to find out what hardware it has and what Android version it has. If you have the technical inclination, you could:
* Connect the phone via USB (with debugging enabled on the device) and access the internal filesystem via ADB (a tool from the Android SDK)
* Extract the relevant information, located in files named like 'build.prop', as well read /proc/cpuinfo
But even without those info (they just help in getting to know the hardware), you could jump straight into running an exploit to see if it works. If the Android version the vendor shipped with the device still has the particular vulnerability, the exploit will work.
Else, you need to extract the boot image and edit files, then repack and flash it. This is only possible if you have access to a safe flashing environment, i.e. custom recovery, so that you can first back up the partition.
There may be other ways, but that depends a lot on who else has posted information related to your device on the Internet or elsewhere.

Thanks, but I'm too noob for this, so I rather leave it on stock.

Related

[Q] 100% Original Stock ROM backup before root?

Hi there,
I am new to xda and new to Android hacking.
What I wanna ask is, (I guess it's of most newbies concern as well), can we have a 100% backup of our system (stock ROM)? Obviously, it is important because:
If we perform an official (OTA) update to a new Android version. And we don't like it. It is possible to get back to the old original one which we are used to. (not everybody likes new things, and/or not every new thing is good)
If our phones are having some problems. And we have to give it back to the company for a fix. In most cases they will flash a new ROM for us. If we wanna keep using the old one (explained in #1), we have to keep a copy of it by ourselves.
If we want to try new custom ROMs, we may want to switch it back after trying.
Whenever we do any modifications, it's always better to keep a backup/roll-back point. In case anything goes wrong, we have a safeguard.
For the official warranty issue.
Yup I do see there are some official stock ROMs downloads for some particular phones. But those are not really a backup of our original ROMs. And it's always hard to verify if those downloads are the original official releases. And, if those downloads are 100% stock ROMs, this means some guys out there could make it, so what is the way to do so?
Or, how those mobile phone companies do it in their labs?
I have been doing researches on this topic for a few days. Some posts claim that their methods are "backup stock ROM" or "backup before rooting". But after digging into it, they requires rooting and/or flashing CWM. Here comes a few questions:
Questions
Rooting will in fact changes some files/data of the system. So backup after root is NOT getting the original stock ROM. Is it?
Is there a method to "un-root", so ALL the changes are TOTALLY reverted?
Installing/flashing things like CWM in phone requires rooting, which would make the ROM not original. Is there a way to extract the system backup from a computer externally?
In addition, I have found some related pieces. which could be useful to anyone viewing this post, and might be useful for you to solve this (my) question. :fingers-crossed:
* as I'm a new user, I can't post links directly. Please delete the blank spaces in between.
ht tp://www .modaco .com/topic/351269-backup-original-rom/
In reply #5, user C3C0 raised a method of backing up the original stock ROM without root. But it seems he is flashing CWM and that method is only for ZTE Skate.
adb backup tool of Android SDK
At the first sight i came across this approach, I thought it is the official method to do whole system (ROM) backup (WOW - how nice!). But after studying for a few more posts, I think adb backup can only backup app+app_data, and possibly some system settings only. Am I correct? And also, adb backup is only for ICS (Android 4.0), isn't it?
adb backup usage: ht tp://forum.xda-developers .com/showthread.php?t=1420351
(But mentioned in the bottom of #1 the poster is having some issues on using adb backup. Perhaps there are some bugs and not reliable(?)
One more question on adb backup: Can it backup just one app+app_data, and restore just one app+app_data, without affecting other things? If yes, we don't need to root and don't need Titanium Backup (which requires root) for backup app+app_data. Isn't it?
** In case I have said anything or any terms wrongly in this thread, please DO correct me, for helping me and helping others.
P.S. i am using LG Optimus 3D.
Thanks a lot, wholeheartedly,
midnite_
Backup phone before root
Hello all this is my first post here...woohoo!:fingers-crossed: This forum is amazing as to the amount of information available. I just wish that in looking for what I need to do I did not need to look in so many places. I feel that if I want to root my T-Mobile GS3 that all the information should be in one subsection of the forum, but it is not that simple I guess....lol Anyway any help would be greatly appreciated.
I have a Samsung GS3 with T-Mobile that I want to root. Everyone says to back up the phone before you do it but I am not really seeing how to make a backup before I start. It appears that most of the guides to root just say to backup without telling you how to fo it. Another thing (correct me if I am wrong) I see the nandroid backup that I think is a backup of the phone however it seems to be done after you make changes to the phone and I thought the backup was supposed to be done before you do anything. Is it that there is not a way to make a complete backup with an unrooted phone?
My question is basically the same as the OP here. I have been reading and reading and reading posts here in the forum. There is much information here and much of it is duplicated with slight variances in some of the duplicates. I am not certain as to which rooting method I should use. There seem to be so many choices. As a new person to this forum I will say that you can find just about everything about any phone which is awesome. The hard thing is sifting through the many options to pick one to use for your issue.
I do see that Mr. Robinson has a thread with backups of the original roms. The only thing is that they are default roms that are like an out of the box phone and not my phone with my apps and my settings. That is what I want to backup...My phone with my settings and my apps.
:good: Thank you in advance for any one that can shed some light on this for me and the OP'er
ASharpEdge said:
Hello all this is my first post here...woohoo!:fingers-crossed: This forum is amazing as to the amount of information available. I just wish that in looking for what I need to do I did not need to look in so many places. I feel that if I want to root my T-Mobile GS3 that all the information should be in one subsection of the forum, but it is not that simple I guess....lol Anyway any help would be greatly appreciated.
I have a Samsung GS3 with T-Mobile that I want to root. Everyone says to back up the phone before you do it but I am not really seeing how to make a backup before I start. It appears that most of the guides to root just say to backup without telling you how to fo it. Another thing (correct me if I am wrong) I see the nandroid backup that I think is a backup of the phone however it seems to be done after you make changes to the phone and I thought the backup was supposed to be done before you do anything. Is it that there is not a way to make a complete backup with an unrooted phone?
My question is basically the same as the OP here. I have been reading and reading and reading posts here in the forum. There is much information here and much of it is duplicated with slight variances in some of the duplicates. I am not certain as to which rooting method I should use. There seem to be so many choices. As a new person to this forum I will say that you can find just about everything about any phone which is awesome. The hard thing is sifting through the many options to pick one to use for your issue.
I do see that Mr. Robinson has a thread with backups of the original roms. The only thing is that they are default roms that are like an out of the box phone and not my phone with my apps and my settings. That is what I want to backup...My phone with my settings and my apps.
:good: Thank you in advance for any one that can shed some light on this for me and the OP'er
Click to expand...
Click to collapse
Hi ya,
It's so nice that you are having the same concern as I do.
As far as i know, the approaches of rooting differ from phones to phones. So we may have to find our own specific rooting method in the phone model sub-forums. It won't be hard for your popular S3
I would like to have a look at that Mr. Robinson's thread. If he can backup the stock ROM, those app+app_data wont a big issue (i guess).
cheers,
midnite_
midnite_ said:
Questions
Rooting will in fact changes some files/data of the system. So backup after root is NOT getting the original stock ROM. Is it?
Is there a method to "un-root", so ALL the changes are TOTALLY reverted?
Installing/flashing things like CWM in phone requires rooting, which would make the ROM not original. Is there a way to extract the system backup from a computer externally?
Click to expand...
Click to collapse
Hi midnight, welcome to a new and exciting world of Android and trying new things. First, let me assure you, what you want is NOT something new. People have been doing this type of thing for years. That is flashing and testing roms. As you will learn, it actually becomes quite addictive. We call those folks that get addicted to flashing: Flashaholics or crackflashers, lol
First let me talk about "root". This process consists of unlocking a lower level of the Android system known as the bootloader. Unlocking the bootloader of your device allows you to flash a custom recovery, flashing a custom recovery allows you to flash the Superuser binary and Superuser.apk, This is what allows you to use apps that require "root". The bootloader is not an OS file. So when you are unlocking your bootloader you are not modifying your stock rom. Only when you have flashed the Superuser package have you modified your stock rom. And even that isn't really modifying anything. When you flash the Superuser package, it adds two files to your rom at certain locations of the file system. It adds the Superuser.apk file to system/app and it adds the SU binary to system/bin. Basically you CAN have a totally S-OFF (unlocked) bootloader and still have an entirely stock rom if you want. But the real benifit is flashing a custom recovery like ClockworkMod Recovery and then flash the superuser package.
As far as extracting the stock system, you should try giving adb a go. Do it right now if you like. Ensure you have the android sdk installed and properly set up on your computer and your computer can recognize your phone. Ensure your phone is in debugging mode, connect your phone to your computer, open up a command window, and run this command:
Code:
adb pull \
This command will pull everything off your phone except for data which is where your market or Google Play apps are stored.
Beyond XDA there are aso more resources to learn from. For example, http://www.android.com is a good place to start, and to learn more about adb check out http://developer.android.com/tools/help/adb.html
If you need to learn how to setup the sdk here is the place to learn how: http://developer.android.com/sdk/index.html
I'm sure others will add to this as well which is the good thing about this community.
Welcome to XDA, I hope you have fun learning, and maybe share back someday things you learn along the way.
wildstang83 said:
Hi midnight, welcome to a new and exciting world of Android and trying new things. First, let me assure you, what you want is NOT something new. People have been doing this type of thing for years. That is flashing and testing roms. As you will learn, it actually becomes quite addictive. We call those folks that get addicted to flashing: Flashaholics or crackflashers, lol
First let me talk about "root". This process consists of unlocking a lower level of the Android system known as the bootloader. Unlocking the bootloader of your device allows you to flash a custom recovery, flashing a custom recovery allows you to flash the Superuser binary and Superuser.apk, This is what allows you to use apps that require "root". The bootloader is not an OS file. So when you are unlocking your bootloader you are not modifying your stock rom. Only when you have flashed the Superuser package have you modified your stock rom. And even that isn't really modifying anything. When you flash the Superuser package, it adds two files to your rom at certain locations of the file system. It adds the Superuser.apk file to system/app and it adds the SU binary to system/bin. Basically you CAN have a totally S-OFF (unlocked) bootloader and still have an entirely stock rom if you want. But the real benifit is flashing a custom recovery like ClockworkMod Recovery and then flash the superuser package.
As far as extracting the stock system, you should try giving adb a go. Do it right now if you like. Ensure you have the android sdk installed and properly set up on your computer and your computer can recognize your phone. Ensure your phone is in debugging mode, connect your phone to your computer, open up a command window, and run this command:
Code:
adb pull \
This command will pull everything off your phone except for data which is where your market or Google Play apps are stored.
Beyond XDA there are aso more resources to learn from. For example, ht tp://www .android .com is a good place to start, and to learn more about adb check out ht tp://developer .android .com/tools/help/adb.html
If you need to learn how to setup the sdk here is the place to learn how: ht tp://developer .android .com/sdk/index.html
I'm sure others will add to this as well which is the good thing about this community.
Welcome to XDA, I hope you have fun learning, and maybe share back someday things you learn along the way.
Click to expand...
Click to collapse
Hi Wildstang,
Thanks very much for your warm welcome and very informative reply. So are you a Flashaholics or Crackflashers yet?
As I am a newbie, please forgive me if I am asking dumb questions.
As far as I understand,
The steps of root is
1. Unlock the bootloader
2. Flash Superuser binary & Superuser.apk
** does "flash a custom recovery" means "flash Superuser binary & Superuser.apk"?
"Flash Superuser binary & Superuser.apk" is just "add SU binary to system/bin" and "add Superuser.apk to system/app". Then why not just copy them into place?
I just found on the web that "flashing" means replacing the OS of the phone with a new ROM. Would that still keeping the stock ROM?
To have a backup of the original stock ROM, can I
1. Unlock the bootloader
2. Flash Superuser binary & Superuser.apk
3. Perform the backup
And later, after I have flashed a new ROM, or whatever I do, as long as I didn't brick it, when I want to rollback my phone to its original, I can
1. Restore the backup
2. Delete "SU binary in system/bin" and "Superuser.apk in system/app"
3. re-lock the bootloader
Is this correct?
I don't mean to challenge you. But does adb pull \ really backup the system, or just all the files?
Thanks very much again!
midnite_
Hey midnite_,
I am a newbie too and have a lot of blank spots in my understanding of what we can do with android. I also came here with same question. I found how to root, this isn't a secret. Like you, I want to know how do I fix it if I break it.
So, with regards to your questions.
1. Unlock the bootloader
Not clear on this one, as not every tutorial even mentions this part. My feeling is that this might be specific to some phones, like HTC.
2. Flash Custom Recovery (such as AmonRa, CWR, TWRP...)
Recovery is an intermediate stage of phone booting process after bootloader but before OS.
It is there to allow OTA (Over the air) updates. During those, the OS is halted and replaced with a newer one.
What this means for us is that the recovery is capable of replacing OS (ROM - are these terms interchangeable?).
Recovery is the same as hidden partition on windows, that is sometimes present on a PC. It has a limited interface.
It can replace one OS image with another. It probably checks the checksum and creates the new one after the update. It is probably the gatekeeper.
Stock recovery will not replace OS with an image from SD card or from PC through USB. Only OTA.
This is the reason for flashing the custom (hacked) recovery on.
Custom recovery is made to allow additional options, such as allowing image sources such as PC or SD card, and also a ROM backup (write OS image to PC).
3. Flash update file using "upgrade from SD card" function of custom recovery now in place.
In this step, the Superuser.apk and bin files are placed. Stock recovery will not let us do that.
Also, I think the reason we can't just use ADB to "copy" superuser package to phone is because the system is either running or exists as an image (compressed?), and is probably protective of its modification. (So, likely the superuser package also replaces the checksum that the OS uses to check if it has been compromised?) Yes, this modifies your rom.
I assume that unrooting could be done after this by updating again with a file that removes superuser package and that would make your rom stock again.
4 OR flash custom ROM, which usually includes superuser package. Of course using custom rom means you no longer have stock rom.
To have a backup of original ROM, you would :
1 Unlock bootloader,
2 Flash (install) custom recovery
3 superuser doesn't matter here
4 Use custom recovery function to back up your stock ROM.
I want to know the answers to the rest of your questions as well as some clarifications to mine.
Personally, I am looking for a way to backup the stock recovery as well.
I know there are some people asking about this. The procedure appears to be as follows:
(pieced together so don't take it as a tutorial)
1 Unlock bootloader (again, unclear on this. Also some mention S-OFF and others don't)
2 With USB debugging allowed (meaning connect as device requiring a driver), Connect to a PC with ABD, and a driver installed.
3 From ADB, issue a command "adb boot recoveryimage.name" instead of the usual "adb flash recoveryimage.name".
This will make the phone boot into a custom recovery image that is residing on PC, without first writing it to the phone.
4 Unclear how, but make that custom recovery now being live to back up stock rom to pc.
5 Unclear how, but make that custom recovery now being live to flash either root or custom rom to the phone.
6 Disconnect, reboot the phone. Once in OS, use root privileges to mount recovery partition ? (this makes it visible as drive)
7 Don't know how, but use root privileges to back up now visible stock recovery partition to PC as image.
( This should give you two out of three original parts.)
Keep in mind that even if my peace-by-peace "know-how" ever works, there is at least one clearly faulty step:
The back up of the original state of the boot loader has been never made. I do not know if it is easily can be toggled back and forth from lock to unlock and back without leaving any trace. Also, like yourself, I probably don't quite understand what am I talking about, but I have tried to make as much sense of what I have read here and there.
This is my first smart phone, and my experience with linux is limited to building a minecraft server on MineOS, which was pre-made so that not much was required to make it run. I have "mounted" a partition for the first time last week, trying to break Win7recovery, booting it with Knoppix. This is why I think this is probably will come in play here too, as the recovery partition on W7 was hidden. Until then I didn't understand what mounting means, as windows always does it for you. So, take everything I say with a bunch of salt.
Please, let me know too, if you find out more. I want to flash the hell out of my Prism, but I want to be smart about it.
bump... midnite_ r u still around?
Hi Descent2,
Yes i am still around but i am busy with other stuffs at this moment. Thanks very much for your reply. You have studied a lot and you really did good summarisations. Very informative and I learnt a lot from it. Hope some of the masters or experienced ones would come by and bring us out of the mist
cheers,
midnite_
Descent2 said:
Hey midnite_,
I am a newbie too and have a lot of blank spots in my understanding of what we can do with android. I also came here with same question. I found how to root, this isn't a secret. Like you, I want to know how do I fix it if I break it.
So, with regards to your questions.
1. Unlock the bootloader
Not clear on this one, as not every tutorial even mentions this part. My feeling is that this might be specific to some phones, like HTC.
2. Flash Custom Recovery (such as AmonRa, CWR, TWRP...)
Recovery is an intermediate stage of phone booting process after bootloader but before OS.
It is there to allow OTA (Over the air) updates. During those, the OS is halted and replaced with a newer one.
What this means for us is that the recovery is capable of replacing OS (ROM - are these terms interchangeable?).
Recovery is the same as hidden partition on windows, that is sometimes present on a PC. It has a limited interface.
It can replace one OS image with another. It probably checks the checksum and creates the new one after the update. It is probably the gatekeeper.
Stock recovery will not replace OS with an image from SD card or from PC through USB. Only OTA.
This is the reason for flashing the custom (hacked) recovery on.
Custom recovery is made to allow additional options, such as allowing image sources such as PC or SD card, and also a ROM backup (write OS image to PC).
3. Flash update file using "upgrade from SD card" function of custom recovery now in place.
In this step, the Superuser.apk and bin files are placed. Stock recovery will not let us do that.
Also, I think the reason we can't just use ADB to "copy" superuser package to phone is because the system is either running or exists as an image (compressed?), and is probably protective of its modification. (So, likely the superuser package also replaces the checksum that the OS uses to check if it has been compromised?) Yes, this modifies your rom.
I assume that unrooting could be done after this by updating again with a file that removes superuser package and that would make your rom stock again.
4 OR flash custom ROM, which usually includes superuser package. Of course using custom rom means you no longer have stock rom.
To have a backup of original ROM, you would :
1 Unlock bootloader,
2 Flash (install) custom recovery
3 superuser doesn't matter here
4 Use custom recovery function to back up your stock ROM.
I want to know the answers to the rest of your questions as well as some clarifications to mine.
Personally, I am looking for a way to backup the stock recovery as well.
I know there are some people asking about this. The procedure appears to be as follows:
(pieced together so don't take it as a tutorial)
1 Unlock bootloader (again, unclear on this. Also some mention S-OFF and others don't)
2 With USB debugging allowed (meaning connect as device requiring a driver), Connect to a PC with ABD, and a driver installed.
3 From ADB, issue a command "adb boot recoveryimage.name" instead of the usual "adb flash recoveryimage.name".
This will make the phone boot into a custom recovery image that is residing on PC, without first writing it to the phone.
4 Unclear how, but make that custom recovery now being live to back up stock rom to pc.
5 Unclear how, but make that custom recovery now being live to flash either root or custom rom to the phone.
6 Disconnect, reboot the phone. Once in OS, use root privileges to mount recovery partition ? (this makes it visible as drive)
7 Don't know how, but use root privileges to back up now visible stock recovery partition to PC as image.
( This should give you two out of three original parts.)
Keep in mind that even if my peace-by-peace "know-how" ever works, there is at least one clearly faulty step:
The back up of the original state of the boot loader has been never made. I do not know if it is easily can be toggled back and forth from lock to unlock and back without leaving any trace. Also, like yourself, I probably don't quite understand what am I talking about, but I have tried to make as much sense of what I have read here and there.
This is my first smart phone, and my experience with linux is limited to building a minecraft server on MineOS, which was pre-made so that not much was required to make it run. I have "mounted" a partition for the first time last week, trying to break Win7recovery, booting it with Knoppix. This is why I think this is probably will come in play here too, as the recovery partition on W7 was hidden. Until then I didn't understand what mounting means, as windows always does it for you. So, take everything I say with a bunch of salt.
Please, let me know too, if you find out more. I want to flash the hell out of my Prism, but I want to be smart about it.
Click to expand...
Click to collapse
check here
All your answers can be found here: [REF] [GUIDE] Welcome to your device, the Galaxy S III. For more XDA related issues check here: [GUIDE] - XDA New User Guide - Getting started on XDA
Good Luck!
mf2112
XDA Moderator
ASharpEdge said:
Hello all this is my first post here...woohoo!:fingers-crossed: This forum is amazing as to the amount of information available. I just wish that in looking for what I need to do I did not need to look in so many places. I feel that if I want to root my T-Mobile GS3 that all the information should be in one subsection of the forum, but it is not that simple I guess....lol Anyway any help would be greatly appreciated.
I have a Samsung GS3 with T-Mobile that I want to root. Everyone says to back up the phone before you do it but I am not really seeing how to make a backup before I start. It appears that most of the guides to root just say to backup without telling you how to fo it. Another thing (correct me if I am wrong) I see the nandroid backup that I think is a backup of the phone however it seems to be done after you make changes to the phone and I thought the backup was supposed to be done before you do anything. Is it that there is not a way to make a complete backup with an unrooted phone?
My question is basically the same as the OP here. I have been reading and reading and reading posts here in the forum. There is much information here and much of it is duplicated with slight variances in some of the duplicates. I am not certain as to which rooting method I should use. There seem to be so many choices. As a new person to this forum I will say that you can find just about everything about any phone which is awesome. The hard thing is sifting through the many options to pick one to use for your issue.
I do see that Mr. Robinson has a thread with backups of the original roms. The only thing is that they are default roms that are like an out of the box phone and not my phone with my apps and my settings. That is what I want to backup...My phone with my settings and my apps.
:good: Thank you in advance for any one that can shed some light on this for me and the OP'er
Click to expand...
Click to collapse
Thanks mf2112. But those resources are seem only for GS3. And it seems it is not teaching us to backup our stock ROMs, it provides stock ROMs for us to download instead. Is there a general way to backup our stock ROMs?
Thanks,
midnite_
mf2112 said:
All your answers can be found here: [REF] [GUIDE] Welcome to your device, the Galaxy S III. For more XDA related issues check here: [GUIDE] - XDA New User Guide - Getting started on XDA
Good Luck!
mf2112
XDA Moderator
Click to expand...
Click to collapse
You must unlock your bootloader then flash a custom recovery. You will then use that custom recovery to make a backup of your rom. That backup will be stored on your sd card.
Now, I have tried to help you and so have a couple other folks. You expect us to just give you answers step by step. I am sorry but this is simply not how XDA works. XDA is set up in a way which makes it for any users to find quickly what they want to know. Use the search feature on the site and you will find many answers. I tell you to go do your own research now and be proud of what you learn on your own. And if you cannot, please do not try to modify your phone further, you may just brick it if you aren't careful.
midnite_ said:
Thanks mf2112. But those resources are seem only for GS3. And it seems it is not teaching us to backup our stock ROMs, it provides stock ROMs for us to download instead. Is there a general way to backup our stock ROMs?
Thanks,
midnite_
Click to expand...
Click to collapse
I put in the GS3 links since the OP was using that phone. Every phone will be different so I don't think a general way or guide would be practical.
Sent from my HTC Sensation 4G using xda premium

[Q] Deployment of image to multiple devices

Hi gurus! I have done some searching based on this, but I seem to come across many different answers based on devices, ROMs etc. So I thought I would just ask. Apologies if there is an easy guide I have missed!
I need to configure a number of Android sticks with customized settings and software then deploy them in kiosk environments. Rather than configure each one separately, I'm hoping to be able to deploy an image nice and quickly to them.
The sticks are RK30 based. The webpage is here: http://multitouch.com/istick-a200-fastest-mini-computer.html and the specs are here: http://multitouch.com/download/datasheet/istick-a200-datasheet.pdf.
They are pre-rooted and you can download a "Factory Restore Pack" which includes the ADB driver, RKBatch Tool and a single factory image. It seems pretty easy to use the tool to push the image to the device and reset it.
I'm hoping to be able to configure a single device and then backup or export the image to an img file (like the factory default one) then just push this to the other devices using the same method. Is this possible and if so, how would I create the img file?
I've read and tried to understand about img files, but it seems there are boot.img files, system.img files and a whole bunch of others. I'm guessing this is a system.img file, but if I stuff around with no direction, I'll probably just brick a bunch of devices.
I also guess I could install clockwork mod and then backup to an SD, then install cm on each new device and restore the backup, but I'm hoping to do this without even needing cm by just using the RKBatch tool.
I really appreciate any help anyone can provide. Thanks in advance!
OK - update (maybe)
Can I use this tool: http://vondroid.com/threads/updated-27-08-2012-how-to-dump-current-rom.322/? I'm guessing that the file I then want to get is the system partition? Is this the one that RKBatchTool will push back to the device?
Soooo many ways to brick!!!

How are Android Phones different from PCs; making them harder to modify?

Out of curiosity, someone please explain to me what we are doing at the hardware level when we flash/root etc. I have an excellent understanding of PCs and Windows hard drives, but I don't understand why Android is much more complicated to modify and how the carriers are able to permanently mess up (in our opinion) our phones using OTA updates when there is not a computer virus that exists that can permanently mess up my computer to the point that a wipe and reinstall wont fix it?
My specific questions are as follows:
1. Most thread instructions usually say to root the phone before installing custom recovery (TWRP). If we are doing an ODIN flash, is rooting actually needed to install TWRP? Is root part of the ROM? Or is it a deeper hardware thing unrelated to the ROM?
2. If we are installing a custom rom (cyanogen mod) and we want root, is it necessary to root with a separate method (superuser.zip etc), or does flashing cyanogen mod give us root automatically?
3. If we are flashing images to the phone's hard drive, why does the current operating system on the phone matter? Why is there a different root/TWRP install method (and .tar images?) for android 4.1.1 than there is for 4.1.2 or 3.x.x? Shouldn't the same ODIN images work regardless of what operating system the phone has on it? As in, why do I even need to look at what is currently installed on the phone? If I have a computer and I want to install a new operating system, the current OS doesn't matter, I just wipe the drive and install the new OS. Why are the phones different? Why is it possible to buy a brand new computer, wipe the drive, and install Windows XP, or even DOS, but I can't buy a brand new phone and install Android 1.0.0?
4. How are the carriers able to cause developers so many problems with their OTA updates? If someone upgraded their i747 to 4.3 why can't they just format the phone's drive and reinstall an older operating system like I can on my computer? Even a computer infected with the worst computer virus can still be wiped and reinstalled with any processor compatible operating system, so how do the OTA updates cause irreversible phone problems when nasty computer viruses can't do this?
Basically explain to me what makes the Android phones different from PCs and makes everything so much more complicated than it is to format a Windows drive and install Linux and then format again and install something totally different? I just don't understand what makes them so different? Lastly, if the carriers encrypt a bootloader, like ATT did with the S4, why can't we just erase the bootloader and flash our own not-encrypted bootloader to the phone? Is the bootloader some sort of chip that we would have to physically remove and replace? Or is it 1's and 0's on the drive that we can format and rewrite?
scubapilot said:
Out of curiosity, someone please explain to me what we are doing at the hardware level when we flash/root etc. I have an excellent understanding of PCs and Windows hard drives, but I don't understand why Android is much more complicated to modify and how the carriers are able to permanently mess up (in our opinion) our phones using OTA updates when there is not a computer virus that exists that can permanently mess up my computer to the point that a wipe and reinstall wont fix it?
My specific questions are as follows:
1. Most thread instructions usually say to root the phone before installing custom recovery (TWRP). If we are doing an ODIN flash, is rooting actually needed to install TWRP? Is root part of the ROM? Or is it a deeper hardware thing unrelated to the ROM?
2. If we are installing a custom rom (cyanogen mod) and we want root, is it necessary to root with a separate method (superuser.zip etc), or does flashing cyanogen mod give us root automatically?
3. If we are flashing images to the phone's hard drive, why does the current operating system on the phone matter? Why is there a different root/TWRP install method (and .tar images?) for android 4.1.1 than there is for 4.1.2 or 3.x.x? Shouldn't the same ODIN images work regardless of what operating system the phone has on it? As in, why do I even need to look at what is currently installed on the phone? If I have a computer and I want to install a new operating system, the current OS doesn't matter, I just wipe the drive and install the new OS. Why are the phones different? Why is it possible to buy a brand new computer, wipe the drive, and install Windows XP, or even DOS, but I can't buy a brand new phone and install Android 1.0.0?
4. How are the carriers able to cause developers so many problems with their OTA updates? If someone upgraded their i747 to 4.3 why can't they just format the phone's drive and reinstall an older operating system like I can on my computer? Even a computer infected with the worst computer virus can still be wiped and reinstalled with any processor compatible operating system, so how do the OTA updates cause irreversible phone problems when nasty computer viruses can't do this?
Basically explain to me what makes the Android phones different from PCs and makes everything so much more complicated than it is to format a Windows drive and install Linux and then format again and install something totally different? I just don't understand what makes them so different? Lastly, if the carriers encrypt a bootloader, like ATT did with the S4, why can't we just erase the bootloader and flash our own not-encrypted bootloader to the phone? Is the bootloader some sort of chip that we would have to physically remove and replace? Or is it 1's and 0's on the drive that we can format and rewrite?
Click to expand...
Click to collapse
Reason being is that the manufacturers have control over everything and completely lock you out.
Its not like you have a bios on these phones or you can install a new hard drive with a different OS on it.
They lock it down so much.
It's also not impossible to root any of the phones.
All you need to do is use uart or jtag to talk to the device straight up.
Rotting is part of the rom.
An odin flash will work great for flashing recovery(For samsung devices only)
And roms.
But odin flashes whole partitions only.
Rotting is not a hardware thing.
Its basically finding a way to place a file on the /system partition in the bin folder.
Then being able to execute that file. (File: su)
The su executable changes your uid(User id) to 0 which indicates the root user giving you full access over the device.
To get the su executable on to the device you will have to find exploits in the software to allow you to write to the /system/bin directory.
One such exploit is zergrush which gave you a root shell where you copy the su binary over to the device.
What is rooting?
Pretty much every rom here will be given root access by default.
Some roms(Usually indicated with stock) have no root.
In which case recovery will allow you to flash a zip putting the su files onto your installed rom.
(Recovery is like running a live cd to repair windows.)
A good place to learn is xda-university
What is recovery?
These phones have flash memory.
Not magnetic.
And like I said Odin flashes whole partitions.
So it would completely wipe whatever partition you are flashing to.
/system would contain android.
So an odin package with a system img would wipe the current OS and flash the contents of your odin package to the place where the old OS was.
To summarize, Odin packages are not dependent upon the installed OS at all.
Now that is an interesting question.
The reason that you can't just install any OS is because we don't just have generic drivers built for generic hardware.
We have millions of different phone models.
There really hasn't been any movement for standard compliant hardware in the phone scene.
So building generic stuff for all of the different kinds of phones would be a nightmare.
And the last one.
Its because we rely on software security bugs to break into devices.
Google has made it easy for us to do anything that we want with our devices with a simple command.
samsung's download mode isn't a sure fire way of doing any modding because you would have to build a rom from stock. (Samsung doesn't release their stuff very often. An exception to this is : sammobile )
And again, you could do this with an underlying knowledge of the hardware using Uart or jtag. (Conneting to the board directly and speaking to the processor)
Seriously think about that for a second, how do you install windows. A cd drive.
How do you configure devices. a bios.
In short : These phones aren't made to be messed with for security reasons and because manufacturers are too lazy to make it easy for modders. (Nexus devices are made in mind for modders though)
Need anymore info just ask. :highfive:
Thank you so much Lgrootnoob. A few more questions.
1. When you say
To get the su executable on to the device you will have to find exploits in the software to allow you to write to the /system/bin directory.
Click to expand...
Click to collapse
Do I understand correctly that this is only true when adding root to a stock rom? If I flash cyanogen mod to the system partition, it does not require an exploit because it just erases and overwrites the entire partition? I have been rooting, and then installing TWRP, and then installing Cyanogen Mod. If I understand you correctly, me rooting the stock rom is an unnecessary step, as I am just erasing and overwriting it with Cyanogen Mod later?
Google has made it easy for us to do anything that we want with our devices with a simple command.
Click to expand...
Click to collapse
2. So modding the Google Nexus does not require that we use the exploits you mentioned are needed to modify the other phone(s)?
3. I understand that Android 4.3 has security features that prevent gaining "true root"? As long as Nexus leaves the "easy access" you mentioned, it will still be possible to flash a custom rom that does allow true root, no matter what security features Google puts into its version of Android?
4. Does the Google Play Edition Galaxy S4 require the exploits? Or do the Google Play edition phones have the same "easy access" you mentioned the Nexus has? Is the "easy access" the fastboot function I've read about?
5. With a carrier that encrypts all of their bootloaders, I will most likely be forced to buy only Nexus products or Google Play edition phones if I want to have Cyanogen Mod with full root? I haven't wanted a Nexus because it doesn't have a removable battery or SD card, but having custom firmware is the most important thing to me.
scubapilot said:
Thank you so much Lgrootnoob. A few more questions.
1. When you say Do I understand correctly that this is only true when adding root to a stock rom? If I flash cyanogen mod to the system partition, it does not require an exploit because it just erases and overwrites the entire partition? I have been rooting, and then installing TWRP, and then installing Cyanogen Mod. If I understand you correctly, me rooting the stock rom is an unnecessary step, as I am just erasing and overwriting it with Cyanogen Mod later?
2. So modding the Google Nexus does not require that we use the exploits you mentioned are needed to modify the other phone(s)?
3. I understand that Android 4.3 has security features that prevent gaining "true root"? As long as Nexus leaves the "easy access" you mentioned, it will still be possible to flash a custom rom that does allow true root, no matter what security features Google puts into its version of Android?
4. Does the Google Play Edition Galaxy S4 require the exploits? Or do the Google Play edition phones have the same "easy access" you mentioned the Nexus has? Is the "easy access" the fastboot function I've read about?
5. With a carrier that encrypts all of their bootloaders, I will most likely be forced to buy only Nexus products or Google Play edition phones if I want to have Cyanogen Mod with full root? I haven't wanted a Nexus because it doesn't have a removable battery or SD card, but having custom firmware is the most important thing to me.
Click to expand...
Click to collapse
1. Well, devices that have no way of flashing at the bootloader must be rooted on the stock rom to flash other roms. (Exception: Nexus devices that have fastboot flash system.img functions) But custom roms come su in /system/bin all the time. (Unless said otherwise in their thread)
2. Yup, google gives exclusive access on the nexus phones.
However, you have to unlock the bootloader to flash anything.
Unlocking the bootloader will use the command:
Code:
fastboot oem unlock
Unlocking the bootloader wipes all data.(/data partition) but leaves the system partition intact.
Reasone being is when someone flashes a recovery:
Code:
fastboot flash recovery.img
They could use recovery to dump your data partition.
3. The way processes work in android 4.3 and above is different from 4.3's ancestors.
Root can be obtained with Supersu
But exploits to gain root on the android system have been pretty much put out of business.
Most exploits are bootloader exploits these days. (Or oem rom exploitsem's theming makes their devices vulnerable usually.[They have less tested code or just don't care.])
So root is still widely available on just about any rom out there thanks to chainfire!
^He is an awesome developer by the way.
4. I would figure that the google play editions have easy access with fastboot that would normally be stumped by samsung.
Google makes everything awesome.
" Is the "easy access" the fastboot function I've read about?" In short yes.
It allows you to flash recovery which can dump the whole system and allow you to modify the system however you like and put it back on the device.
There is even an app for recovery by the way: Aroma fm
5. The removable battery doesn't matter unless you wan't to swap batts on the fly.
But it does have a function for restarting the phone without pulling the battery. Hold power button + volume up until it restarts.
And even if you wanted to replace the battery you could take the nexus device apart and disconnect the battery and find a replacement. (Maybe ordered from the manufacturer.)
The devs here are awesome and find exploits in almost all of the bootloaders or the oem (skinned) android versions.
So the nexus devices aren't the only option, but they usually get more development unless your device is truly a powerhouse like the gs4 international.

AT&T H10 20N Android 6.0 - Temp Root request

Hello everyone,
I would really like to achieve a temporary root on my device. I am running the stock version, recently it updated to 20N for the Android 6.0 MM update.
I am very comfortable with adb and other command line interfaces (I primarily work on Linux servers remotely for my day job).
Are there any good resources for achieving a manual temporary root from adb on this device (or any Android device in general?). I find my Google-Fu searching has been lacking, I haven't found any reliable information on this in general for Android. Ideally, I would like to achieve a temporary root without having to wipe my device or install a new ROM. Am I correct in thinking that some sort of temporary root must be achieved before installing a custom ROM? I am wary of most "One Click" packages out there.... I prefer to do the grunt work and understand why/how something works.
In short, I yearn to see a '#' instead of '$' over an abd connection, specifically for an LG G4 H810 20N, but any general Android process is welcomed! Even being able to mount the filesystem as root (possibly from a bootloader or recovery mode) and access the internal filesystem as root via command line would be considered a success. I primarily want to be able to read/write files that are normally blocked from the standard user.
Thanks in advance!
MisterMagicFingers said:
Hello everyone,
I would really like to achieve a temporary root on my device. I am running the stock version, recently it updated to 20N for the Android 6.0 MM update.
I am very comfortable with adb and other command line interfaces (I primarily work on Linux servers remotely for my day job).
Are there any good resources for achieving a manual temporary root from adb on this device (or any Android device in general?). I find my Google-Fu searching has been lacking, I haven't found any reliable information on this in general for Android. Ideally, I would like to achieve a temporary root without having to wipe my device or install a new ROM. Am I correct in thinking that some sort of temporary root must be achieved before installing a custom ROM? I am wary of most "One Click" packages out there.... I prefer to do the grunt work and understand why/how something works.
In short, I yearn to see a '#' instead of '$' over an abd connection, specifically for an LG G4 H810 20N, but any general Android process is welcomed! Even being able to mount the filesystem as root (possibly from a bootloader or recovery mode) and access the internal filesystem as root via command line would be considered a success. I primarily want to be able to read/write files that are normally blocked from the standard user.
Thanks in advance!
Click to expand...
Click to collapse
Bad news: at this point it's not going to happen. With 6.x you have to have a modified kernel to get root and the locked bootloader on your phone will not allow that kernel to boot. In short: don't expect to see root on Marshmallow on this phone anytime soon and it will probably never happen.
I'm not saying that it's impossible, but it's almost certainly not going to happen.
http://www.xda-developers.com/a-look-at-marshmallow-root-verity-complications/
fatbas202 said:
http://www.xda-developers.com/a-look-at-marshmallow-root-verity-complications/
Click to expand...
Click to collapse
Thanks for the information! I have several 4.x and 5.x devices around and am still hoping to find some general information on manually achieving temp root access of the filesystems.
MisterMagicFingers said:
Thanks for the information! I have several 4.x and 5.x devices around and am still hoping to find some general information on manually achieving temp root access of the filesystems.
Click to expand...
Click to collapse
We are all hoping that you find something that someone else has overlooked! Good luck!

download from device - samsung firmware

Hi,
I want to download the current firmware from a device. (in this case SM-A125F/DSN )
After hours of searching I gave up. All I got are guides etc. to download firmwares from WEB.
I need it as a backup for my experiments. But if, by any chance, someone can point me to a place where I can download this exact firmware, I'd be happy too.
I also tried to find that specific firmware as an alternative to downloading. But no luck after another 60 minutes. (beside some dubious sites that claimed to have everything but wanted money first, so I was obviously digging deep already - maybe I'm just asking the wrong questions (search terms))
Ofc. I'd prefer to download it from device.
SM-A125F/DSN
[ QP1A.190711.020. ] A125FXXU1AUC3
4.9.190-20270726
If you mean backing up / extracting phone's firmware then - if phone's Android is rooted - you may use ADB to achieve this.
Example extracting boot.img
Method 1
Code:
adb devices
adb root
adb pull "<NAME-OF-RELATED-BLOCK-DEVICE-HERE>" > C:\boot.img
Method 2
Code:
adb devices
adb root
adb exec-out "dd if=<NAME_OF_RELATED_BLOCK_DEVICE_HERE> bs=4096" > C:\boot.img
tyvm for the input!
it is not rooted (but the bootloader is unlocked but I fear this won't help, would it ?)
I guess same applies to the other partitions? (root requirement)
further I guess, there is no way to do this without root (you would have mentioned it, even if obscure, right? :] )
i focus on alternative now (search for firmware)
EDIT: yes, I mean "backing up / extracting phone's firmware"
jwoegerbauer said:
If you mean backing up / extracting phone's firmware then - if phone's Android is rooted - you may use ADB to achieve this.
Click to expand...
Click to collapse
Tell me please if it has sense to backup literally all partitions?
asq81:
ADB doesn't know much about rooting as far as I know, especially in download mode.
It wants only USB debug activated.
asq81 said:
Hi,
I want to download the current firmware from a device. (in this case SM-A125F/DSN )
After hours of searching I gave up. All I got are guides etc. to download firmwares from WEB.
I need it as a backup for my experiments. But if, by any chance, someone can point me to a place where I can download this exact firmware, I'd be happy too.
I also tried to find that specific firmware as an alternative to downloading. But no luck after another 60 minutes. (beside some dubious sites that claimed to have everything but wanted money first, so I was obviously digging deep already - maybe I'm just asking the wrong questions (search terms))
Ofc. I'd prefer to download it from device.
SM-A125F/DSN
[ QP1A.190711.020. ] A125FXXU1AUC3
4.9.190-20270726
Click to expand...
Click to collapse
I don't know much about tech, but it seem to me that you would make your life easy if you would:
1. Look at the exact firmware you have at about phone. I guess you have a Samsung Galaxy A12.
2. Use a reliable Samsung firmware website, for example https://www.sammobile.com.
3. Click browse firmware archive
4. Enter your model: SM-A125F
You should have there the firmware specific for numerous countries, as far as the last 2-3 firmwares for your device. I think on sammobile they might ask you to create an account.
F308 said:
Tell me please if it has sense to backup literally all partitions?
asq81:
ADB doesn't know much about rooting as far as I know, especially in download mode.
It wants only USB debug activated.
Click to expand...
Click to collapse
Don't confuse the Android images like
boot.img, system.img,recovery.img,vendor.img,vbmeta.img, etc.pp
and Android partitions.
The described 'pull' method works well! Thank you jwoegerbauer!
(did not try 'dd' - there was no reason to do so for me)
For me it was ok to flash a boot image and leave everything else untouched. (yay, finally found one and let magisk patch it to have root)
In my case I did not plan to do anything to boot image, just had to find a working one (with root) and backup this. BUs from everything else is what I really need. Not a perfect but totally adequate solution!

Categories

Resources