I know that there is many tools apps etc to disable or hide SU.
I decide to make this just because those don't work on my device and or CyanogenMod/LineageOS ROM that I use, so I assume this happens to other in CyanogenMod/LineageOS users too.
This is only to CyanogenMod/LineageOS SU binary
No it doesn't support Xposed
What is iSu?
A simple app to deactivate SU at will on CyanogenMod/LineageOS and CyanogenMod/LineageOS base ROM's.
I test this on Marshmallow and Nougat CM base ROM's, also Supports Lollipop, Kit Kat and older not supported.
How it works?
A simple apk with some instructions and one main switch, to activate or deactivate SU, to pass safety net or wherever app you use that doesn't like ROOT, the app has a builtin app monitor that can be used to automatic activate or deactivate SU when the selected app starts or stops be used.
There is no change need to be made to the system or kernel to use the app.
But be aware ! on Marshmallow or under is need to be made one simple change to kernel services (add a iSu service) to be able to reboot with SU deactivated and be able to have it enable after...
Without the kernel change you can use the app enable disable SU but if you reboot with SU deactivate or a random reboot happens the app will no be able to enable SU after.
The service is a normal service is just like SU service but works only with iSu implementation.
On Nougat the app can set the service without any changes to the kernel.
Some CyanogenMod/LineageOS Use different SU version name
I restrict the app to only work with cm-su but some CyanogenMod/LineageOS base ROM like to change everything included su version name like the below, if the ROM you use is CyanogenMod/LineageOS and have a different name post on the thread so I can add that option to the app.
- If after deactivate SU using the app you can pass safety net check, but can't use this or that app because it detects you have ROOT try this post workaround (Click here), simple explain some apps are using some build.prop flags that exist only on ROOT devices to detect a rooted ROM, changing build.prop is really simple just fallow that post, if that doesn't help post on the thread the affected app.
- After flashing the kernel reboot support or the cmdline Patch the device may not boot it is not perfect to all devices but was tested in many device and is fully working, if your device doesn't boot after flashing just reverted by re-flashing yours current ROM .zip or by restoring a TWRP backup of system and boot made before had flashing the .zip.
- If you use iSu to deactivate SU and lost SU support try a reboot if you have iSu kernel support, if you don't have kernel support re-flash yours current ROM .zip or restore a TWRP backup of system and boot from before had used the app to deactivate SU.
Download Folder: Click Here
There is four files:
Install the apk as a normal app.
On iSu V2.2 or up is only need reboot support for Marshmallow or under.
The kernel reboot support use only one, this files avoid you losing SU after a reboot with SU deactivated.
Use the one base on yours current Selinux status to check on your device look in settings > About a phone > SELinux Status if is enforcing or permissive, some CM ROM Run with selinux in Permissive so check yours.
The below are obsolete after V3.6 of the app see old_version folder in main download folder for those files
The kernel_cmdline is only need to some devices that after deactivating SU with the app still can't pass the safety check, Google is using kernel and bootloader arguments to determined that the user modify the stock SW(AKA is using custom ROM) and prevent from passing as "safe", this add extra safe arguments to cmline and help to achieve the pass current it only support some device (Nexus and Motorola, maybe other post on the thread device/vendor if the zip help you)
This is only for those that have apps that use rootbeer SU detection...
explain in this post (Click here).
After flashing defaultprop_Patch zip the user will no longer have access to the option in Settings > Developer options > Root access
But that is not a problem as the same zip will enable root by default so you can use without changing that option.
Updating CM nightly or any ROM update of any CM base ROM will remove any of the zip affects, so is need to flash those .zip with any ROM update, may be need to do it also with some custom kernel from developer that use a boot.img to share the kernel(check yours kernel zip content to know).
If you forget to flash the .zip in a update and have lost ROOT don't worry just go back to recovery and flash it after the reboot all will be good.
iSu, App for all CyanogenMod/LineageOS devices (see above for details)
All Contributors can be see in github click here
bhb27, I use osm0sis Anykernel2 for the kernel zip
App Source Code: https://github.com/bhb27/isu
Current Stable Version: Check latest version
Last Updated Check latest version