Reputation: 410
I am trying to generate keystore for my application using keytool command follows:
keytool -genkey -alias tomcat -keystore tomcat.keystore -keyalg RSA -keysize 2048 < keystore.data.txt
And it's working fine with JDK5 and not working with JDK6. FYI:
When executing with JDK5
Enter keystore password: What is your first and last name?
[Unknown]: What is the name of your organizational unit?
[Unknown]: What is the name of your organization?
[Unknown]: What is the name of your City or Locality?
[Unknown]: What is the name of your State or Province?
[Unknown]: What is the two-letter country code for this unit?
[Unknown]: Is CN=tpserver-hostname, OU=MyCompany, O=MyOrg., L=MyCity, ST=MyState (ST), C=IN correct?
[no]:
Enter key password for <tomcat>
(RETURN if same as keystore password):
When executing same with JDK6
Enter keystore password: Re-enter new password: They don't match. Try again
Enter keystore password: Re-enter new password: They don't match. Try again
Enter keystore password: Re-enter new password: They don't match. Try again
Too many failures - try later
Please Help me.
Upvotes: 1
Views: 47
Reputation: 136
Yes, you are correc. 'Re-enter new password' is added since JDK6. So you have to enter after password
Upvotes: 1
Reputation: 410
I got solution for my problem.
'Re-enter new password:' is new in jdk6 & jdk7 version and not asking with jdk5. So, copied and added new password under password in my 'keystore.data.txt' file then able to generate keystore file.
Upvotes: 1