16

I have created a test app on Play store, to test out the Google Play Signing functions. As soon as I create the test app and enabled the feature, I had access to "Deployment Certificate". I didn't download it or used it in any way. Following are the steps I followed:

  1. Then using Android Studio, I create a new keystore, giving it a password and created an alias with a password (as usual).
  2. Signed the app with keystore created in step 1 Uploaded the app to Google Play store.
  3. Downloaded the Upload Key certificate. Added the Upload Key certificate to my keystore created in step 1 using command keytool.exe -importcert -file upload.der -keystore mykeystore.keystore
  4. Check if it is added to keystore using command keytool.exe -list -keystore mykeystore.keystore. There are now two alias, a new alias (named mykey) added in step 3. It is of the type trusted certificate.

Now as "Trusted certificate entries are not password-protected", without an alias password Android Studio does not allow me to sign the app and of course I cannot use a random password as they are "not password-protected". how do I use it to sign my apk for future updates? Am I missing something crucial here or my understanding is incorrect?

Atif Farrukh
  • 2,219
  • 2
  • 25
  • 47

2 Answers2

0

If you opt-in to use google managed signing key you will have access to 'Deployment Certificates' after you uploaded (released) your first APK where as 'Signing Certificates' will be available immediately from the App integrity page.

Regarding your steps, I think you are almost there except you don't need step 3 & 4.
You have already signed your app and uploaded it to Play Console on step 2. Note that the keystore you created on step 1 already contains your upload key (in fact both private(upload key) and public key), so on step 3 you are downloading the same public key (Deployment Certificate) and adding it to your store.

The 'Deployment Certificate' is downloadable in case you want to share it with 3rd party API developers which use app package name and certificate as an auth/trust mechanism. They are not used to sign APK or anything; They are not secure anyway. They are just public keys and it is all safe to share them and no need to password protect them.

dsharew
  • 10,377
  • 6
  • 49
  • 75
-1

Use Upload Certificate,upload_cert.der, not App Signing Certificate deployment_cert.der. You can download it in Google Play Console right under App Signing Certificate.

Trent Steele
  • 142
  • 1
  • 5