Playstation Vue on rooted Fire TV - Fire TV General

Has anyone figured out how to get ps vue to work with firetv that is rooted? I've gone the route of renaming su.apk in shell to xsu.apk. When I do this I can access root in shell but can not give permission to installed rooted apps on screen. I've tried root cloak. It's a no go. Plus why is there no gui for su for fire tv. Any help would be greatly appreciated. Thanks.

1. What did you think would happen if you rename your su and Superuser.apk? It all would magically work regardless?
2. Other people report that Root Cloak worked for them as recently as 24 days ago. Might not work on the FireTV - but still...
3. You can get the information on why the su GUI does not work on the FireTV from here:
http://forum.xda-developers.com/showpost.php?p=68273660&postcount=67

Thanks for replying. By changing su name I still have root abilities through adbfire. I can access and change root files. The issue is once I originally grant root access on fire tv I can never get it to appear again. Is there any way to clear su.apk access without gui? In app section all su options are grayed out. It's strictly read only su. The link below is the post for renaming su files. It does work. System is still rooted. I just can't get popup to grant access to apps. I've been trying off and on for a few months. Any help would be greatly appreciated. Thanks.
http://forum.xda-developers.com/fire-tv/help/playstation-vue-fire-tv-fire-tv-stick-t3247813/page2

Not through adbfire - through adb and the shell.
Adbfire is a "eazy to use" frontend that prevents users from learning to navigate using adb commands and the shell by makeing them click buttons with preset commands backed in, that sometimes are just silly. Then it pops up fake progress counter animations to put their minds to ease.
Every time someone says that "adbfire doesn't work" I die a little bit more, deep in my heart.
But you have made it to the actual shell, so congratulations, you are using the real deal.
-
Here is what happens as far as I understand it - could be wrong - but it is a pretty educated guess.
Once you rename su and Superuser.apk - all apps loose access to it.
The prompt is not poping up, because the apps already think they have SU access - but because they cant access su.
Here is why.
Apps that require su, have to address su, and they certainly don't expect su to be named xsu.
Its great that you can call su functions by typing in xsu into the shell instead - but that won't help your apps.
If an app cant get su access - it usually just prompts su and the Superuser.apk again. There is no need to "clear Superuser.apk access" in fact - just uninstalling an app that requires root and reinstalling it again is enough for the rootmanager to forget it ever existed. So you can in fact test your theory that way. My best guess is, that you are wrong and it won't work regardless, because none of the apps calls a binary named xsu. xsu could in fact be named "makeamericagreatagain" and it would make no discernible difference.
The thing why I preface this with "I could be wrong" is, that I havent looked into how systemless root works, and how those guys get root access to their apps, without having a binary named su in /system. Maybe the apps call Superuser.apk (which is now called xSuperuser.apk so they cant find it) and xSuperuser.apk of course cant find su, because you renamed it xsu. But in any case - they are not using the usual Superuser.apks

Thanks for the quick reply. You are right about the renaming of su. I tried same thing on old tablet and got the same results. Even with having gui access. I could not get it to grant root abilities. Next step is to find a way to edit apk's and find a way change where it looks for root files. I only need to edit 3 apps. (adaway, xposed, and hdxposed) If can figure out how to do it once the others should be easier. This should be interesting.

Now here is something that could work. I'm a bit hesitant to recommend you doing it, because you are constantly modifying system files - but if you were willing to risk it before... It might work.
Read up on a program named "Remote adb Shell" in here
http://forum.xda-developers.com/showpost.php?p=69050521&postcount=3
Then maybe try two commands like these:
su -c 'mount -o remount,rw /system /system && sleep 1 && mv /system/app/Superuser.apk /system/app/XSuperuser.apk && mv /system/xbin/su /system/xbin/xsu' && exit
and
xsu -c 'mount -o remount,rw /system /system && sleep 1 && mv /system/app/XSuperuser.apk /system/app/Superuser.apk && mv /system/xbin/xsu /system/xbin/su' && exit
Now - understand, that I havent tested this myself - also - I havent looked if you need to chmod modify the su file first (add another
&& chmod 761 /system/xbin/su
- at the appropriate spot(s)), which you do according to this thread https://www.reddit.com/r/fireTV/comments/41e8z3/ps_vue_aftv_1_with_root/?st=iuk3lgx4&sh=36edc941 (which I think you took the method from) --
but if it works - it would allow you to switch between "rooted" and "non rooted" states with a few presses on your android smartphones (or tablets) screen.
Now - I don't know if you would need to reboot the AFTV for root or VUE to work again -- (make another entry with just
reboot
- in it) . The reboot might kill the concept - because switching between the states might take too long.
Also - you do this at your own risk. If you loose root (or worse.. ) as a result of this - its not my fault.

install xposed, install rootcloak and block the vue apk by package name. I use that method on my shield tv. Just reset my ftv so I'm still trying to set everything up before I get to this.

There you go.
Should have looked into the "doesn't know how to use rootcloak" angle a bit more.
Definitely the better solution. Go with that.

Just like you should go to "I'm a **** and my comments don't provide any help others than to prove I'm an asshole section."
This is a forum for questions and help. Thanks Noggind614 he gave me the correct command for the fire tv and root cloak. Don't use the phone or tablet com entry. For fire tv its. "com.snei.vue.firetv"

Thats not a command, thats literally the process name of the app others have suggested <ou to block with root cloak before.
Oh, and here is why I hate dumb people.
- They rather complain about solutions not working than to learn how they work. If you don't constantly have the filter on, that everything they say might in fact be just a made up "fact" trying to mask that they werent able to use an app - you are out of luck entirely, and situations like these happen.
- When they then resort to renaming system apps - because reddit told them to, not knowing what they are doing, and you have to explain to them, that stuff breaks, because they broke it - the< might act interested and willing to learn for a moment -
- but as soon as someone points out, that they don't know jack, their "facts" are all kinds of wrong, and the better solution was suggested by every entry in google, this forum, and even by myself (hinting at that it would be strange, that people report cloak works as recent as a month ago..) - they become tonguetied, and when you weigh in to make it clear for others that the solution the excluded from the beginning as "not working" is in fact the best one --
they take it ultra personal - and switch from thanking you for explaining to them how stuff works, to calling you a dickface -- because it becomes so very obvious whats wrong here.
So they are the assholes. They think the internet is here to serve them without even calling a dog a dog, they cause the majority of confusion in stating wrong information to begin with, they switch from thanking you for explaining to them what they are doing to calling you a dickface - because you just made it clear, that the solution someone else brought up is in fact the better one, so others wouldn't bother to go through the same pitfalls they went through - oh, and all information you have provided them so far all of a sudden becomes null and void - because it was just that, information - and not the entire step by step solution they wanted people to provide in the first place.
Now - not even "block the app with root cloak (exposed)" is enough information for someone like you in the end. No - you need a PN conversation to clarify that you should block the process everyone told you to block in the beginning. Because you didn't bother to find out how its named.
Instead of typing ps into the Fire TVs shell (or ps | grep vue), you used this forums PN function to ask someone else to do it for you. And you didn't have to know the ps command either, you probably could have looked up the apps (process) name elsewhere on the net.
Here i the mea culpa on my part. I am not a PS VUE user, because the service is not even available in my country. I might react threads though, where people rename android system files, and then complain about them "not working". I don't if blocking within root cloak using the process name of an app is something out of the ordenary, if it is, some of my criticism doesnt apply, although I highly doubt it at this point.
Tldr.
Dont ever take agreeing with someone else on what would be the best solution, as mocking you personally. I know that reddit QA culture demands, that every thread is a personalized support session for people with no clue but high aspirations - threads on forums usually are not. Clearing up "what the best solution seems to be" for the next person that reads along is something I don't do out of malice, I do out of responsibility.
Well, at least until someone calls me a **** for not providing an easier solution for them faster. Then all bets are off.
Everytime someone explains somethng on an open internet forum, there is the notion, that others are reading it, and that the information they are providing gets used further - that just the immediate support session they are driving at a time. This is the sole cause - why people might not wan't to protect you or others in the "looking fly" department - while you are actually -
- promoting, that people should modify system files - and then expect stuff to work regardlessly
- making it sound like a fact, that stuff doesn't work, when its actually working
This is not "acting like an asshole", this is actually responsible behavior.
n00bs usually don't become educated users, by calling the people explaining stuff to them dicks, or accusing them of "saying unimportant stuff, because - you just needed a step by step instruction, which you finally solicited from someone via PN - good job" - or by putting down people, that explain stuf to them, because it makes them look like n00bs.
This goes for me as well - in other areas.
Yet I never got the demand, that others should fix your issues for free, and on the spot, in detailed step by step instructions, while making it extra sure, that you can save face, and look like a hero at the end of the day - also what dicks, are they for actually daring to try to explain stuff to you instead of just fixing your problem.
Have I mentioned, that I sometimes hate what has become of the web in the recent years? Signs of getting old...
Also, yes, I do think that this response was needed.

Related

Identifying symlink to avoid "infinite" loop when browsing files.

Hi,
I have tested this behaviour on both a N1 and the emulator. Could anyone tell me if that is a problem? How can I avoid the recursive code going forever? What is happening?
If you use any file browser/manager and starting going into /sys/devices/w1 bus master/subsystem/devices/w1 bus master/subsystem it will go inner forever, repeating that pattern devices/w1 bus master/subsystem/ all the way.
So when I run a recursive search it keeps going deeper and deeper and seems never to finish.
What is happening, how to avoid this behaviour?
I tried different file managers and they all seem to be going forever into these folders, although when I do a search through Astro it doesn't seem to get stuck with this loop (It seems to ignore the /sys folder, but I am not sure if this happens also in any other folder).
Some people point me this problem can be related to symlinks, but I didn't find a way of checking for those symbolic links with Android's Java.
I know it can be done (as proved by Astro file manager), I just don't know how.
Hopefully it won't involve any call to functions which I'll have to create using NDK, which would be a pain.
Regards.
astro goes infinite for me on an N1
I think any app needs to do some extra checks instead of following stuff down.
eg the "find" command has the "-follow" option
open a terminal or use "adb shell" and "cd /sys/bus"
now type in "find" and it will display all the files directories and symlinks without following them
now type in "find -follow" - you will need to press Control-C to get out, you will see that each line has an error "too many symlinks" - kernel has protection/limit for symlink levels.
writers of file managers could easily fix this, but you have to ask what you were doing in their anyway?
Lol, I was trying to find some info to address this problem under Android & found a relevant thread I thought might help, only to discover it was you (jfbaro) having this conversation on another forum
Specifically, this thread on anddev.org.
I don't know Android yet, but a getCanonicalPath() like call is always going to be at the heart of spotting in advance & avoiding this type of problem, whatever your environment & language. If it doesn't work either the function is broken or you're making a mistake somewhere, I'm fairly sure.
In the above thread you say this doesn't help you. Can you post what getCanonicalPath returns for both /sys/device/subsystem/ & /sys/device/subsystem/sys/ ?
Let's assume you start your traverse at / & have reached /sys/device/subsystem/. When you check to see if it's safe to follow /sys/device/subsystem/sys you should discover that the latter is actually /sys, and that further, it is in your list of already scanned directories, hence you do not search further down that branch.
Where is this breaking down?
[Edit:] You might also find something of use buried in this bug thread which involves similar issues. Funnily enough it concerns Eclipse, but all that matters is that it's a Java based example of the problem. From a quick scan, getCanonicalPath again seems to be the solution though I think they avoid any performance hit by only using it on files known to be sym-links.

[Q] NexTheme problem?

For some reason, NexTheme is triplicating all the texts I receive. It's not giving me three notifications, just 3 texts all at the same time. I saw that a few other people were having this problem, but the only solution given is to use RootExplorer to do some stuff, and I'd rather not pay $4 for an app to make my phone work as it should.
Word on the street is that it's only affecting Epic 2.5 users, something about conversations.apk vs. mms.apk. Anyone have any ideas?
vcarl said:
For some reason, NexTheme is triplicating all the texts I receive. It's not giving me three notifications, just 3 texts all at the same time. I saw that a few other people were having this problem, but the only solution given is to use RootExplorer to do some stuff, and I'd rather not pay $4 for an app to make my phone work as it should.
Word on the street is that it's only affecting Epic 2.5 users, something about conversations.apk vs. mms.apk. Anyone have any ideas?
Click to expand...
Click to collapse
For your phone to work as it should would mean to not make any changes as that as how it comes from the manufacturer. As with any theme, you use at your own risk. You should have a decent root explorer on your phone anyway and i would recommend getting one in case you have system issues or have to overwrite a file. Additionally, you should be able to use adb as a root explorer alternative just not as convenient since it is not on the phone itself.
Well, I'm still not sure why it was happening (or how it could've been caused by installing a theme), but the root of the problem seems to have been having multiple messaging applications. I uninstalled Handcent SMS and it only duplicated messages, and I went in and renamed Conversations.apk to Conversations.bak, which ultimately solved the problem.
I have a terminal emulator and busybox on my phone, and despite having a fair bit of bash knowledge, but I couldn't do anything with any of the files in the app folder. It'd be nice if the information on how to do things was more organized, I've been trying to learn.
of course arent we all here to learn?
if you were in terminal you should be able to do something such as:
PHP:
mount -o rw,remount -t ext3 /dev/block/mmcblk1p21 /system
rn system/apps/conversations.apk conversations.bak
I believe that would work.
Additionally, it may be something with the theme as multiple people have had the issue. Just the phrase of I want my phone to work how it was supposed to sounded as if you were blaming the developer is all. Just wanted to make sure that we had the canned response of "use at your own risk".

SSH binary from S5?

Hey yall,
I'm thinking this might now be possible until root is gained, but is it possible to run ssh through the terminal?
I know there are apps like JuiceSSH & BetterTerm Pro, but I specifically need to ssh with a key through the shell.
Reason:
I used to have a Tasker profile that when activated (by location context) would write to a text file on my server, which would be the catalyst for my other computers and devices to switch contexts and run various scripts & such.
Sigh………I'm thinking it was a big mistake to get this phone between the 4.4 SD card lockout & stupid Verizon locking.
I think ssh is possible, how, I have NO IDEA but in the irc channel #sgs5 (maybe in a thread here somewhere and not on irc, idk )someone mentioned we may get root faster if we set up ssh so a dev could adb shell and let a dev without a physical device tinker.... I'm probably way off though, or maybe the person that posted was off and mislead me through my own lack of knowledge.
beav3r
Ah, I saw that in the big root thread here. I believe they're referring to starting an SSH *Server* on the phone, kinda the opposite of what I'm asking. But thanks for your input though!
I don't think you would need root for this. Both JuiceSSH and BetterTerm should support shell scripts that can be called from Tasker.

[ROOT][HOWTO] Disable Lockscreen Ads

WARNING: I am not responsible for any bricked devices caused by attempting this howto. If you haven't read this how to twice, and fully understand the requirements, then please don't attempt it.
Introduction (not important):
First, this may not be the best way to do this, and if someone knows a better way, I'll be happy to listen.
I kinda stumbled across this solution after trying the many other ways to solve the problem, but all the other ways seemed to have something incomplete with them and ended with no ADS, but no something else, like rotating lock screens or something.
I started with the assumption that the ADS program (dtcp) can be disabled through a flag somewhere on the system, for if you pay the extra $20 you get a kindle with no ADS, but same Android build. After looking through lots of sqlite databases I found it in the com.android.providers.settings/settings.db file.
Prerequisites:
Basic knowledge of databases
SQLite Editor Pro (Free on 1Mobile Market)
DroidWall
Steps:
Open SQLite Editor
Open "Settings Storage" (com.android.providers.settings)
Open settings.db
open "global" table
Highlight entry "IS_DTCP_ENABLED"
Click the Edit Record button at the top
Change the value from a 1 to a 0
Click Save
Go back
Make same change on the "secure" table
Reboot kindle for new options to take effect.
Other Thoughts:
This just changes the value temporarily until the device checks back in with Amazon and then the value will get overridden again with the correct value. To prevent that install DroidWall and whitelist only the applications you need to access the internet. DroidWall requires root, which is why root is in the subject. But you should be doing this anyways to prevent OTA updates.
cool
Does this mean that you will now get the rotating native wallpapers that you would have if you paid for the dismissal of the ads? Currently I use adaway on my s4 hotspot and the only one I blacklist is (spectrum.s3.amazonaws.com) this has blocked updates because I am still on old software with no other blocking in place and I have noticed it also has blocked rotateing ads accept I have the same 1 at all times.
Edit: YAY !!!! and yes I now have rotating native wallpapers
Btw thank you for sharing and it is quite refreshing to see a new member join to share useful information in a well thought out and presented OP and not just join to start a thread with a question that is the heading of so many other threads that has been beat to death already..burying perfectly good information..thank you for joining us at XDA!
Awesome!!!! have been looking for a way to do this without factory reset for a while! You da man! Gonna spam that thanks button for a while lol
Thanks so much, that was easy!
Mind after a few days .2 went straight black lock screen
Anyone know what exactly I need to enable in droidwall to have internet but no ota updates or Amazon changing the lock screen back to ads?
Uhg
This mod works fine. No ads, rotating wallpapers appear every time. No reversion to black screen. No need for Droidwall. Use of Droidwall is impractical for this purpose. Who knows what not to include in some giant white list?
It appears that the wallpapers will continue to appear without reversion if you have blocked updates using the root kit.
earlgrey_44 said:
This mod works fine. No ads, rotating wallpapers appear every time. No reversion to black screen. No need for Droidwall. Use of Droidwall is impractical for this purpose. Who knows what not to include in some giant white list?
It appears that the wallpapers will continue to appear without reversion if you have blocked updates using the root kit.
Click to expand...
Click to collapse
Sorry, what's the root kit?
dras99 said:
Sorry, what's the root kit?
Click to expand...
Click to collapse
First link in this post:
http://forum.xda-developers.com/showpost.php?p=53451623&postcount=3
I assume the block update action from the rootkit is responsible for the lack of reversion to ads since I haven't done anything else except the steps I outlined in the post and the data base tweaks explained above. My kindle has been running for 5 days now without ads and with the startup wallpaper.
earlgrey_44 said:
First link in this post:
http://forum.xda-developers.com/showpost.php?p=53451623&postcount=3
I assume the block update action from the rootkit is responsible for the lack of reversion to ads since I haven't done anything else except the steps I outlined in the post and the data base tweaks explained above. My kindle has been running for 5 days now without ads and with the startup wallpaper.
Click to expand...
Click to collapse
I also blocked updates with the root kit. Then I followed this tutorial and it worked great however it did revert back to adds after a reboot or 2.
conan1600 said:
I also blocked updates with the root kit. Then I followed this tutorial and it worked great however it did revert back to adds after a reboot or 2.
Click to expand...
Click to collapse
Strange! What's different about my install I wonder?
earlgrey_44 said:
Strange! What's different about my install I wonder?
Click to expand...
Click to collapse
I'm left scratching my head over that as well. Tomorrow I will re run the ota block script as I'm now concerned that it perhaps did not do something correctly. I did check for updates and it says last update failed but better safe than sorry. I DO NOT want to end up getting updated again. I finally have this tablet running rather nicely and am quite satisfied with most aspects. Still need much more customization options but it's serviceable now. And this tablet has always had the best touch input response of any I've ever used. I'd hate to have to throw it back in the closet.
I am getting now BLACK SCREENS. Any way to change this?
Script
For anyone who wants to run this from command line (e.g. on reboot or network change event) you can create a script like below and use SManager to run it periodically. You will first need to install sqlite3 binary (google "SQLite Installer for Root").
Here is the script that needs to be executed as root:
Code:
#!/system/bin/sh
sqlite3 -batch /data/data/com.android.providers.settings/databases/settings.db "update global SET value='0' where name='IS_DTCP_ENABLED'";
sqlite3 -batch /data/data/com.android.providers.settings/databases/settings.db "update secure SET value='0' where name='IS_DTCP_ENABLED'";

Root done right

WARNING: This is not a place for you to come to say how great you think Chainfire is. I'm not calling his character into question, only his methodologies and the character of the outfit he sold out to (and I don't question the act of selling out, that's business, pays the bills, and puts kids through college). The debates about what people prefer and why are as old as the first software. And of course, I will not tell you what to do, no matter how much I disagree with you. If you UNDERSTAND what I have to say, then THIS software is for you. If you don't, you are probably better off with binaries.
The root situation on Android 5.x left a lot to be desired. There was basically just one distributor of a functional substitute user command (su), and it was binary. Recently, ownership of that binary and all of its history has become the property of a previously unknown legal entity called "Coding Code Mobile Technology LLC". While it was presented as a positive thing that that entity has a great involvement with android root control, this is actually a VERY frightening development.
The people at CCMT are no strangers to the root community. They have invested in, or own, a number of popular root apps (though I am not at liberty to disclose which ones) - chances are, you are running one of them right now. I believe SuperSU has found a good home there, and trust time will not prove me wrong.
Click to expand...
Click to collapse
There are precisely two motives I can imagine for buying up all the root control software for Android;
1) monetizing it, which is contrary to the user's best interests,
2) something very frightening and dangerous involving the potential exploitation of everybody's devices.
You don't know the owners, and they are distributing a binary, so who the heck knows WHAT is going on.
Now a few important considerations with respect to your security and privacy;
1) Obfuscated binary cannot be sanely audited.
2) Function of this binary depends on the ability to manipulate selinux policies on the fly, including RELOADING the policy altogether and replacing it with something possibly completely different. Frankly, I've never heard a single reason why this should be necessary.
3) While a root control application may give you nice audits over other software that is using its service, it can *EASILY* lie about what it is doing itself. It can delete logs, it can share root with other applications that they have made deals with, it can directly sell you out to spammers, etc.
That is WAY too dangerous, and not worth the risk.
Frankly, you are safer if you disable selinux AND nosuid, and just run the old style of root where you set a copy of sh as 6755. And that is FRIGHTENINGLY dangerous.
So not satisfied with this state of root, and especially now with a new unknown entity trying to control the world, we bring you the rebirth of the ORIGINAL Superuser:
https://github.com/phhusson/Superuser
https://github.com/lbdroid/AOSP-SU-PATCH (this one is mine)
From the history of THAT Superuser:
http://www.koushikdutta.com/2008/11/fixing-su-security-hole-on-modified.html
Yes, look at the Superuser repo above and see whose space it was forked from.
Note: This is a work in progress, but working VERY well.
Use my patch against AOSP to generate a new boot.img, which includes the su binary.
Features:
1) selinux ENFORCING,
2) sepolicy can NOT be reloaded.
3) It is NOT necessary (or recommended) to modify your system partition. You can run this with dm-verity!
The source code is all open for you to audit. We have a lot of plans for this, and welcome suggestions, bug reports, and patches.
UPDATE NOVEMBER 19: We have a new github organization to... "organize" contributions to all of the related projects. It is available at https://github.com/seSuperuser
UPDATE2 NOVEMBER 19: We have relicensed the code. All future contributions will now be protected under GPLv3.
*** Regarding the license change; according to both the FSF and the Apache Foundation, GPLv3 (but not GPLv2) is forward compatible with the Apache License 2.0, which is the license we are coming from. http://www.apache.org/licenses/GPL-compatibility.html . What this means, is that it is *ILLEGAL* for anyone to take any portion of the code that is contributed from this point onward, and use it in a closed source project. We do this in order to guarantee that this VITAL piece of software will remain available for EVERYONE in perpetuity.
Added binaries to my the repo at https://github.com/lbdroid/AOSP-SU-PATCH/tree/master/bin https://github.com/seSuperuser/AOSP-SU-PATCH/tree/master/bin
These are *TEST* binaries ONLY. Its pretty solid. If you're going to root, this is definitely the best way to do so.
The boot.img has dm-verity and forced crypto OFF.
The idea is NOT to use as daily driver, while I can make no warranties at all regarding the integrity of the software, I use it myself, as do others, and its pretty good.
What I would like, is to have a few lots of people try it out and report on whether things WORK, or NOT.
IF NOT, as many details as possible about what happened, in particular, the kernel audit "adb shell dmesg | grep audit". On non-*nix host platforms that lack the grep command, you'll probably have to have to add quotes like this in order to use android's grep: "adb shell 'dmesg | grep audit'".
How to try:
0) Starting with a CLEAN system.img, get rid of supersu and all of its tentacles if you have it installed, if it was there, it will invalidate the tests.
1) Install the Superuser.apk. Its just a regular untrusted android application. Yes, there is a security hole here, since we aren't (yet) authenticating the communications between the android application and the binaries, or validating the application by signature, or anything else that would prevent someone from writing a bad Superuser.apk. This is on the list of things to do.
2) fastboot flash boot shamu-6.0-boot.img
3) test everything you can think of to see if it works as expected.
Note: there are some significant visual glitches in the android application, but nothing that makes it unusable.[/quote] @craigacgomez has been working on fixing up the UI. Its really paying off!!!
How you can reproduce this YOURSELF, which we RECOMMEND if you feel like daily driving it (in addition, make sure that you UNDERSTAND everything it does before you decide to do that, you are responsible for yourself;
You can build it any way you like, but I do my android userspace work in eclipse, so that is what I'm going to reference. Import the project from phhusson's git, including SUBMODULES. Right click the Superuser project --> Android Tools --> add native support. The library name you choose is irrelevant, since it won't actually build that library. Right click project again --> Build configurations --> Build all. This will produce two binaries under "libs", placeholder (which we won't be using), and su. You need the su binary. Then right click project again --> run as --> android application. This will build Superuser.apk, install it, and launch it.
Next:
repo init -u https://android.googlesource.com/platform/manifest -b android-6.0.0_r1
repo sync
Then apply su.patch from my git repo.
UNFORTUNATELY, the repo command isn't smart enough to apply a patch that it created itself. That means that you are going to have to split up the patch into the individual projects and apply them separately to the different repositories. This isn't that hard of a step though, since there are only FOUR repositories I've modified... build/ (this just makes it possible to build with a recent linux distro that doesn't have an old enough version of openjdk by using oraclejdk1.7. The boot.img doesn't actually need the jdk to install anyway -- its just part of the checking stage, so its up to you.), device/moto/shamu/, external/sepolicy/, system/core/.
After applying the patches, copy the su binary you generated with eclipse into device/moto/shamu/
Then ". build/envsetup.sh; lunch aosp_shamu-userdebug; make bootimage". That should take a minute or two to complete and you will have a boot.img built from source in out/target/product/shamu/
NEW UPDATE!!!!
While I haven't yet gotten around to running a complete cleanup (very important family stuff takes priority), I *HAVE* managed to find a half hour to get on with the Android-N program. If anybody takes a peek at the AOSP-SU-PATCH repository on the AOSP-N branch, you should find some interesting things there.
One warning first though... I updated the patches to apply against the N source code, and then updated some more to actually compile, and compiled it all. BUT HAVE NOT HAD THE OPPORTUNITY TO TEST IT YET.
Nice thing you came up. Sounds awesome.
We should have an alternate to all LLC thing, no matter how much respect (I owe you Chainfire thing) we got for the man who created CF Root (since Galaxy S days) and SupeeSU.
wow, tyvm for this! Will definitely test for ya and let you know.
I already applied your patch, built my own binaries and the boot.img but won't have a chance to test anything until tomorrow. Would love to get this %100 working fine and yeah, will use this from here on out instead of supersu.
Thanks again and yeah, will post when I have something ^^
I will be following progress closely, as should others. Without something like this, many in the community may naively let a corporate entity control root access on their devices. This is extremely frightening, it may not happen right away but if you believe the an entity will not monetize or exploit the current situation I believe you are sadly mistaken.
I could be wrong, however, it's not a risk I will take lightly and no one else should either.
Thanks for this.
Nice work!! Will be following this thread closely.
Time for me to learn eclipse. And do a heck of a lot more reading.
Larzzzz82 said:
Time for me to learn eclipse. And do a heck of a lot more reading.
Click to expand...
Click to collapse
Just note that I use eclipse because I'm used to it. Its become the "old" way for android dev.
i just paid for superSU is this the same people?
TheLoverMan said:
i just paid for superSU is this the same people?
Click to expand...
Click to collapse
I'm not sure what you are asking... are you asking if I am in any way affiliated with supersu, then you probably failed to read the first post in this thread altogether.
Charging money for a binary blob to use root on your device is borderline criminal, and unquestionably immoral. I'm sorry to hear that they got something out of you.
This is pretty great. I'll be watching this as well.
Perhaps this is not the place to take the tangent but why does root behave as it does and not more similar to a standard linux distro? It seems like it would be much more secure to have a sudo function as opposed to an all encompassing root. I'll admit I'm not that familiar with the inner working of the android OS but off hand I can't think of any program that absolutely needs to be automatically granted root every time it wants to run (I'm sure there are but even in this case the power user could chown it to standard root).
Wouldn't it be much more secure if you had to go in to developer options (which are already hidden by default) and turn on the option for sudo. This would then require a sudo-user password (perhaps even different than the standard lock screen password). Need to run a adblock update? Enter the password. Need to run Titanium backup? Enter the password... etc. Much more secure than a push of "accept".
Sorry for off topic but it's always made me wonder and seems like it would be root done right (see how I tied that back to the topic ) If elevating programs/tasks to a superuser was more secure perhaps it would not need to be such an issue...
^ Some root functionality is just too common for a Linux like sudo password to be usable at all. I'll give 2 examples:
1. Since Lollipop Google disabled access to mobile network settings for third party apps. Now it's only possible with root. I have an app that together with Tasker automates my network changing. That network app needs root access EVERY time there is any changes to the connected network and when it wants to change the settings.
Phone connects to a different cell tower? Root needed to detect this and determine the mobile network status.
You can figure how many times this is required per day.
2. I use Greenify to force some misbehaving apps to sleep after the screen goes off. It needs to request root every time it wants to sleep one of those apps. In other words every time I use them, after my screen goes off and I turn it back on I'd be facing both my secure lockscreen and the sudo password.
There's are plenty of other apps that need to request root access on a regular basis. These were just a few examples. If you only need root for TiBu then a sudo password type of security measure would work. In my case all I'd be doing with my phone would be typing that password again and again.
Beyond what is said above, to my understanding... What "root" is is just a way to install the "su" binary to your phone, with a nice GUI to make it more friendly for phone/tablet use.
Being rooted, if memory serves, is being able to access and change any file in your root directory, at least that's a simplified way to see it. The SU app is a GUI that is mostly used to control the ability of apps to access and change the root directory.
Sent from my Nexus 6 using Tapatalk
Interesting thread. Thanks for your work....subscribed
doitright said:
There are precisely two motives I can imagine for buying up all the root control software for Android;
1) monetizing it, which is contrary to the user's best interests,
2) something very frightening and dangerous involving the potential exploitation of everybody's devices.
Click to expand...
Click to collapse
I would suggest that there is a third potential motive here - that having control over the "only" way of rooting Android devices might be attractive to Google.
I've read a few articles suggesting that they would prefer to prevent people from rooting their phones (partially so that they can monetise Android Pay - which requires a Trusted Computer Base, which means unrooted - as well as controlling Ad Blockers, which affect a revenue stream). I also suspect that only a tiny minority of Android users - and most of them are probably on here - actually root their devices.
Regardless of the motives, having a technological monoculture is never a good thing, especially when it is delivered as a binary owned by an unknown organisation.
(No disrespect to Chainfire - I have had many years of root access to my devices thanks to his efforts.)
scryan said:
Beyond what is said above, to my understanding... What "root" is is just a way to install the "su" binary to your phone, with a nice GUI to make it more friendly for phone/tablet use.
Click to expand...
Click to collapse
Not quite.
"root" is the *name* of a privileged user, with user id of 0.
The "su" command (short for substitute user), is used to substitute your current user for another user, but most particularly root.
Every application and many subsystems in Android are granted each their own user, which are very restrictive, hence the need to escalate to root to obtain necessary privileges.
Philip said:
I would suggest that there is a third potential motive here - that having control over the "only" way of rooting Android devices might be attractive to Google.
Click to expand...
Click to collapse
What does that have to do with the third party? I doubt very much that Google would appreciate the security of their users being compromised by a 3rd party.
urrgevo said:
Being rooted, if memory serves, is being able to access and change any file in your root directory, at least that's a simplified way to see it. The SU app is a GUI that is mostly used to control the ability of apps to access and change the root directory.
Click to expand...
Click to collapse
Nope. The root directory can be setup to be accessible by specific users just by applying the appropriate permissions to the files.
The root directory and root user are not specifically related.
doitright said:
What does that have to do with the third party? I doubt very much that Google would appreciate the security of their users being compromised by a 3rd party.
Click to expand...
Click to collapse
Because the "third party" might actually be Google (or an organisation funded by them).
---------- Post added at 15:05 ---------- Previous post was at 15:02 ----------
doitright said:
Every application and many subsystems in Android are granted each their own user, which are very restrictive, hence the need to escalate to root to obtain necessary privileges.
Click to expand...
Click to collapse
Shouldn't need to su to root to do this - that's what setuid and setgid are for.

Categories

Resources