Remove All Ads from XDA

[STABLE][2016.07.05] SuperSU v2.76 [CLOSED]

11,223 posts
Thanks Meter: 86,610
By Chainfire, Senior Moderator / Senior Recognized Developer - Where is my shirt? on 9th March 2012, 09:20 AM
Thread Closed Email Thread

Stable releases have moved to the new thread here:


SuperSU is the Superuser access management tool of the future

!!! SuperSU requires a rooted device !!!

SuperSU allows for advanced management of Superuser access rights for all the apps on your device that need root. SuperSU has been built from the ground up to counter a number of problems with other Superuser access management tools.

Features include:

- Superuser access prompt
- Superuser access logging
- Superuser access notifications
- Per-app notification configuration
- Temporary unroot
- Deep process detection (no more unknowns)
- Works in recovery (no more segfaulting)
- Works when Android isn't properly booted
- Works with non-standard shell locations
- Always runs in ghost mode
- Wake on prompt
- Convert to /system app
- Complete unroot
- Backup script to survive CyanogenMod nightlies
- Icon selectable from 5 options + invisible
- Theme selectable from 4 options
- Launch from dialer: *#*#1234#*#* or *#*#7873778#*#* (*#*#SUPERSU#*#*)
NOTE: Not all phones take both codes. On some phones you need to use single *# instead of double *#*#

The Pro version additionally offers:

- OTA survival mode (no guarantees)
- Full color-coded command content logging (input/output/error)
- Per-app logging configuration
- Per-app user override
- Grant/deny root to an app for a set amount of time
- PIN protection
- Per-app PIN protection
- Adjust auto-deny countdown


For extra performance, disable notifications. Logging does not impact performance much.


Yes, you are allowed to embed the (free, non-Pro) SuperSU apk and su binaries in your own custom ROMs ! As is standard (and done by the attached ZIP), normal is to use /system/app/Superuser.apk for the apk and /system/xbin/su for the binary.

Want to help translate ?

See SuperSU project on GetLocalization !


SuperSU on Google Play (free)

SuperSU *Pro* on Google Play (Pro/donate addon, requires free version)

TWRP / FlashFire installable ZIP:
Note that if you are already rooted, installing through Play is by far the easiest way to install SuperSU !

Issues installing / updating binaries ?

There's a thread for that:


Want to learn how to use "su" correctly from your own apps ? How-To SU !

ROM Developers

Feel free to include the (free version, unmodified) SuperSU APK in your ROMs. You do not need to ask me for permission to include it.

It would be nice if you would include minor advertisement in your ROM description, such as "Powered by SuperSU", or "Please support SuperSU". This is not a requirement, merely a request.
Attached Thumbnails
Click image for larger version

Name:	screenshot_inapp.png
Views:	1427159
Size:	47.0 KB
ID:	938854   Click image for larger version

Name:	screenshot_apps.png
Views:	927030
Size:	74.5 KB
ID:	938855   Click image for larger version

Name:	screenshot_apps_2.png
Views:	875490
Size:	69.2 KB
ID:	938856   Click image for larger version

Name:	screenshot_logs.png
Views:	762053
Size:	59.8 KB
ID:	938857   Click image for larger version

Name:	screenshot_logs_2.png
Views:	732935
Size:	78.5 KB
ID:	938858   Click image for larger version

Name:	screenshot_settings.png
Views:	695058
Size:	46.8 KB
ID:	938859   Click image for larger version

Name:	sacreenshot_pin.png
Views:	680050
Size:	56.5 KB
ID:	938860  
The Following 4,484 Users Say Thank You to Chainfire For This Useful Post: [ View ]
9th March 2012, 09:25 AM |#2  
Chainfire's Avatar
OP Senior Moderator / Senior Recognized Developer - Where is my shirt?
Thanks Meter: 86,610
Donate to Me
Who, what, why ?!
As you may know, I make a lot of apps that use or require root. I also release rooted kernels. I run into a lot of issues with existing Superuser tools. More importantly, a lot of my users run into these issues as well and then email me about it. So I decided to do something about this. Doesn't mean these were problems you have ever seen, or will ever see.

And thus, I have written - pretty much from scratch - SuperSU. I have taken the su binary command line parameter parsing from Superuser, to make sure that is compatible. Aside from that, it is completely rewritten, because how I wanted to do a number of things was incompatible with the existing codebase.

This is not a stab at ChainsDD, or his skills. He has done great work and will no doubt continue to do so, however, I felt the need for some of these changes, and thus made them. This is an early release, so I expect there will be some unforseen issues somewhere.

From now on, all CF-Root and Mobile ODIN Pro (EverRoot) releases will be built around SuperSU.

Please note that SuperSU is not hardened-security-tested or reviewed, and may be exploitable (... as may other solutions ...).
The Following 1,040 Users Say Thank You to Chainfire For This Useful Post: [ View ]
9th March 2012, 09:25 AM |#3  
Chainfire's Avatar
OP Senior Moderator / Senior Recognized Developer - Where is my shirt?
Thanks Meter: 86,610
Donate to Me
01.10.2017 - v2.82 - SR5 - RELEASE NOTES
- suinit: Fix (flashed) TWRP 3.1.1 compatibility on Pixel (XL)
- FBE: allow FBE devices to boot unencrypted (unless KEEPFORCEENCRYPT is set)

18.09.2017 - v2.82 - SR4 - RELEASE NOTES
- ZIP: Fix an incompatibilty with CFAR
- ZIP: Fix slot detection breaking if no /vendor present
- ZIP: If unmounting fails, retry lazily
- sukernel: Fstab patch: fix case where verify removal could break slotselect
- sukernel: Adjust system_root cpio import
- sukernel: Detect and use stock boot image backups created by other tools
- supolicy: Add some Oreo policies
- suinit: Fix boot case where bootloader unexpectedly doesn't enforce dm-verity

13.08.2017 - v2.82 - SR3 - RELEASE NOTES
- sukernel: Fix external sdcard issue on Samsung devices running custom ROMs
- launch_daemonsu: Abort if su binaries missing
- ZIP: Fix FlashFire compatibility in SBIN mode
- SBIN: Add /sbin/supersu/bin and /sbin/supersu/xbin to PATH (root shells only)
- SBIN: Fix policies for /sbin-based services
- SBIN: Fix /sbin-based symlinks not always properly resolving
- ZIP: Add support for bzip2/lz4/lzo/lzma/xz compressed kernels and ramdisks (lz4 @ 1.5.0 format)

08.08.2017 - v2.82 - SR2 - RELEASE NOTES
- ZIP: Support order-swapped /etc/recovery.fstab
- ZIP: Cope with /system being a symlink to /system_root/system
- suinit: Fix remount /system r/w issue on Pixel(XL)+OPreview
- sukernel: Fix pre-patched ramdisk detection for reduced system_root footprint
- ZIP+suinit: Fix recovery going to ramdump on Pixel(XL)
- Added "BIND SBIN" mode, mounts files in /sbin instead of /su, stores files directly in /data instead of su.img (new default for O+)
- Systemless: all file contexts are restored at boot, see /path/to/su/mount/file_contexts

09.06.2017 - v2.82 - SR1 - RELEASE NOTES
- ZIP: Detect AVB signature on input boot image, and sign output image accordingly (force with SIGNBOOTIMAGE, custom keys in /tmp/avb)
- ZIP: Samsung/7.0+: if /data is not currently encrypted, disable encryption (unless KEEPFORCEENCRYPT or REMOVEENCRYPTABLE are set)
- ZIP: Detect TWRP UI slot switch (Pixel/XL: 3.1.0-RC2+)
- ZIP: Further improve /system device detection
- ZIP: Support compiling sepolicy from split CILs
- ZIP: Kernel patch: support LZ4 compressed kernels (new format only)
- ZIP: Mount /vendor
- ZIP: Add /vendor/lib[64] to LD_LIBRARY_PATH
- ZIP: Initial Pixel+ODP2 support
- ZIP+APK: Fixes in boot partition detection
- sukernel: Allow cpio-add of 0-byte files
- sukernel: Add dtb (in-kernel only) related features
- suinit: Improve logging
- suinit: Support pre-mounting /system and /system_root (ODP2+)
- sukernel+suinit+ZIP: Reduce system_root footprint by dynamically importing entries at boot
- supolicy: Adjustments for ODP3

28.05.2017 - v2.82 - Work-In-Progress / TEST-1
- supolicy: Newer libsupol version used
- su: Fix sdk parameter not always being passed to supolicy in system mode

26.05.2017 - v2.82 - CCMT - RELEASE NOTES
- su: Fix su.d scripts running in the wrong mount context (introduced by ODP sdcardfs fix)
- CCMT: Remove Feedback screen and associated permissions

(v2.81 == v2.79 SR3 with patched version code)

24.05.2017 - v2.80 - CCMT
- CCMT: Update language files
- CCMT: Update guide screen
- CCMT: Update privacy policy screen
- CCMT: Updater: remove 4.3 and 5.0 specific upgrade messages, replace with generic; and detect if root must be manually updated
- CCMT: Add feedback screen
- CCMT: Drop support for Android 2.1 and 2.2. Minimum is now 2.3 (SDK 9, up from 7)

11.04.2017 - v2.79 - SR5 - Not publicly released
- su: Update mount namespace separation code to improve sdcardfs compatibility
- su: Fix kernel panic on ODP1/2 on 5X/6P
- su: Fix ODP1 compatibility on Pixel (XL)
- launch_daemonsu: Revert previous ODP1 work-around
- sukernel: Add option to patch out optional /data encryption (encryptable)
- suinit: cleanup /boot
- ZIP: Get boot image from fstab last-effort
- ZIP: Add REMOVEENCRYPTABLE flag to force disable encryption on newer Samsung firmwares

23.03.2017 - v2.79 - SR4 - RELEASE NOTES - ODP1/6P/5X only
- ZIP: Fix slow /dev/random on some devices, apparently freezing install at "Creating image"
- ZIP: Fix LD_LIBRARY_PATH for hex-patch execution
- supolicy: Fix applying deferred allow rules
- supolicy: Fix setting impossible XPERM causing policy corruption
- supolicy: Add policies for ODP1
- launch_daemonsu: Work-around kernel panic on ODP1 on 5X/6P. Forces service mode for ODP1 on all devices.

14.01.2017 - v2.79 - SR3 - RELEASE NOTES
- Fix erroneously deleting SuperSU's copy of app_process on 6.0 since 2.79-SR1
- GUI: Fix app_process requirement detection when supersu context used
- Fully eliminate sugote binary, no longer needed due to SELinux handling improvements in earlier versions
- Support /system/xbin/sush as default shell
- Adjust LD_PRELOAD filtering to exclude suhide's libraries
- ZIP: Motorola: default to systemless mode

03.01.2017 - v2.79 - SR2 - RELEASE NOTES
- supolicy: fix some segfaults(NPEs) in pre-7.0 sepolicy handling
- ZIP: write boot block device once instead of twice (@_alexndr)
- (c) 2017 + CCMT

22.12.2016 - v2.79 - SR1 - RELEASE NOTES
- Expand Samsung detection
- GUI: reworked portions to work with 'supersu' context on 7.0+
- GUI: fix binary update notice when superuser disabled by user in some cases
- su: reworked portions to work with 'supersu' context on 7.0+
- su/GUI: improve responsiveness when device busy on 7.0+
- sukernel: fix cpio restore failure with very short filenames
- sukernel: no longer patches file_contexts(.bin)
- sukernel: revert force seclabel (no longer needed with 'supersu' context)
- supolicy: add "create", "auditallow", "auditdeny" policy commands
- supolicy: support "*" for permission/range parameter of "allow", "deny", "auditallow", "auditdeny", "allowxperm" policy commands
- supolicy: --live/--file no longer apply default patches if custom patches are supplied
- supolicy: --sdk=X option added (required for 7.0+)
- supolicy: reworked all SELinux rules for 7.0+, run as 'supersu' context
- ZIP: Separate slotselect and system_root logic
- ZIP: Adjust system/system_root device and mount-point detection
- ZIP: Fix minor errors in documentation
- ZIP/frp: Explicitly label /su

15.12.2016 - v2.79 - CCMT
- CCMT: Change "Upgrade to Pro" button color

30.11.2016 - v2.78 - SR5 - RELEASE NOTES
- Fix shell-based scripts/services possibly not being executed on 7.x firmwares
- Add SecurityLogAgent to Samsung KNOX detection
- sukernel: force seclabel

15.11.2016 - v2.78 - SR4 - RELEASE NOTES
- sukernel: improve FBE detection
- suinit: TWRP compatibility on slot-based systems
- ZIP: TWRP compatibility on slot-based systems

03.11.2016 - v2.78 - SR3 - RELEASE NOTES
- Fix 'Full Unroot' on slot-based systems
- sukernel: replace system symlink with bind mount
- sukernel: add missing slot check for system_root import
- sukernel: fix ramdisk backup segmentation fault
- supolicy: adjust priv_app policy to be able to call su
- launch_daemonsu: adjust su.img size detection
- ZIP: improve loop device setup
- ZIP: add factory reset protection (FRP variable, default if slots used)

29.10.2016 - v2.78 - SR2 - RELEASE NOTES
- File-based-encryption support
- CCMT: Add privacy policy dialog
- CCMT: Update translation files
- su+gui: support /system_root paths
- sukernel: add kernel binary extract/replace
- sukernel: add kernel cmdline extract/replace
- sukernel: add system_root import
- sukernel: add slot-kernel patch
- sukernel: support /boot paths
- suinit: new binary component
- launch_daemonsu: restructure to support /su in initramfs or system_root
- ZIP: Support systemless on 5.0 (requires 3rd party patches)
- ZIP: Support for A/B slot systems with / inside system partition

15.09.2016 - v2.78 - SR1 - RELEASE NOTES
- subinary: Adjust app_process detection with manipulated mount namespaces
- subinary: Adjust Zygote PID detection to prefer 64-bit
- subinary: Fix possible NPE in LD_PRELOAD sanitization
- subinary: In systemless mode, ensure PATH contains /su/bin and /su/xbin
- supolicy: Ensure zero-on-alloc for new rules
- supolicy: Fix parsing allowxperm with multiple sources/targets in a single definition
- ZIP/Systemless: Give su.d 60 seconds to execute (from 4 seconds)

01.09.2016 - v2.78 - CCMT
- CCMT: Change default icon from Emblem to Material
- CCMT: Update detection activity
- CCMT: Update guide activity
- CCMT: Update translation files

27.08.2016 - v2.77 - BETA - RELEASE NOTES
- ZIP/Systemless: Support for hexpatches (Note7)
- ZIP/Systemless: Additional logging in daemonsu launcher script

05.07.2016 - v2.76
- Clear logs now asks for confirmation
- Fixed memory leak that could ultimately lead to reboots or root not working
- Fixed an issue that might have causes root loss on temporary unroot
- ZIP/Systemless: /data/su.img resized from 32M to 96M, to make sure enough space is available for systemless modes such as xposed
- ZIP/Systemless: launch daemon on post-fs-data, if supported by device (6.0+, fallback to service)
- CCMT: Added guide screen for new users

19.05.2016 - v2.74-2 - BETA - RELEASE NOTES
- supolicy/sukernel: Prevent security updates to SELinux from being applied
- sukernel: backup and restore modified ramdisk files, to be able to re-root if boot image backup got lost
- ZIP: Only show TWRP warning on TWRP v2.x

10.05.2016 - v2.72 - BETA - RELEASE NOTES
- Add support for ChromeOS boot images (Pixel C)
- supolicy: Fix logging to logcat for some processes on some firmwares
- supolicy: Fix fsck of /data/su.img being denied on some firmwares
- ZIP: Also read flags from /cache/.supersu (aside from /data/.supersu and /system/.supersu)

31.03.2016 - v2.71 - BETA
- Massive speed improvement in handling permissive domains
- N/RC/BETA merged with normal BETA release

14.03.2016 - v2.70 - BETA RC - RELEASE NOTES
- Rewrote re-enabling root after temp-disable
- supolicy: Improve permissive domain handling
- N: Disable forced encryption
- N: Fix remounting /system for some apps (relatime becomes noatime for ro mounts)
- ZIP: call users scripts without setting LD_LIBRARY_PATH

13.03.2016 - v2.69 - BETA RC - RELEASE NOTES
- su: Escape from audit-based safe mode
- supolicy: Update to new v30 sepolicy format
- supolicy: Add support for special case M sepolicy format
- supolicy: Add support for XPERM rules
- sukernel: Add support for binary version of file_contexts
- ZIP: Create mount point in ramdisk instead of script
- ZIP: Add support for binary version of file_contexts
- BINDSYSTEMXBIN: Now disabled by default
- launch_daemonsu: Perform fsck before mounting

28.02.2016 - v2.68 - BETA - RELEASE NOTES
- su: Add -mns/--mount-namespace option
- su: Fix issue with sdcard on Note4/5.1
- sukernel: Fix issue where writing to /dev could truncate early at 64k barriers
- supolicy: Fix logcat issue on Omni/CM/etc
- supolicy: Disable AUDITDENY entries, to make debugging easier for devs
- supolicy: Extend fake-permissive to work with new Samsung firmwares
- ZIP: Fix TWRP log truncating and screen output on installs embedded in other ZIPs
- ZIP: Improve loopback device setup handling
- ZIP: Move variable reading to after /system and /data have been mounted
- ZIP: Added call to custom patcher script, if any (/data/
- ZIP: chmod 0751 /su/bin

21.01.2016 - v2.67 - BETA
- (systemless) Improved deep sleep fix for Samsung 5.1+
- (systemless) Added fallback method to mounting /su on system boot
- supolicy: fix bug copying system_server capabilities to init
- supolicy: replaced transitions: copy capabilities and attributes, silence audits
- supolicy: work-around shell-based services being executed as undefined_service on Samsung 5.1+
- sukernel: refuse to patch ChromeOS boot image
- FSTABSYSTEMRW: flag removed; worked around remount /system r/w issue
- ZIP: improved handling of loop devices
- ZIP: detect boot image partition being a symlink to a file on /data, and skip wipe if so
- Updated translation files

03.01.2016 - v2.66 - BETA
- (systemless): Add deep sleep fix for Samsung 5.1+
- supolicy: Adjust Samsung 6.0 init shell
- ZIP: Patch recovery SELinux policy
- ZIP: Improve su.img mounting

Changelogs continue in the next post ...
The Following 216 Users Say Thank You to Chainfire For This Useful Post: [ View ]
9th March 2012, 09:25 AM |#4  
Chainfire's Avatar
OP Senior Moderator / Senior Recognized Developer - Where is my shirt?
Thanks Meter: 86,610
Donate to Me
Changelogs continued from the previous post ...

26.12.2015 - v2.65
- (systemless) Add /su/xbin to su.img and PATH
- ZIP: Fixed force close issue when custom boot image is used
- ZIP: Reworked remounting (prevents bugged write to r/o /system on flo)
- ZIP: Added warning that first reboot may take a few minutes/loops

20.12.2015 - v2.64 - BETA
- (systemless) Detect more boot image partition names
- (systemless) Blank partitions before writing to them
- (systemless) Ask to restore boot and recovery images on full unroot
- (systemless) Implement "uninstall competing superuser apps"
- (systemless) Samsung: prevent "KERNEL IS NOT SEANDROID ENFORCING" warning
- (systemless) Cleanup system install properly if present, fixes a number of possible bootloops
- ZIP: 6.0+: Detect firmwares that can reload sepolicy from /data and use system-based root on these ("allow init kernel:security { load_policy }")
- supolicy: Additional SELinux patches for M (reduced logging only)
- Update translations

10.12.2015 - v2.62 - BETA
- (systemless) Do not attempt to patch fstab symlinks
- (systemless) Implement feature to en/disable Superuser
- (systemless) Poor man's overlay on /system/xbin for compatibility reasons (hopefully temporary) [BINDSYSTEMXBIN]
- (systemless) ZIP: Add reading setup variables from /system/.supersu and /data/.supersu
- (systemless) ZIP: Add option to patch /system to rw in fstab [FSTABSYSTEMRW]
- (systemless) ZIP: Added call to custom patcher script, if any (/data/
-2 (systemless) ZIP: Fix calling wrong script name for custom patcher script
-2 (systemless) ZIP: Improve APK overwrite
-3 (systemless) ZIP: Do not move backups from /cache to /data, just copy them

07.12.2015 - v2.61 - BETA