Sunday, September 20, 2015

system apps - Uninstall via adb without root


I own an Asus Zenfone Go Z00VD running Android 5.1. It came preinstalled with TrendMicro Dr. Safety, which I absolutely have no use for and do not want running at all. This app starts itself periodically, and there is no option to uninstall nor disable it. I'm not sure that it's a system app but I assume it is.


I've done some research and found the following options:



  1. Root the phone and uninstall the app. This is the most obvious solution, but this is a last resort.

  2. Remove the app via adb without root. Not sure if this is even possible, I've seen some claims that it is, and more claims that it is not.

  3. Install an app manager to kill Dr. Safety processes as soon as they start. From the answers on this Stack this seems like a bad idea.


This question is about option 2. Is it possible? Is it safe (little chance of bricking the phone and won't open security holes)? If the answer to either is "no" are there other non-rooting options to disable the app?


I found instructions here: http://hexgears.blogspot.com/2015/06/android-remove-system-apps-without-root.html



but I'm doubtful that they'll even work, let alone work safely.



Answer



Since it is Android Lollipop, you can setup in PC and execute this command:


adb shell pm hide PACKAGE

PACKAGE → package name of an app. To know the package name of an app, follow the answers to the question: View app's full package name?


If I'm correct, this app is exactly what came with your device and which you aim to get rid of. Although you should verify the package name through your own means, I find the package name as com.trendmicro.freetmms.gmobi from the linked URL, so your command would be:


adb shell pm hide com.trendmicro.freetmms.gmobi
adb reboot # reboot the device


Note: Execute the command at your own risk. I cannot guarantee that it would not soft-brick the device but it would make sure the app do not run again until your unhide the package. To unhide the package, replace hide by unhide in the aforesaid command.


If something goes wrong, such as the Android ends up in a boot-loop or with recurrent crash messages, then you should either unhide the package (provided that you can) or do a factory reset which means you should backup your data before hiding the package.


As for the instructions in the link, ignore them. The author doesn't know what they wrote. Let me simplify few things there. First, the device is rooted and the title is deceptive. They are using a kernel which is not stock. A stock kernel (production build) should never allow adb deamon to be restarted with root permissions but they were able to do so using adb root. If a kernel allows this, then it is considered an insecure kernel and unfit for consumer ready devices.


Also, the steps there about removing the system apps are risky. Huge risk. Only a re-flash of stock ROM or a backup of system partition would be able to fix the device.


No comments:

Post a Comment

samsung galaxy s 2 - Cannot restore Kies backup after firmware upgrade

I backed up my Samsung Galaxy S2 on Kies before updating to Ice Cream Sandwich. After the upgrade I tried to restore, but the restore fails ...