• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Root LBE Alternative [Pdroid Privacy Protection]

Uzephi

Well-Known Member
Dec 20, 2012
158
41
Sonora Desert
As this thread points out, LBE doesn't work on JB. He suggested I make a thread on how to make Pdroid work on our JB roms.

Links before I go any further:
Pdroid by Svyat
Pdroid 2.0 Thread (Built from source but modified to work better and has more options) by CollegeDev
Auto-Patcher made by Mateorod and pastime1971
ApG Windows Version Auto Patcher made by kobik77

Above is all the details you need, but to make your life easier, I will help you out a little bit.

The original app Pdroid, made by Svyat, was originally made for GB. All his patcher does is work in GB roms. After ICS came out, Svyat went MIA so he released his source code, so someone can continue his work. Meteorod and Pastime1971 kept Pdroid alive by making the auto-patcher (originally only worked on linux) to increase compatibility for ICS (and later JB). Then someone wanted to give Pdroid more options and make it actually work on google apps (like Maps not being able to read your GPS).

List of what Pdroid can do (Quoted from Pdroid 2.0 thread) Bold is what was added to 2.0 that wasn't originally in Svyat's creation

CollegeDev said:
PDroid itself is not needed anymore!

PDroid 2.0 allows blocking access for any installed application[/B] to the following data separately:

  • Device ID (IMEI/MEID/ESN)
  • Subscriber ID (IMSI)
  • SIM serial (ICCID)
  • Phone and mailbox number
  • Incoming call number
  • Outgoing call number
  • GPS location
  • Network location
  • List of accounts (including your google e-mail address)
  • Account auth tokens
  • Contacts
  • Call logs
  • Calendar
  • SMS
  • MMS
  • Browser bookmarks and history
  • System logs
  • SIM info (operator, country)
  • Network info (operator, country)
  • IP Tables(until now only for Java process)
  • Android ID
  • Call Phone
  • Send SMS
  • Send MMS
  • Record Audio
  • Access Camera
  • Force online state (fake online state to permanent online)
  • Wifi Info
  • ICC Access (integrated circuit-card access, for reading/writing sms on ICC)
  • Switch network state (e.g. mobile network)
  • Switch Wifi State
  • Start on Boot (prevents that application gets the INTENT_BOOT_COMPLETE Broadcast)

For device ID,android ID, phone and mailbox number, SIM serial, subscriber ID and device location it also allows supplying custom or random values.

Please note that PDroid2.0 is now more powerful than ever. Use some options only if you know what you do!

Requirements:
  • Rooted Phone
  • ClockworkMod Recovery
  • If you integrated sys Dalvik into ROM with Titanium Backup, you will have to undo it
  • knowlegde about compiling your own rom is not required anymore. You can use autopatcher from mateo and pastime.
  • CM10 is required for actual patch

Now as we can see, Pdroid 2.0 will only work on CM10 at the moment.

If you want Pdroid 2.0, I do have a patch for linked at bottom of this post. To flash it, go to CWM, flash update.zip, reboot and install pdroid 2.0 app from CollegeDev's thread.

If by some odd turn of events you get a bootloop, just flash the restore.zip

What quirks pdroid 2.0 patch has with our rom!

It will break camcorder (even though b3 fixed camcorder)
edit: it seems after a reboot or two, and after system settles, b3a with pdroid 2.0 does work. (right after a reboot it breaks and force closes, need to wait a few minutes)

Sometimes going to pdroid 2.0 app will have random error (still works 100% on denying/custom permissions set)
any others?


I don't know if original Pdroid won't break camera, if someone finds out, I will update this post.

If you make a working patch that doesn't break camera, or make one for another ROM or some for Original Pdroid, I will update and credit back to you!

Credits:
  • Svyat for his creation
  • CollegeDev for continuing his work
  • Mateorod and pastime1971 for making the patcher. (making it easy for us dummies to not have to type in the code ourselves)
  • kobik77 Making the Windows compatible Auto-Patcher (for us Windows Dummies)
  • anyone else behind the scenes I forgot, lol

Open Pdroid for CM10 Update zip
Open Pdroid for CM10 Restore
Pdroid update aokp41 b4
Pdroid restore aokp41 b4
CM10.1 M2
AOKP42 B5

I will not personally test out CM10.1 patches, as I use AOKP42
 
I tested patch for beta 4 on 5, does work. Any feedback on this topic, or I will stop making patches for the apparent no body using them.

I will update OP with links and give credit where due if someone makes a patch and links it

Edit: RC1 works with current patches. Looks like there is no changes in the affected files this patch edits in each update tdm does.
 
Upvote 0
I tested patch for beta 4 on 5, does work. Any feedback on this topic, or I will stop making patches for the apparent no body using them.

I will update OP with links and give credit where due if someone makes a patch and links it

Edit: RC1 works with current patches. Looks like there is no changes in the affected files this patch edits in each update tdm does.

Sounds like we should have no problem jumping from CM10.1 build to CM10.1 build at least for a while. Looking forward to you getting the patch ready for a CM10.1 nightly.

Pm'd you about the same.

As far as people using it, 99.99999% of android users really don't have a clue. There is a blogger at technet that wrote an app, back when the first Froyo builds were out, that can connect to his server, download an apk of anything he wants, and install it on any android device, without displaying anything on the screen after install. He even got it on Google Play. I have not checked it on Jelly Bean, but I did try it on ICS and it had no problem hacking right in and downloading a test apk and installing it (I nandroided first and removed my SD card before I installed, then wiped and restored after testing it... :) )

If I remember correctly the test apk it downloads pulls precise GPS location, emails, sms, phone logs, browser history, imei, IP and MAC address.

That is all it took for me, if I did not hack the crap out of my phone so much, I would have the whole thing encrypted too.


looks like the autopatcher was updated last friday for Android 4.2.2
 
Upvote 0
CM10.1 M2
AOKP42 B5

There is patches for the recent AOKP build and CM M release. I will not patch nightlies, as they are there to help with bug fixes, and pdroid might break the fixes.

Also, with 4.2.2 openpdroid does break GPS, just use PMR (Pimp My Rom) and load the gps files to be able to fix the gps lock issue (this is a pdroid issue on all patches, not just our device)

Edit: ApG didn't have the line below in it. Without this line, it gave my phone an error code 7 due to permissions error on patching. I fixed the zips manually and it should work perfectly now.

Code:
run_program("/sbin/busybox", "mount", "/system");
 
Upvote 0
Not planning on pulling CM10.1 nightlies on my phone, but I do want to get off the initial release... I will probably take today's nightly and flash it, then wait for the next monthly before updating, don't know if I will be putting any further version on after that, as it looks like we won't be able to get a stable version for the Spectrum. If I encounter any issues I'll happily report here (and any successes as well), in case anyone else is interested.

once you use pDroid and see what your apps are really up to, you may never want to go back. Some of the info that apps do request is down right scary. oh, for anyone new, don't block "get network status" unless you don't want the app to ever be able to go online :) (also some apps have the same for wifi and won't work if they can't check the wifi, even with access to your mobile data...)
 
Upvote 0
I will not patch nightlies as they are made to help debug the device tree. It would be counter productive if my patches broke something and it got reported as a CM bug when it really isn't. With the 3/9 and 3/10 nightly itay have a big change in framework.jar which this patch edits.

Edit: with AOKP, I have no issues with this patch.
 
Upvote 0
question for you, have you run into any issues where immediately after patching, my device no longer has a network connection to Verizon, nor will it connect to wifi. I have not changed any settings yet. I did use the autopatcher to create a patch for cm10.1, applied it, cleared cache and dalvik cache, and rebooted. I happened to have a saved copy of pdroid manager on my SD, and installed it from there, checking the app settings shows everything with a green check under both apps.

I have clean installed cm10.1 3/15 nightly restarted, let google download the "backed up" app list it had from before I wiped, then let the phone sit 45 minutes, rebooted, let the phone sit another 30 minutes, restarted into CWM and installed the patch from autopatcher, made with only openpdroid. wiped cache and dalvik, restarted the phone, and I have no network connections.

Not asking for help troubleshooting CM nightlies, just asking if you have run into any similar issues while working with pDroid AND if you do anything different when making the pDroid patches, as so far none of the ones you have made for CM have caused me any issues.

-----------
So far, I have not been able to change any settings on the phone (ie enabling debugging worked by tapping on the CM version in about phone, but I can not enable root via adb and root for apps setting, I also cannot enable installing apps from unknown sources. Additionally, the power menu will not restart or power off the phone, and adb reboot also fails. (like the processes are hanging, not getting permission to do what they are trying to do). I did get a message while creating the patch...

Code:
... apply telephony-common.patch ...
1 out of 78 hunks FAILED -- saving rejects to file smali/com/android/internal/telephony/cdma/CdmaServiceStateTracker.smali.rej
Reversed (or previously applied) patch detected!  Skipping patch.
15 out of 15 hunks ignored -- saving rejects to file 'smali/com/android/internal/telephony/RIL$RILSender.smali.rej'
!!! PATCHING FAILED FOR com/android/internal/telephony/cdma/CdmaServiceStateTracker.smali !!!

File for which patching failed:
---------------------------------------------

CdmaServiceStateTracker.smali

---------------------------------------------

We can try to add a premade copy of those files.
This sometimes works.

You only need to report this if running the program gives you problems!!!


Do you want to proceed ? (YES/no) YES
... replace com/android/internal/telephony/cdma/CdmaServiceStateTracker.smali ...

but no errors after that.

---------------------------------------------------------------------------
Ok, even stranger after that, a force power off, then I powered back on and now EVERYTHING is working...
confused but happy...

Since they are working, here are the files in case someone else wants them.

OpenpDroid LG Spectrum CM10.1 nightly march 15th 2013
CM10.1 Nightly 3/15/2013 update
CM10.1 Nightly 3/15/2013 restore
 
Upvote 0
Having a new issue,
pDroid is not stopping any app from doing any thing. if I just check a couple boxes it still shows "no settings" if I do a "deny all" it changes to "untrusted" neither has any affect on any app. I tried rebooting a couple of times, still no go. it all "seems" to work, but has not effect on the apps.

what i did
1. ran autopatcher for openpdroid on cm10.1 nightly 3/15
2. pushed the 3/15 rom and update and restore zips to my phone
3. factory reset
4. wipe cache (yes I know the factory reset does this)
5. wiped dalvik
6. factory reset
7. installed rom
8. booted up
9. setup google account
10. went to the play store and installed titanium
11. airplane mode (to prevent settings and such from installing)
12. restored my settings for a couple of system apps
13. rebooted
14. let it sit for 30-40 minutes
15. installed ortrigger's kernel
16. wiped cache and dalvik
17. rebooted
18. let it sit over night (the above was all done after 1130pm)
19. installed pdroid patch
20. wiped cache and dalvik
21. booted, no errors or any other issues
22. let it sit for 2 hours, then reboot again.
23. tried setting deny on a few things for a web interface app (my insurance companies app)
24. was still able to log in to their system and see my account information.
25. rebooted, no change
26. set deny all on the app, no change
27. rebooted, no change

while I did test the pdroid patch on a clean CM install without the kernel, I did not test to see if it did anything. will have to do that tonight.

Any suggestions would be nice. I did not make any changes to the Rom before or after install (messing with system files or any settings, did not even add a hosts file to the phone yet).
 
Upvote 0
Yeah, the mount command is there on line 1213
(file version 3/7/2013)

I'll just wait for the first stable build (kind of what I am hoping for anyway, as I'd like to update my phone, then leave it alone until I get rid of it in November. Hoping the Moto X is all the internet is hyping it up to be, almost 2 months to go before the Google IO to find out... else I dunno what I'll get... I'd really like a 4 core that either can side load Ubuntu, or can run the Ubuntu Mobile OS, as I am getting tired of Android I think.

I would stick around for a Nexus 6 or whatever it will be (pure Android device), if it merges Chrome OS and Android. Else I may just go with a pay as you go feature phone that supports wifi for data, as I have not been using my phone for much since the spectrum really has not been all that reliable for me. My last phone was the HTC Evo 4G (the first one) and I had so few problems with it that I only every did a reboot was 1 when I bought the extended battery and had to switch to it, 2. when I rooted, and then about 10 times while I tried out various Roms until I found one I liked, then 3 more times for version updates on the Rom I chose. It never crashed, it never lagged (except when running an app that needed more horsepower), and everything the device was supposed to do, it did it, without complaint. I'd then just pick up a really nice tablet (maybe with LTE), I already carry a small tablet around pretty much everywhere I go anyway, won't be too much more to snag something between 8.9" and 11" to use as an upgrade.
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones