[Q] issues post-boot with su - Android

So i modded a firmware for the yifang m7 android tablet running android 2.1
added superuser.apk and su, set the sticky suid root bits on the su binary and when i open a terminal on the tablet flashed with the firmware, i get "su: permission denied" when executing su.
the system.img is on a nand, in a cramfs filesystem image.
i'm fresh out of ideas.

Related

Superuser prompt doesn't pop up when I type su in adb shell

Whenever I type any command in the command line that requires root (e.g. adb remount) or run script as root in script manager, I get a 'permission denied' immediately. The superuser app just doesn't pop up.
I bought the tab in China and rooted it according to the instructions in the forum. I don't know why some apps (e.g. root explorer) will pop up the su window but others won't.
It seems that my tab is partially rooted. Here is the result of Root Checker:
Code:
Root Access is not properly configured or was not granted.
Superuser.apk - com.noshufou.android.su - version 2.3.6 is installed!
System Environment PATH: /sbin /vendor/bin /system/sbin /system/bin /system/xbin
The adb binary is set to default shell user access as a standard non-root user
Standard su binary location: ls -l /system/bin/su:
/system/bin/su: No such file or directory
Standard su binary location: ls -l /system/xbin/su:
-rwsr-sr-x root root 26336 2008-08-01 20:00 su
Alternate su binary location: ls -l /sbin/su:
/sbin/su: Permission denied
Alternate su type binary location: ls -l /system/xbin/sudo:
/system/xbin/sudo: No such file or directory
SU binary not found or not operating properly
Is it safe to reapply the root.zip?
Forgot to tell you that my tab was bought in China with HC 3.1 preinstalled.
After some trials. I think I'm closer to the cause of this problem.
I've flashed the latest oc kernel and after that adb remount worked without a glitch.
But after I flash a zip other than root.zip in recovery, be it kernel.zip, su_busybox_tools.zip or google_servicepack.zip (Samsung China has deprived google service off the system), the superuser icon in app drawer is becomes 4 times smaller (2 time for both height and length) than the superuser app installed by root.zip.
There seems to be something wrong with this version of superuser app. Whenever I open an app that requires root access, the superuser window is unable to pop out. As a result, I cannot use that app.
But if I reflash the root.zip. The big-icon superuser app is back. And other apps can revoke it most of time. However, it is not perfectly stable. Somethimes, it still failed to be revoked.
Any thought on this?
su from the busybox pack installs a new su app which only monitors /system/xbin/su executable, not the /system/bin/su executable the root.zip provides.
You can either remove the /system/bin/su executable (and optionally create a link to the /system/xbin/su executable in it's place) or re-install the su app from the root.zip file.
Thanks, I've flashed latest starburst rom and all is set.

[Q] Not rooted anymore?!!

i Rooted my phone a few months ago and installed a few roms but didnt like any of my options so i kept the phone rooted with the stock look. now i want to try a new rom and my phone is telling me my phone isnt rooted any more...
any suggestions??
What is telling you that you are not rooted? Like trying to run certain root apps? How did you root? Which bootloader? Does is say s-on or s-off?
Sent from the MIUI powered 3d
the rejection i am getting on rom manager is "an error occured while attempting to run privileged commands... sorry i am kinda a beginner on my 3D..rooting on my evo prior was so much simpler...and i used to use shoot me and all of a sudden it couldnt acess root permissions...
on my boot screen it says
s-off
hboot1.4.1000
radio 0.97.10.0530
ramseyattar said:
the rejection i am getting on rom manager is "an error occured while attempting to run privileged commands... sorry i am kinda a beginner on my 3D..rooting on my evo prior was so much simpler...and i used to use shoot me and all of a sudden it couldnt acess root permissions...
on my boot screen it says
s-off
hboot1.4.1000
radio 0.97.10.0530
Click to expand...
Click to collapse
Do you have superuser installed on your phone?
ramseyattar said:
the rejection i am getting on rom manager is "an error occured while attempting to run privileged commands... sorry i am kinda a beginner on my 3D..rooting on my evo prior was so much simpler...and i used to use shoot me and all of a sudden it couldnt acess root permissions...
on my boot screen it says
s-off
hboot1.4.1000
radio 0.97.10.0530
Click to expand...
Click to collapse
looks like your bootloader is still unlocked, which is a very good sign.
more than likely the permissions on your root access where changed at some point in time. either from loading a ROM or removing/adding superuser.apk incorrectly.
my application, root checker pro, will show all the necessary information in order to troubleshoot.
my guess would be, you'll probably need to install the superuser.zip file from recovery mode and that should add the /system/bin/su binary for Superuser.apk back and set the permissions as 4755 on the su binary. this is the most common and simplist method of properly restoring root access for Superuser.apk users.
if you want, feel free to post up the root checker pro results and we can specifically troubleshoot. hope that helps!
joeykrim said:
looks like your bootloader is still unlocked, which is a very good sign.
more than likely the permissions on your root access where changed at some point in time. either from loading a ROM or removing/adding superuser.apk incorrectly.
my application, root checker pro, will show all the necessary information in order to troubleshoot.
my guess would be, you'll probably need to install the superuser.zip file from recovery mode and that should add the /system/bin/su binary for Superuser.apk back and set the permissions as 4755 on the su binary. this is the most common and simplist method of properly restoring root access for Superuser.apk users.
if you want, feel free to post up the root checker pro results and we can specifically troubleshoot. hope that helps!
Click to expand...
Click to collapse
my results were:
Root Access is not properly configured or was not granted.
The following link is a suggested Guide for obtaining root access on your device. No guarantee the guide will work. Please use the guide with CAUTION!! Suggested guide for your device:
http://www.revolutionary.io/
Superuser.apk - com.noshufou.android.su - version 3.0.6 is installed!
System Environment PATH: /sbin /vendor/bin /system/sbin /system/bin /system/xbin
The adb binary is set to default shell user access as a standard non-root user
Standard su binary location: ls -l /system/bin/su:
---xr---wt root root 26324 2011-08-12 15:27 su
Standard su binary location: ls -l /system/xbin/su:
lrwxrwxrwx root root 2011-09-07 20:28 su -> /system/bin/su
Alternate su binary location:
/sbin/su: Permission denied
Alternate su type binary location:
/system/xbin/sudo: No such file or directory
SU binary not found or not operating properly
ramseyattar said:
my results were:
Root Access is not properly configured or was not granted.
The following link is a suggested Guide for obtaining root access on your device. No guarantee the guide will work. Please use the guide with CAUTION!! Suggested guide for your device:
http://www.revolutionary.io/
Superuser.apk - com.noshufou.android.su - version 3.0.6 is installed!
System Environment PATH: /sbin /vendor/bin /system/sbin /system/bin /system/xbin
The adb binary is set to default shell user access as a standard non-root user
Standard su binary location: ls -l /system/bin/su:
---xr---wt root root 26324 2011-08-12 15:27 su
Standard su binary location: ls -l /system/xbin/su:
lrwxrwxrwx root root 2011-09-07 20:28 su -> /system/bin/su
Alternate su binary location:
/sbin/su: Permission denied
Alternate su type binary location:
/system/xbin/sudo: No such file or directory
SU binary not found or not operating properly
Click to expand...
Click to collapse
Those results are perfect in that they show exactly what the issue is!
If you are familar with ADB, the process is very simple to fix your root access. I've done this many times! A basic but important process to learn, in my opinion.
Reboot to recovery, from a computer type, adb shell and issue two commands as follows:
mount /system /system
chmod 4755 /system/bin/su
go ahead and reboot.
Alternatively, if you're not familar with adb, the next simpliest approach, in my opinion would be to load the Superuser-3.0.6-efgh-signed.zip file onto your sdcard. reboot into recovery and "flash"/install the .zip file. The superuser.zip file will execute the above commands for you.
Run Root Checker Pro again and it should trigger superuser prompting whether or not to grant root checker access. go ahead and grant it root access.
Root Checker Pro should confirm you have root access and for the /system/bin/su line it should show an "s" in the middle of the permissions, example: rwxsr-xr-x root root 26324 2011-08-12 15:27 su . the "s" being in the middle is important as this is the setuid bit essentially granting the su binary superuser permission/access.
Reasons the permissions were changed on the /system/bin/su binary ... really hard to say but we can narrow down the causes. In order to change the permission, the process/device/application would need root access. Everything executed in recovery mode usually runs as root and many users don't inspect the updater-script file of the ROM .zip before they load.
Sometimes flashing ROMs, which aren't setup properly, will remove or set incorrect permissions removing the setuid bit on the su binary.
Also, flashing an OTA file would definitely remove the setuid bit on the su binary.
Hope that helps!

[Q] Rooting an Android device.

Ok, i know there is plenty of info about rooting various devices out there, however there i seem to locate anywhere that has an guide to actually rooting an Android system.
I understand to gain root access you must have a version of su that is compatible with your Kenel. I build an -eng build of AOSP and this includes a version of su into the system ( /system/xbin/su) with the following permissions.
Code:
-rwsr-sr-x root root 60112 2011-12-06 11:56 su
Its my understanding that each app in the Android system is essentially a individual user of the Linux system so i thought that all i would have to is grant the correct permissions for su so that any user can execute it.
Code:
chmod 755 su
-rwxr-xr-x root root 60112 2011-12-06 11:56 su
This does not seem to be the case, i have done this though when i try to su (from Terminal Emulator) i get this
Code:
$su
su: UID 10027 not allowed to su
$
Can anyone let me know what i am missing to allow root access for my applications?
Ok, so it is the version of su that is bad.
If you want to root any device get the correct version of su from here and include into your builds.

[Q] I want to root my unrooted device, but it already has root access

Okay. I have a weird situation in my hands.
I'm attempting to root a tablet that's not out yet (It's a dev version that I got my hands on). So I installed adb and fastboot on my computer to do that. But when I type "adb shell", the command prompt has a #, which should mean my device is rooted, right? Actually, it says the following: http://gyazo.com/734b7a0eb125d7be02c09362e89a8cd2
The thing is, the tablet isn't actually rooted. But since I somehow have access to the root via my computer, what steps should I take to actually root my device? I've searched lots of guides online, but none ever accounted for having access to root when using "adb shell", so I don't know what to do.
Thanks in advance for your attention! ^^
EDIT:
Okay. A few more bits of info. I ran Root Checker Pro and this is what I got:
Code:
Superuser Application Status:
Superuser Application - version 3.2 - is installed
System File Properties for Root Access:
Check Command: ls -l /system/bin/su
Result: -rw-rw-rw- root root 380532 2008-02-29 17:03 su
Analysis: Setuid attribute NOT present BUT root user ownership is present. Root access is NOT correctly configured for this file!
Check Command: ls -l /system/xbin/su
Result: -rwsr-sr-x root root 211739 2013-12-06 18:50 su
Analysis: Setuid attribute present and root user ownership present. Root access is correctly configured for this file! Executing this file can grant root access!
When I read that, I did:
Code:
adb shell
cd /system/xbin
su
And it just returned "su". It doesn't actually root the device, which had lead me to think that I need to fix the setuid for the /system/bin/su file. Am I correct? If I am, how to do that?
EDIT 2:
Just discovered that my tablet doesn't have a recovery partition. Gonna work on creating one.
how can i root my device while its unrootable or dont have access
Sent from my QMobile T500 using XDA Free mobile app

[Q] Chinese Tablet Root Problem

Hi all! I have a Chinese tablet that I need to root in order to run some applications. It mounts a 4.4.2 Android version and I can access via adb by opening an adb root shell. The table is called letine lt707a .
This is what I did:
Code:
adb shell mount -o remount,rw /system
adb push su /system/xbin
adb shell busybox chmod 6755 /system/xbin/su
Then I installed a version of Superuser.apk. When I open a terminal emulator app from the device, if I write "su" I obtain a "Permission denied" message.
Where is the problem? Maybe I have an old binary su?
I also tried with SuperSU without any results.
Thank you for your help!
I have just to push the correct su in the folder, but I don't know where to find it. After that in case of error I must undersand how Superuser communicates with the su. Anyone?
I think the problem is with kit kat. I pushed the su binary that came from superSU, but when I open a terminal emulator to write su I obtain a number zero as output.
If I start superSU I obtain a warning message: the program doesn't find the su binary.

Categories

Resources