Monday, August 13, 2018

How to generate key or jks file using java keytool command

  • First open a command prompt (if using Windows, open the command prompt as an administrator) and navigate to your <JDK_HOME>\bin directory. Once there, generate the key store and private key using the command below.
keytool -genkey -alias <store name> -keyalg RSA -keysize 2048 -sigalg MD5withRSA -keypass <password> -keystore <store name>.jks -storepass <password>


1


Where <store name> is the name of the key store you want to use, <password> is the password you wish to use. You will be prompted to enter some additional information like below.

This command will generate blank jks file in your <JDK_HOME>\bin directory.

No comments:

Post a Comment

How to check whether operating system is 64 bit or 32bit?

What is 32 and 64 bit operating system? The terms 32-bit and 64-bit refer to the way a computer's processor that is CPU, handles info...