Kingroot to SuperSU (Root Issue) - Android Q&A, Help & Troubleshooting

Hey, new user here. Sorry if this is miscategorised.
I have a very simple issue. I have a GT-I9305, recently rooted with some weird Android Terminal commands and a .zip file I found online. No issue with rooting. I did a root check and used root to uninstall Knox.
Issue is that beforehand I tried to root with KingRoot and I didn't know it would automatically download its own SU (probably should have been more cautious). I want to use Super SU instead but I can't because after some research, there'll be so conflict between these two. So further research suggests I need to do some deep replacement between these two.
I've tried several methods already.
An app called SuperSu Me required higher Android version, so that was a strike for me. The one with the commands with the mrw file did not work (just threw up a whole list of failures and errors), and another appears to be working with Kit Kat only (I'm on 4.3). Another limitation I have is that my computer is garbage and probably won't run Odin or whatever flashing thing, so that rules out another horde of solutions.
Further, Super SU did not update binary, which most websites suggested it will do. It tries to do it, then regurgitates an error message after five minutes.
So I was just wondering if there is some obscure way beyond the second Google search page which might help me out here, to replace King SU with SuperSU. After all, the root method I used in the first place wasn't exactly conventional.
Just wanted to ask around here before I simply unroot and forget about the whole business. Been lurking around here unregistered and you guys have been very helpful, so now I guess I'm starting a topic of my own.

Related

[Q] Rooting procedure technical details - checklist

Hello everybody.
This is my first post, and while I am noob at XDA-Developers, I have spent more than 10 years writing and reading in forums, and I know what has to be done before writing on them. And I did. I have a couple of questions that I think they are not easy to answer. Indeed, I spent 8 hours yesterday searching through the interwebs and this forum to try to figure out the most thorough answer. And I think I figured out mine, but I don't know any people that can reinforce my toughts and tell me "Hey Gabriel: you are right, you did well, you are the man: go out for a beer, keep calm and carry on". I will ask the questions first, and later I will explain why I ask such questions, and finally what are the steps I did.
The questions are: How can I remove root from a custom rom, and how can I be sure that I properly did? I know that many of us think that "This is stupid / Why do you want to do such a thing / the power of your phone will... / go to stock / etc". But, any way, I have a deep concern on expanding concepts and knowledge, and I thing that root process, root means and rooted phone securing checklist are not as clear as I would like to find them. And more important: I *have* to remain in a custom rom but I *must not* be root.
So the why's are not the question but, just to add some reasonable context: I have a phone that does not fit my needs with the stock rom, because a hardware component is falling apart and I need a software workaround (YEAH, right LOL: a Nexus One with the power button falling apart and I need to be able to unlock / wake with the trackball; but this thread is Android-wide because it tries to find a deep insight into rooting itself). This software workaround does not work in stock rom when I configure the password / PIN / pattern. And the problem with custom roms is that they run into trouble with certain data-protection aware environments, which do not allow rooted terminals. And more important than all: I have no need at all to be root, at least by now.
So, I spent hours searching, and I figured out that I should remove "su" command and related APK's (ROM Manager, Superuser, ... and some others that I won't need). All by myself and with some posts (I don't remember if they were here or in "HTCMania", a good spanish smartphones board, either) that suggested it.
The exact process I did was to download CyanogenMod 7.2 RC1, check signature & md5 to make sure the zip was what it claimed to be (because later I found that I needed to shut down recovery signature check) open the .zip, remove "/system/xbin/su", install the rom, remove su-related ".apk" with adb, and try to check if it still had any sort of superuser permission scalation. It aparently does not have. I checked /data directory with Root Explorer, I downloaded and ran Root Checker Basic.
The results seem what I expected (and that's the question: they seem, and I don't know if they are): I am running on CyanogenMod, the workaround (wake on trackball) works, the PIN/password works fine with it, and it seems I am not able to gain root access.
But my question are deeper than that: is there any remaining technical mean that could be used to gain root access on my phone? Do I have to get rid of more su-companion tools to be sure and to be "non-root"-compliant? Is there any checklist we should follow to check both if our custom ROM is rooted-but-secure and if our ROM is properly un-rooted? And most important: did I miss / failed to find the correct resource in these forums?
Thanks to every body and congrats for this outrageous boards.

Difference between cf-root and galaxy s3 toolkit rooting method?

So there are two populair methods of rooting the galaxy s3:
- The Samsung galaxy s3 toolkit
- Chainfire's CF-ROOT
My questions are as follows:
What are the technical differences between the two rooting methods?
Do the methods have any drawbacks? (cf-root for example is incompatible with rommanager)
disclaimer:
I am not interested in what you think is the best method, I want to know the technical differences between the two methods used.
I know that the toolkit itself is not a rooting method, it does however include 4 different methods you can use, I am referring to those.
The toolkit uses cfroot I think. Not sure if it's as up to date as the latest cfroot via Odin. They both work well enough. There is no other method I know of. And I haven't had any drawbacks.
That's all I can say really
Sent from my GT-I9300 using xda premium
Also The toolkit uses Odin too. It has other options and clear instructions. Drivers. Modems etc so this would be the best option for an casual user.
Latest cfroot via Odin is probably your best option if u know what your doing
But it's up to you mate, it doesn't really need analyzing so deeply...
Sent from my GT-I9300 using xda premium
slking1989 said:
But it's up to you mate, it doesn't really need analyzing so deeply...
Click to expand...
Click to collapse
Well it is personal but I like to know or at least have a general idea of what I am doing to my phone. So yes it does
Tnx for the reply
Anyone else who can give me some more insight?
Unfortunately I don't have an answer for you, but I also am interested in the answer to your question..
I think certain methods of rooting use SuperSU (is this the CF one?) and then another method uses Superuser. I think both install busybox (that seems to be the same?)
In my experience, using the Superuser.apk app was faster than SuperSU..
I don't even have the Busybox app installed (but I am sure my phone has busybox, so this also confuses me??)
CF root gets the job done in 20-25 seconds. It installs superSU, busybox and cwm recovery. I would allways recommend rooting with CF Root over the Toolkit.
But that`s my opinion off course
gee2012 said:
CF root gets the job done in 20-25 seconds. It installs superSU, busybox and cwm recovery. I would allways recommend rooting with CF Root over the Toolkit.
But that`s my opinion off course
Click to expand...
Click to collapse
Yes go with the CFroot if u just want to root ur phone.
Sent from my GT-I9300 using Tapatalk 2
'K, I'll bite. I'm not going to give an overall recommendation - at the end of day, they both install an APK and put a new binary in /system/xbin.
Note: I used CF-Root to root my phone. When I talk about how the the toolkit does what it does, I'm basing my words on this image. I've seen the things in that image before, even though I haven't used the toolkit. This also means that my toolkit observations may not be entirely accurate but it's a batch script, anyway; you can just read through it and find out how it works. I'm also primarily a Windows user, but I used to use GNU/Linux quite a bit to write programs for a phone that I once had.
Rooting is, when broken down, the installation of a "su" binary installed to /system/xbin, that is owned by root and carries the setuid flag. This flag is important as the Linux kernel will then run the process whenever it's invoked as the person who owns it, root. This process can then, in turn, start other programs and they inherit the user ID (something like this - I'm taking my time reading TLPI...) so they are then running as root. There's also a "manager" app (Superuser or SuperSU) that will be installed; this app is talked to by the su binary (through the Android Binder AFAIK, though Superuser's source is available so if you really wanted to find out you could read that) to see, for example, if the program that is invoking "su" is allowed to do so. CF-Root installs the SuperSU apk to /system/app, which means that it survives factory resets. The toolkit, from a quick look at the Superuser ZIP in its folder and its batch file, also installs the Superuser apk to /system/app. When sideloading apps or installing from the Google Play Store, they usually get installed to /data/app.
Not all "su" implementations for Android need a manager app, I've seen implementations where su does not place restrictions on who is allowed to run it; uid=0 for everyone without discrimination! (Yes, that also includes you, Super Smilies Pack 3000 with boob smilies) Thankfully, neither the toolkit nor CF-Root do this. I lie a little. Superuser's su binary will automatically reject any request to become root if the Superuser.apk is not installed but SuperSU's su binary will automatically accept all requests to become root if the SuperSU apk is not installed. Personally, I prefer SuperSU's behaviour as there have been too many times with my old phones where I'd have to sign into Google Play after wiping /data just to install the Superuser APK when all I wanted was to run a simple command.
ext* filesystems along with other *NIX filesystems have the concept of file permissions, a concept shared by other *NIX filesystems. In order to actually place this su binary owned by root into a folder owned by root, you need to be root. (Actually, the folder is also owned by the shell group so a user which is a member of that group could do it too, but they wouldn't be able to set the all-important setuid flag as they're not the user root [perhaps a member of group root could do it but I don't know]) Usually, exploits in other programs running/can run as root or in the kernel are searched for so that you can temporarily root in order to install the su binary correctly. The GSIII (with the exception of Verizon's) has an unlocked bootloader, though, so programmers don't need to search for any of these: it's able to flash unofficial, unsigned recoveries and kernels.
CF-Root does this:
* it flashes a new CWM-based recovery in the recovery partition of the phone. If you've seen the stock Android recovery, you'll know that it just can't match the features of CWM. The important thing about CWM is that it runs as root, just like the stock recovery, but it also lets you place any file anywhere on the phone without requiring that the the ZIP file containing the files are not signed with a Samsung private key. Remember what I said about file permissions?
* there's also a param.bin file. I don't know anything about this file, but I suspect it's flashed to get the phone to boot up into recovery mode the next time it's started so that CWM runs before anything else
* it also flashes the cache partition (I'm not sure whether it overwrites or appends as I don't know how [and probably never will] know how ODIN works with two ZIP files: SuperSU, which contains the su binary, the SuperSU apk and a script that is run by CWM to set the required permissions on the su binary among other things, and the CWM app which lets you tell the recovery what actions you want it to perform in Android without having to navigate through the awkward interface of CWM itself. While I don't know how to do this myself, CWM recovery can be told to automatically run commands from an external source. I'm not talking about random websites on the Internet, but (I think) through files that have to be placed somewhere by root. This is what apps like the CWM app and ROM Manager do. This is also what CF-Root does to tell the recovery that the next time it's booted that it should install both the CWM ZIP and SuperSU ZIP. That's it in the case of CF-Root: you now have a phone with the two files required for root access, and a CWM recovery and an app to control it.
The toolkit:
(I only talk about the "insecure boot" options as I imagine the recovery option does something similar to the above and do remember that I haven't used the toolkit to root my phone so some assumptions are made. I also assume you know what ADB is as I won't be explaining it)
* it gets you to flash a kernel image with a patched adbd that runs as root, so adb on your computer, in turn, is able to place files anywhere on the phone's /. File permissions make it so you can't just place adbd in its expected place (/sbin) as any user and /sbin is also mounted on a ramdisk part of the flashable kernel image so it would be replaced on the next reboot, anyway.
* When the phone is running again with the new kernel, it then tells adb (now running as root) to push the Superuser APK and the su binary into their rightful place and sets the correct permisions on the su binary so that it runs as root
* if you've told it to install busybox, busybox is pushed and a bunch of symlinks for all the applets that BusyBox supports are set up
CF-Root installs, naturally, Chainfire's SuperSu whereas the toolkit installs Superuser. I much prefer SuperSU (and I bought a pro license for Superuser long before I did for SuperSu). Superuser's interface is much better than SuperSU's and it's also open-source but I find that SuperSU works much quicker for me (Root Explorer actually popped up a message on my sister's freshly-flashed Xperia Arc S saying that Superuser can be slow if Superuser hasn't granted it root access quick enough - I've never encountered that on my Huawei U8800pro with SuperSU which has pretty much the same specs as the Xperia) and it can also log the commands an app is running as root if you're suspicious of an application.
You'll notice that ADB still runs as a normal user with CF-Root. You can use Chainfire's adbd Insecure app which will replace /sbin/adbd everytime the phone is started with his patched adbd which always runs as root, or you can just flash one of the many kernels available that already include a patched /sbin/adbd.
CF-Root also does not install BusyBox. You can grab one of the installers from the Play Store but what I do personally is kang a CM9 nightly build for the I9300 and take the META-INF folder and the /system/xbin/busybox binary and strip out most of the lines in the update-script leaving only the lines that mount, extract and create the symlinks for busybox and place the result in a new ZIP which is then flashed with CWM.
Your "cf-root for example is incompatible with rommanager" gripe is easily solved - just flash another recovery. CF-Root just packages a CWM Recovery, an app to control CWM and SuperSU. CF-Root itself is not a resident component, but the recovery and SuperSU etc. are, if that makes sense.
qwerty12 said:
A long story with a lot of interesting and valuable information
Click to expand...
Click to collapse
Tnx! This is precisely what I have been looking for! A lot of the information I already found in seperate pieces but this made it click in my head. I used cf-root to root the phone and am currently deciding if I want to work with the included tools and cwm recovery or flash CWM touch
I got a busybox installer from the market and it works like a charm (Well Titanium backup seems to do its job anyway).
I must say I think was over analyzing this a bit since I owned a HTC desire before this phone where rooting has a lot more risks involved and a lot more steps.
The only advantage i can see to using toolkit is it will get updated quicker and it has loads of other options. If you just want to Root and flash a Rom cf root is way to go
Sent from my GT-I9300 using xda app-developers app
creesch said:
Tnx! This is precisely what I have been looking for! A lot of the information I already found in seperate pieces but this made it click in my head. I used cf-root to root the phone and am currently deciding if I want to work with the included tools and cwm recovery or flash CWM touch
Click to expand...
Click to collapse
Glad it helped
I must say I think was over analyzing this a bit since I owned a HTC desire before this phone where rooting has a lot more risks involved and a lot more steps.
Click to expand...
Click to collapse
Yeah, HTC's locked bootloaders and the S-ON/S-OFF rubbish is one of the reasons I decided to skip the One X and go for the Galaxy S3.
creesch said:
I must say I think was over analyzing this a bit since I owned a HTC desire before this phone where rooting has a lot more risks involved and a lot more steps.
Click to expand...
Click to collapse
Its fair to say that unlike many people on this forum you did your research. Searched.. and asked a valid question. Whereas the majority of people just ask questions without being bothered to figure it out themselves. So thanks. Over analyzing? Maybe a little... but its better than flashing any old thing like many other have done and continue to do. Big thanks to qwerty who has filled me in on some useful info also.
Sent from my GT-I9300 using xda premium
You should have thanked him tho maaan
Sent from my GT-I9300 using xda premium
creesch said:
Tnx! This is precisely what I have been looking for! A lot of the information I already found in seperate pieces but this made it click in my head. I used cf-root to root the phone and am currently deciding if I want to work with the included tools and cwm recovery or flash CWM touch
I got a busybox installer from the market and it works like a charm (Well Titanium backup seems to do its job anyway).
I must say I think was over analyzing this a bit since I owned a HTC desire before this phone where rooting has a lot more risks involved and a lot more steps.
Click to expand...
Click to collapse
Stick with 5.x.x.x recovery, touch(6.x.x.x) has some instability issues afaik
Sent from my GT-I9300 using xda premium
slaphead20 said:
Stick with 5.x.x.x recovery, touch(6.x.x.x) has some instability issues afaik
Sent from my GT-I9300 using xda premium
Click to expand...
Click to collapse
Alright well since it was only the touch aspect that made me consider it i'll leave it just like it is
Hey guys
Hey guys i have the internationa galaxy s3 running 4.1.2, i haven't done anything to my phone yet and im about to root it is the boot loader unlcoked and if not how do i unlock it :good:, could someone please help me:crying::crying: and give me clear instructions and links please :fingers-crossed: thanks you so much,
BTw i know this is the wrong thread but i cant find the right one, thanks alot guys
regards nick

[Q] Pyle PTBL102BCD tablet has only partial ROOT

Have a strange one I don't know how to fix. Purchased a Pyle PTBL102BCD tablet for the Mrs. to use basically as an ebook reader (according to About, running 4.2.2). When it came in I started sideloading apps to prepare it for her (I do not have a Google account), and searched on the Net about rooting the device. Found a one-click that worked with a different Pyle tablet, so I gave it a shot.
Now I have root access _only_ through the adb shell. None of the apps (including Superuser.apk itself as tested by updating /system/bin/su) can get root access, yet I have no problem running root through an adb shell - remounted file systems, even performed an su which is the only instance Superuser.apk's log shows. Root access in the shell remains between reboots, so it's not a temporary root.
If the adb shell has root, I _should_ be able to use it to grant access to everything else, and I've followed a few different "manual" root instructions (having different permission settings for su and busybox), with no joy. So long as I connect with a USB cable and type on the Windows machine, I'm god. On the tablet itself...not so much.
I hope that someone with a more intimate knowledge of Android internals can point me in the right direction for achieving root completely. Currently have Titanium Backup and ConnectBot (long java errors when I attempt to su there) installed to test root, Superuser v3.1.3 and su v3.1.1. Permissions on su are -rwsr-sr-x. And the human is confused.
Did you get anywhere with this? I have the same problem. What one-click did you use?
mfurlend said:
Did you get anywhere with this? I have the same problem. What one-click did you use?
Click to expand...
Click to collapse
Side note; REALLY hate the new forum software. With all the untrusted Google and Amazon javascript (which my company firewalls), it's a pain for me to even log in let alone post replies. (And I wonder if I'm the only person in the world sick to death of all the unnecessary ajax garbage...)
Anywho, used Kingo, rooted and unrooted a few times, until I finally acquired complete root on the thing. Once I did, I could run Samba, and once that worked, I could more easily transfer files and apks to the tablet.
Still don't understand why it was left in such a...weird...state - having root by default in adb is just a scary thing!
thanks for the information. I tried doing that but I encountered various problems. Eventually, after trying to do it manually, I totally screwed up the device. Now it won't boot.. I still have access to adb. I need to flash this thing. Do you know what the stock ROM is?
mfurlend said:
Do you know what the stock ROM is?
Click to expand...
Click to collapse
No...I can give you the Kernel version info (3.0.36+ [email protected] #48) and build number (rk3168_k11_4.2.2_v20131230), but other than that no clue.

Need help manually rerooting my phone using ADB to push files

Okay so I was told to come here because my phone doesn't have its' own forum yet (Not at all surprising..), so I'm just going to quote my post back on the other thread that told me to come here instead.
Mc Fow1er said:
Okay so I've had this phone for little over 10 months now and within that time I've managed to achieve root (unreliable but it works at the very least) in that time as well as learned a fair amount about Linux and android alike (Not a whole lot but I know some stuff) though I've now come to the point of I actually want to give my phone a proper root instead of this faulty solution I have currently. I (barely) managed to get my phone rooted using Kingoroot and I've played plenty with my phones' innards in that time, removed system apps, added my own selection to the system but some apps in my phone that use root don't work even with root permission granted which is why I'm wanting to replace Kingoroot with ChainFires' SuperSU binaries, could anybody help me with simple instructions for someone who doesn't actually know very much regarding how root and SU bins work inside of android? My phone's using 4.4.2 kitkat.
Just a few disclaimers first to get misconceptions out the way:
1. I do not have a custom recovery nor is one available for my phone (Samsung galaxy young 2 (SM-S130H) for those who want to know)
2. I'm currently unable to use the internet on my phone as I lack Wi-Fi to do so (router is dead) so I'm manually installing app packages through ADB, so if something needs an internet connection on my phone it's not going to work for me, for now..PC still has net access.
3. I have access to ADB shells' SU but not ADB root so I hope you don't need that from me.
4. This phone does not have a fastboot mode. (That I can find anyway..) Only a download mode from what I've found.
Can anybody help me out with telling me what I'll need to be doing in regards to getting this done?
Click to expand...
Click to collapse
So, can anyone here knowledge on the matter can assist me with this instead of me having to figure it out on my own?

[Q] cloudfone Q005G not properly rooted?

You can skip this. Unless you're truly concerned :victory:
Hi guys. I'm new here. I searched on the forums and in google about rooting Q005G and no correct results. Therewas this guy searching for rooting a geo 47i something and other models. The closest answer could be here: http ://www .infotechmaestro. com/2016/01/how-to-root-cloudfone-kitkat-android.html?m=1 (remove spaces. I cant post urls, i think) but still, i can't trust it yet.
I am looking for a correct way to root a Q005G cloudfone properly because i rooted with kingoroot on my pc and, yeah, I finished it and all. It was easy... too easy.. which was suspicious. Anyway, you might say "your device is not compatible with kingoroot", well, it says on their page their root is compatible with anything before 5.1 android, and mine was a 4.4.2 kitkat. Also, it said there it is compatible with cloudfone. So I went ahead. Anyway, after "rooting", I tried to download a root verification/checker app and a terminal emulator. First I tried using the checker, and it says root was not properly implemented or smth. Then I checked the terminal, tested it first, then typed "su". It doesnt even show anything after, but I noticed $ was before the "su".
I unrooted (dont think it was even rooted in the first place) it and deleted some apps that was supposed to be prepared fpr my grand rooting, like the titanium backup, es file explorer, adaway, etc.
Any way to fix this? Thanks for any help and salamat :good:
Also, there may be typos and all. I'm using my mobile. And I'm not too great at speaking english.

Categories

Resources