keytool error: java.io.IOException: Invalid keystore format

Invalid keystore format

1.

Find debug.keystore and delete  

Path User\username\android\debug.keystore  

My directory: C:\Users\growu\.android\debug.keystore

Re-run the current project after deletion , and a debug.keystore file will be automatically generated.

2.

File ---> Project Structure---->SDK Location ---> Gradle Srttings 

Enter the current project jdk root directory bin cmd (I use the jre that comes with AndroidStudio here) to enter the bin root path

D:\Software\Java\android\AndroidStudio\jre\bin

Then execute the keytool -list -v -keystore debug.keystore command to check for errors 

Specify the full path of debug.keystore, usually in the system disk, user name/.android directory:

keytool -list -v -keystore C:\Users\growu\.android\debug.keystore   switch to your own.

Default password for android debug.keystore

默认debug.keystore的信息如下:
Keystore name: “debug.keystore”
Keystore password: “android”
Key alias: “androiddebugkey”
Key password: “android”
CN: “CN=Android Debug,O=Android,C=US”

If an error is reported: keytool error: java.io.IOException: Invalid keystore format

 That is, the current project runs debug.keystore (you can go to the system user/.android directory to delete, and the project runs to create a new one) to generate the keystore and the JDK version to access the keystore is inconsistent. (Plainly speaking, jks is generated with a different version from the current jdk. For example, 1.8 and 11) and an error will be reported. (Projects need to pay more attention to the local configuration of multiple versions of jdk sometimes).

When the book is used, you will hate less, but when you get it on paper, you will feel shallow.

おすすめ

転載: blog.csdn.net/qq_33721320/article/details/125508058