Upload a new app and sign with the Google Play App Signing service

3

I want to publish a new app and therefore I have activated the Google Play App Signing the little information that runs and details of the steps I'm not going from point 1 Sign your new APK with the upload key

In the Signature section, you can download the upload key that is a file deployment_cert.der

But what do you have to do with that file, where do I configure it with Android studio?

If I upload the apk signing with a keystore as I usually do, then I get that error:

  

Error loading Upload an APK that is signed with a key that   It is also used to sign the APKs that are sent to users. As   you are enrolled in the app signing program, you must use a   new password before uploading the file.

Tests

I usually use one for all apps, but apparently I had to generate one% new% co:

keystore

Ask me to assign a password, insert it, all the fields you ask also ... a keytool -genkey -v -keystore my-upload-key.jks -keyalg RSA -keysize 2048 -validity 10000 -alias my-alias is generated, sign the app from android studio referring to the file alias: my-alias and its password, the apk goes up perfectly.

Now in the my-upload-key.jks section of googleplay console it appears to download firmas that can be downloaded is a Subir certificado

Scenario 1 - loss of the original keystore

Keeping in mind that the service of upload_cert.der is so that if the user loses the keystore Google Play App Signing it can be restored without problem.

I generate another my-upload-key.jks using another password, I sign the apk and I upload it the error (obviously):

  

Error loading Upload an APK file that is not signed with the   load certificate and you should use it. The loading certificate   has the fingerprint [SHA1: ...: 89: 45] and the certificate that   you used to sign the APK has the fingerprint [SHA1: ...: B6: F0]

Searching the internet I found how to import a certificate my-upload-key.jks as I insert the der with an alias upload_cert.der

my-alias2

step: ask me if it's a secure certificate: yes

Now looking inside the keystore file, the correct signature appears and the apk should be uploaded.

In the dialog box, I put the key of the keystore, pull-down to select keytool -importcert -file openssl_crt.der -keystore my-upload-key.jks -alias my-alias2 -keypass n1k2e3y4p5a6s7s , the key field of the alias I put the established my-alias2 and I skip error with:

  

Error: Execution failed for task ': app: packageRelease'.   com.android.ide.common.signing.KeytoolException: Failed to read key my-alias2 from store "my-upload-key.jks": trusted certificate entries are not password-protected

Apparently not the import command the n1k2e3y4p5a6s7s part is as if it did not affect, but the signature process in the dialog box does not let me continue if I do not put any.

What I still need to try

I still have to try to sign the apk using command mode, to see if it's possible without using a key in the alias of the upload certificate.

How do you sign an apk in command mode under Windows?

    
asked by Webserveis 28.07.2017 в 10:32
source

0 answers