How to Create a Self Signed Certificate using Java Keytool

1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 5.00 out of 5)
Loading...
SSL Certificate is also important to secure java application using a self signing certificate. In most cases you must use a CA verified certificate but you can also use a self signed cert to secure your java app.
comodologo

Comodo Positive SSL

95% OFF – Comodo Positive SSL Certificate at $6.50

Read More

thawtelogo-verticle

Thawte SSL123 Certificate

75% OFF – Thawte SSL123 Certificate at $42.30

Read More

comodologo

Comodo Positive SSL Multi Domain

95% OFF – Comodo Positive Multi Domain SSL at $17.5 – 2 SAN Included

Read More

Steps to create a Self Signed Certificate using Java Keytool

Step 1. Open the command console

Step 2. Run this command (Where indicate the number of days for which the certificate will be valid)
keytool -genkey -keyalg RSA -alias selfsigned -keystore keystore.jks -storepass password -validity 365 -keysize 2048

Step 3. Enter a password for the keystore. Note this password as you require this for configuring the server

Step 4. When prompted for first name and last name, enter the domain name of the server. For example, myserver or myserver.mycompany.com.

Step 5. Enter the other details, such as Organizational Unit, Organization, City, State, and Country.

Step 6. When prompted with Enter key password for , press Enter to use the same password as the keystore password

Step 7. Run this command to verify the contents of the keystore
keytool -list -v -keystore selfsigned.jks

Step 8. When prompted, enter the keystore password note in Step 3. The basic information about the generated certificate is displayed. Verify that the Owner and Issuer are the same. Also, you should see the information you provided in Step 4 and 5.

Download Site Seal
comodo-trust-seal
SSL Checker

Pin It on Pinterest

Shares
Share This