How To: Backup protected and paid Android applications for root users

First off, this is not a guide to pirating apps. There are legit reasons for wanting to backup your applications. Sometimes an older version of the app worked better, or had features you liked better. Sometimes new versions don’t work with specific phones and you need to revert back.

Now, you can use AppManager to backup most apps, but protected apps are not included in this because they are stored in a different directory. With a rooted phone, you can access this directory and copy the apps to your SD card or to your computer. After all, you paid for it, it’s yours. If you want to pirate apps, or buy an app, copy it then return it, that’s on you, I’m not advocating that.

First method, copy with your phone to SD card:

  1. Install and open a Terminal Emulator on your phone.
  2. Enter su to be superuser (root).
  3. Enter cd /data/app-private/ to enter the protected application directory.
  4. Use ls to view the apps in the directory.
  5. Enter cp filename.apk /sdcard to copy a single app to your SD card.
    (Or to backup all the protected apps: cp * /sdcard)
  6. If you want to backup all your apps, they can be found in /data/app/

Second method is to use Android Debug Bridge with your PC:

  1. Install the Android SDK on your PC
  2. Connect your phone to your computer via USB cable, and make sure USB debugging is enabled on your phone (Settings > Applications > Development)
  3. Enter adb shell to fire up Debug Bridge and enter shell mode
  4. Enter su to become superuser
  5. Enter cat /data/app-private/filename.apk > /sdcard/filename.apk to copy the file to the SD card.
  6. exit
  7. exit
  8. And finally adb pull /sdcard/filename.apk filename.apk pulls the .apk file from your SD card to your computer.

Success? Problems? Moral issues with copying software? Let us know in the comments.

  1. December 22nd, 2009 at 14:08 | #1

    I installed eclipse + droid sdk with the most recent updates. When I run the commands above I get this.

    $ su
    su: permission denied

    *Also, I cannot see anything in the /data directory, thus a directory /data/app-private is not found either.

    Is there a way to elevate permissions without rooting my phone?

  2. spaz
    December 28th, 2009 at 00:02 | #2

    No there is not

  3. aziz
    January 2nd, 2010 at 13:34 | #3

    i tried the adb method.

    when i type in “cat /data/app-private/filename.apk > /sdcard/filename.apk” replacing filename.apk with the app im tryin to backup…i get error saying cannot create /sdcard/filename.apk: read-only file system.

    I followed the steps exactly as specified… i have a HTC Hero rooted running firmware 1.5.

    Help would be appreciated.

  4. Brian
    January 5th, 2010 at 13:48 | #4

    This has worked for me, however one thing everyone should be aware of (that I just ran in to) if you are planning to perform a hard-reset _for the purpose of changing the primary google email address_ is that you may have issues with the Android Market recognizing which apps you’ve purchased.

    Backing up the applications works fine, however if you perform a hard-reset and then change the primary google email address, the Market will no longer acknowledge that you’ve purchased an app (because it is associated with the original gmail address) and you won’t be able to receive app updates from the market unless you actually re-purchase & download the app via Android Market.

    So far the developers I’ve asked about this have been okay with issuing a refund for the second purchase if I could prove that I actually paid for the app, but this can definitely be a hassle so keep it in mind.

0 komentar:

Posting Komentar

Return top