APK with invalid signature

Hi, so I have currently build an APK and I was planning to upload it to the Google Play Store. But problem occurred when I want to upload the apk file to the production. Here is the error:

So, I have checked anyone with the same issues and there are some solution that might worked for some of us. One of the solution is to tick the box of V1 and V2 like this:

image

So, I was wondering what is the V1 and V2 box and where I can find it. Plus is it applicable for ionic.

Thank you in advance

The Key (Keystore File) that you have used for earlier version of the apk is not the same at this build version. Replace KeyStore file and test again

Hi,

I am sorry I don’t quite get it. Do i need to re-generate another keystore or there is any command that can be used to update or replace the keystore. I tried google for the answer but nothing I got so far.

I tried this command as suggested by my friend:

apksigner sign --ks my-release-key.keystore app.apk

but after I enter the password, the result turned to this:

Failed to load signer "signer #1"
java.io.FileNotFoundException: my-release-key.keystore (The system cannot find the file specified)
        at java.io.FileInputStream.open0(Native Method)
        at java.io.FileInputStream.open(FileInputStream.java:195)
        at java.io.FileInputStream.<init>(FileInputStream.java:138)
        at java.io.FileInputStream.<init>(FileInputStream.java:93)
        at com.android.apksigner.ApkSignerTool$SignerParams.loadKeyStoreFromFile(ApkSignerTool.java:832)
        at com.android.apksigner.ApkSignerTool$SignerParams.loadPrivateKeyAndCertsFromKeyStore(ApkSignerTool.java:723)
        at com.android.apksigner.ApkSignerTool$SignerParams.loadPrivateKeyAndCerts(ApkSignerTool.java:663)
        at com.android.apksigner.ApkSignerTool$SignerParams.access$500(ApkSignerTool.java:615)

I am actually not really good with this and still in learning process so your kind help is much appreciated.

Thank you

hello,
the error indicates that he didn’t find the file my-release-key.keystore. Specify the path to this file. If the path contains spaces you need enclose it with “”.

If you have not uploaded any version of your apk to store, then, only then, you can create a new one. Otherwise find this f*** file and keep it save.

Best regards, annaliebt