An Android library that prevents your app from being pirated / cracked using Google Play Licensing (LVL), APK signature protection and more. API 14+ required.
.destroy()
to avoid ServiceConnection leaks. See the Wiki for a sample usage.Display.ACTIVITY
. Use .withActivityColor(R.color.colorPrimary, R.color.colorPrimaryDark)
to customize the activity with your own colours..enableInstallerId(InstallerID.GALAXY_APPS)
.blockIfUnauthorizedAppDetected(...)
by blockIfUnauthorizedAppUninstalled(...)
.Bug fixes.
.display(Display.ACTIVITY)
. This way you make sure that the main activity of the app is finished..enableUnauthorizedAppsCheck()
. You can even block your app when this pirate apps has been uninstalled. See "Verify the use of pirate apps" for more details..enableStoresCheck()
..enableDebugCheck()
to check if app is a debug build..enableEmulatorCheck()
to check if app is being run in an emulator..saveResultToSharedPreferences(preferences, preferenceName)
to save the result of the license check in SharedPreferences
. See the README for more details.A huge thanks to @jahirfiquitiva for his PR 👏
.display(Display.ACTIVITY)
. This way you make sure that the main activity of the app is finished..enableUnauthorizedAppsCheck()
. You can even block your app when this pirate apps has been uninstalled. See "Verify the use of pirate apps" for more details..enableStoresCheck()
..enableDebugCheck()
to check if app is a debug build..enableEmulatorCheck()
to check if app is being run in an emulator..saveResultToSharedPreferences(preferences, preferenceName)
to save the result of the license check in SharedPreferences
. See the README for more details.A huge thanks to @jahirfiquitiva for his PR 👏
<uses-permission android:name="com.android.vending.CHECK_LICENSE"/>
.callback(new PiracyCheckerCallback() {
@Override
public void allow() {
// Do something when the user is allowed to use the app
}
@Override
public void dontAllow(PiracyCheckerError error) {
// You can either do something specific when the user is not allowed to use the app
// Or manage the error, using the 'error' parameter, yourself (Check errors at {@link PiracyCheckerError}).
}
@Override
public void onError(PiracyCheckerError error) {
// This method is not required to be implemented/overriden but...
// You can either do something specific when an error occurs while checking the license,
// Or manage the error, using the 'error' parameter, yourself (Check errors at {@link PiracyCheckerError}).
}
})
Huge thanks to @jahirfiquitiva for his PR #11.
.enableInstallerId(InstallerID.AMAZON_APP_STORE)
.enableInstallerId()
now supports multiple installers. For example:.enableInstallerId(InstallerID.GOOGLE_PLAY)
.enableInstallerId(InstallerID.AMAZON_APP_STORE)
Initial release.