'apksigner' return with error #2

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By DinDinDin

I am trying to set up a project for making games for my Oculus Quest but I got stuck a an error message when trying to test a demo.

Here’s a screenshot of the error

A screenshot might help people understand your problem better.

alshahriorhasan | 2021-07-14 07:58

I added it, is it helpful?

DinDinDin | 2021-07-14 14:11

Are you trying to export release apk ? If you are release apk then create an key for release. Open JDK (version 8 is required, more recent versions won’t work)
Create key for debug
keytool -keyalg RSA -genkeypair -alias androiddebugkey -keypass android -keystore debug.keystore -storepass android -dname “CN=Android Debug,O=Android,C=US” -validity 9999 -deststoretype pkcs12

alshahriorhasan | 2021-07-14 14:29

Debug key will not work for release.

alshahriorhasan | 2021-07-14 14:31

Thank you very much, it worked!

DinDinDin | 2021-07-14 14:59

:bust_in_silhouette: Reply From: alshahriorhasan

Open JDK (version 8 is required, more recent versions won’t work)

Creating key for debug
keytool -keyalg RSA -genkeypair -alias androiddebugkey -keypass android -keystore debug.keystore -storepass android -dname “CN=Android Debug,O=Android,C=US” -validity 9999 -deststoretype pkcs12

Creating key for release
keytool -v -genkey -keystore mygame.keystore -alias mygame -keyalg RSA -validity 10000

This keystore and key are used to verify your developer identity, remember the password and keep it in a safe place!

Screenshot

I AM ALREADY USING A RELEASE KEYSTORE THEN ALSO THIS ERROR IS IRRITATING ME

iamnotdumbBUTiamdumb | 2021-07-24 17:42

When I try to create a release key, it says “Enter keystore password:”, but I cannot input words, only the enter button works

Tori | 2021-12-20 10:38

Password is invisibly. Just type your password then hit enter.

alshahriorhasan | 2021-12-22 05:16

:bust_in_silhouette: Reply From: nooarth

I simply updated the right versions of sdk files as godot doc said on android studio and it worked well.