Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Protect android application from piracy [closed]

I am creating an application in Android. I want that once my application is installed on one device, user should not be able to copy the ".apk" and run it on other device. Please help me out. Thanks in advance. :)

like image 945
iPhoneCoder Avatar asked Jan 17 '11 08:01

iPhoneCoder


People also ask

How can you protect an app from piracy?

All in all, the best way to really secure your application from piracy is to correctly configure and use Proguard, Google Play Licensure, and to sign you final apk with a very secure license key. I'd like to point out that you don't need a rooted device to get a copy of an APK. ADB pull com.


2 Answers

The answer I'm about to give is not the answer you want to hear, but please read through, as I will justify this answer and give you an alternative model you might be able to use in your application.

In general, you should not look for a single method that will be absolutely successful in protecting your application from being pirated. A determined pirate will, at some point, be able to remove the protection, and distribute the modified application if there's enough interest in it.

Even relatively closed devices like the Apple iPhone have piracy problems with jail broken devices, and a determined attacker will, at some point, be able to open your app. I give you as a further example of the difficulty of protecting software: Microsoft Windows. If Microsoft and Apple, with all of their resources and expertise are unable to solve this problem in an effective manner, do you really think you'll be able to?

Instead, I would encourage you to program your app in such a way that you're using software features that rely on servers you control. That way, you're holding the keys to the kingdom. When people make a purchase, ask them for a login/password that ties them to the server.

For example, if you're programming a game, make a good portion of the game community features based, where you interact with other players through servers which you, as the developer/distributor, control.

A slight modification of this model allows the customer to access the application for free, but with a limited amount of functionality, then gain full functionality when they purchase. In that light, piracy ceases to be a problem, and indeed, even the motivation to pirate your app vanishes. In the end, a service based model like this is probably a better solution than relying on some technically wizardry in a vain attempt to protect your app from prying eyes.

like image 197
SplinterReality Avatar answered Oct 10 '22 09:10

SplinterReality


If you plan to distribute your app through the Android Market, use Android Market Licensing.

There's also a copy-protection option in the Android Market Publisher, but it has been deprecated and Google recommends to use licensing instead.

If you're not distributing the app through the Android Market, I'd recommend looking at the Android Market Licensing source code and implement a similar system with your own server.

like image 21
hpique Avatar answered Oct 10 '22 09:10

hpique