Nuxtstop

For all things nuxt.js

Common errors found when generating Android certificates (and how to fix them!)

5 0

AppGallery supports two kinds of signing certificates: one that is totally generated by AppGallery Connect and the other one that is generated by developers. Here I will share some solutions with you for the common errors reported during the signing certificate generation.
The command in the official document is as follows:

Error 1 - "No value provided for flag: include-cer"

Image description
Cause: It is not the correct pepk.jar file. Normally, its file size is around 2 MB. Check whether it is the file that was provided by Android Studio.
Solution: Use the correct pepk.jar file that you can get from Google.

Error 2: "java.io.IOException: Keystore was tampered with, or password was incorrect"

Image description
Cause: The keystore password is most likely not correct.
Solution: Enter the correct password.

Error 3: "Unable to export or encrypt the private key"

Image description
Cause: Incorrect password. The keystore password is entered correctly, but the key file password is entered incorrectly when entered for the second time.
Solution: Enter the correct key file password.

Error 4: "Unable to parse the input:"

Image description
Cause: The length of the encryption key is incorrect. Check whether you have copied the complete encryption key.
Solution: Use the complete encryption key.

Error 5: "java.lang.IllegalArgumentException: publicKey should be 68 bytes"

Image description
Image description
Cause: The length of the encryption key is incorrect. Check whether you have copied the complete encryption key.
Solution: Use the complete encryption key.

Error 6: "java.lang.IllegalArgumentException: Hex encoded byte array must have even length but instead has length: 143."

Image description
Cause: The encryption key is too long.
Solution: Use the correct encryption key

Error 7: "java.security.GeneralSecurityException: point is not on the curve"

Image description
Cause: The encryption key is incorrect.
Solution: Use the correct encryption key.