How do I get (or view) an Android app base 64 public key? I have the license file, and I have published my app before.
I need the key for licensing.
How do I get (or view) an Android app base 64 public key? I have the license file, and I have published my app before.
I need the key for licensing.
To find the public licensing key for your app perform the following steps...
1.) Login to the Google Play Developer console from where you published your app
2.) Click on your app in the list of apps
3.) Click on Developer Tools on the left menu
3.) Select Services & API's
4.) Under Licensing & In-App billing you will see the public key
To add licensing to an application, you must obtain your publisher account's public key for licensing and copy it into your application. Here's how to find your account's public key for licensing:
Go to the Google Play publisher site and sign in. Make sure that you sign in to the account from which the application you are licensing is published (or will be published). In the account home page, locate the "Edit profile" link and click it. In the Edit Profile page, locate the "Licensing" pane, shown below. Your public key for licensing is given in the "Public key" text box.
Source http://developer.android.com/guide/google/play/licensing/adding-licensing.html
Your base64 string is possibly an X509EncodedKeySpec. I can only guess. If so, you should base64 decode the string to obtain a byte []. Then construct an X509EncodedKeySpec from this byte []. Then create an instance of an RSA KeyFactory, and use the generatePublic() method of this KeyFactory to obtain a PublicKey. This public key can then be passed to Cipher.init()