If you’re trying to use Google’s Licensing mechanism, solution that worked for me:
// explicit Intent, safe
Intent serviceIntent = new Intent(ILicensingService.class.getName());
serviceIntent.setPackage("com.android.vending");
boolean bindResult = mContext.bindService(serviceIntent, this, Context.BIND_AUTO_CREATE);
This is located in com/google/android/vending/licensing/LicenseChecker.java
. Do a search for “Base64.decode(
“
Edit:
Adding reference to Google Licensing java file that has to be patched:
com.google.android.vending.licensing.LicenseChecker.checkAccess(LicenseChecker.java:150)
patch:
new String(
- Base64.decode("Y29tLmFuZHJvaWQudmVuZGluZy5saWNlbnNpbmcuSUxpY2Vuc2luZ1NlcnZpY2U="))),
+ Base64.decode("Y29tLmFuZHJvaWQudmVuZGluZy5saWNlbnNpbmcuSUxpY2Vuc2luZ1NlcnZpY2U=")))
+ .setPackage("com.android.vending"), // this fix the 'IllegalArgumentException: Service Intent must be explicit'
this, // ServiceConnection.
Source: https://code.google.com/p/android/issues/detail?id=78505#c19