Search code examples
androidauthenticationgoogle-playverification

Verifying the authenticity of an Android App


I have an Android library that is included in apps. For certain purposes, I need to verify if the app claiming to be X is actually X on the Play Store. One simplistic way is to verify if the app's package name is the same as the app that is on the Google Play store. But if the app is faking the package, how can we verify this?

Essentially, how can I verify the authenticity of an Android app with the Google Play Store? For example, I'd like to determine that an App (with my library in it) claiming to be Angry Birds is the real Angry birds and not an impersonator app with the same package name as Angry Birds?


Solution

  • You could verify the package name and the installation manager package. You can use the method:

     public abstract String getInstallerPackageName (String packageName)
    

    Retrieve the package name of the application that installed a package. This identifies which market the package came from.