5,606,530 Members 33,537 Now Online
XDA Developers Android and Mobile Development Forum

[APP] Voodoo OTA RootKeeper (and temporary un-root)

Tip us?
 
supercurio
Old
(Last edited by supercurio; 24th July 2013 at 11:32 PM.)
#1  
supercurio's Avatar
Senior Recognized Developer - OP
Thanks Meter 5063
Posts: 3,528
Join Date: May 2010
Location: Chambéry

 
DONATE TO ME
Default [APP] Voodoo OTA RootKeeper (and temporary un-root)

Hi Everyone


Because I'm lazy and was tired re-rooting manually my devices after installing manufacturers OTA updates, I wrote an app that protects root in one touch event.
It is available for free on Android market and its source code is Open Source under WTFPL (github).

Translations and code contributions are welcome.

Features: :

- Backup root before OTA & Restores it right after.
- Temporary un-root your device.

Requirements:

- Device must be already rooted.
- Protection is effective only for devices with Ext2/Ext3/Ext4 /system partition
- Non ExtFS devices will still be able to use the temporary un-root feature

OTA RootKeeper will detect what's possible or not and display available options accordingly.

Typically works for: Nexus S, Every Honeycomb tablets.
On ExtFS partition, root survives anything but true formating or partition wiping.
It means some update tools like KIES/Odin for Samsung device will wipe the whole thing anyway because they write complete new partition.

I needed this app so I wrote it, hopefully it will be useful to you too!

Android 4.3 Notes:

Based on Android 4.3 release notes, on Enterprise and Security, Restrict Setuid from Android Apps, su binaries and Superuser apps designed for previous Android generation will simply not work on 4.3:

Quote:
Restrict Setuid from Android Apps

The /system partition is now mounted nosuid for zygote-spawned processes, preventing Android applications from executing setuid programs. This reduces root attack surface and likelihood of potential security vulnerabilities.
It means preserving root with OTA Root Keeper won't be possible anymore as new rooting techniques rely on more than just a setuid su binary in /system.
I'll look into solution of course to preserve the functionality if possible, but until then please follow Chainfire's job on SuperSU betas.
The Following 71 Users Say Thank You to supercurio For This Useful Post: [ Click to Expand ]
 
nanujra
Old
#2  
Senior Member
Thanks Meter 10
Posts: 134
Join Date: Oct 2010
Aw, so its a no go on my sgs2..

Thanks for the amazing work as always anyways!
HTC Desire
SGSII
 
supercurio
Old
#3  
supercurio's Avatar
Senior Recognized Developer - OP
Thanks Meter 5063
Posts: 3,528
Join Date: May 2010
Location: Chambéry

 
DONATE TO ME
Quote:
Originally Posted by nanujra View Post
Aw, so its a no go on my sgs2..

Thanks for the amazing work as always anyways!
You're welcome

On Galaxy S II, temporary unroot is working and allows you to "hide" root from stupid apps refusing to work as expected after detecting root.
Its not really hidden but so far, those stupid apps (like Google movies) use stupid detection routines.
The Following 5 Users Say Thank You to supercurio For This Useful Post: [ Click to Expand ]
 
crypticc
Old
#4  
Senior Member
Thanks Meter 105
Posts: 1,057
Join Date: Aug 2009
Location: London
Supercurio. do you think you can backup Superuser.apk too please. I can see where it needs to be done in github but I'm no expert in compiling apk. or Will apkmanager work for that and i Will have a go at that.
 
supercurio
Old
#5  
supercurio's Avatar
Senior Recognized Developer - OP
Thanks Meter 5063
Posts: 3,528
Join Date: May 2010
Location: Chambéry

 
DONATE TO ME
Quote:
Originally Posted by crypticc View Post
Supercurio. do you think you can backup Superuser.apk too please. I can see where it needs to be done in github but I'm no expert in compiling apk. or Will apkmanager work for that and i Will have a go at that.
Why backup Superuser.apk?

If it's not installed, you already get automatically a button to access the market page automatically.
When you update your device via an OTA, Superuser.apk is not uninstalled.

Please describe your need
The Following User Says Thank You to supercurio For This Useful Post: [ Click to Expand ]
 
crypticc
Old
#6  
Senior Member
Thanks Meter 105
Posts: 1,057
Join Date: Aug 2009
Location: London
Quote:
Originally Posted by supercurio View Post
Why backup Superuser.apk?

If it's not installed, you already get automatically a button to access the market page automatically.
When you update your device via an OTA, Superuser.apk is not uninstalled.

Please describe your need
Thanks for replying.

Busybox because is part of xbin and could be lost.

superuser apk because that would be a full unroot and reroot in one app. E.g. If I want to unroot during work hours and reroot after say if work sync calendar app doesn't like root.

Or do you think this will be a nice way to cut my teeth on android development? I see two java code places that seem to backup and then restore.
 
supercurio
Old
#7  
supercurio's Avatar
Senior Recognized Developer - OP
Thanks Meter 5063
Posts: 3,528
Join Date: May 2010
Location: Chambéry

 
DONATE TO ME
Quote:
Originally Posted by crypticc View Post
Thanks for replying.

Busybox because is part of xbin and could be lost.

superuser apk because that would be a full unroot and reroot in one app. E.g. If I want to unroot during work hours and reroot after say if work sync calendar app doesn't like root.

Or do you think this will be a nice way to cut my teeth on android development? I see two java code places that seem to backup and then restore.
I never noticed an OTA that destroyed xbin directory? Do you have an example? (please show me the updater-script so I can study it)

Why I made this utility is because /system permissions are reset via recursive chmods during OTAs: what causes su binary to not be efficient anymore.
But saving files in not the main purpose. As long as you're rooted, you can re-install busybox in /system anyway.
The Following User Says Thank You to supercurio For This Useful Post: [ Click to Expand ]
 
crypticc
Old
#8  
Senior Member
Thanks Meter 105
Posts: 1,057
Join Date: Aug 2009
Location: London
Ah. I am thinking odin not ota

Ta
 
supercurio
Old
#9  
supercurio's Avatar
Senior Recognized Developer - OP
Thanks Meter 5063
Posts: 3,528
Join Date: May 2010
Location: Chambéry

 
DONATE TO ME
Quote:
Originally Posted by crypticc View Post
Ah. I am thinking odin not ota

Ta
With Odin the whole partition is wiped, I can't backup/restore root − and as a result restore busybox either because it would require root to do so.
The Following User Says Thank You to supercurio For This Useful Post: [ Click to Expand ]
 
crpeck
Old
#10  
Member
Thanks Meter 11
Posts: 81
Join Date: Jul 2011
Location: Williamsburg, VA
Any reason not to backup su to /data instead of /system? I've tried this on a Bionic and it works just fine. I tried this:
adb shell
su
cp -p /system/bin/su /data/su
rm /system/bin/su /system/xbin/su
exit - reboot phone
adb shell
/data/su
I'm root.
Seems like /data has a better chance of being untouched and as long as it's mounted correctly that copy of su will be there and executable.

The Following User Says Thank You to crpeck For This Useful Post: [ Click to Expand ]
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes