Keytool import error
I have installed the following version of GlassFish Application Server,
# ./asadmin version
Version = Sun GlassFish Enterprise Server v2.1.1
I followed the below steps to install a certificate signed by a CA,
1. Deleted the existing certificate using the following command,
keytool -delete -alias s1as -keystore keystore.jks -storepass
2. Then generated the key pair
keytool -genkeypair -keyalg RSA -keystore keystore.jks -validity -alias s1as
3. Then created a certificate request for getting it signed by CA
keytool -certreq -alias s1as -file -keystore keystore.jks -storepass
4. Then importing the signed certificate
keytool -import -v -alias s1as -file s1as.cert -keystore keystore.jks -storepass
The above steps where given by CA using the the url, http://blogs.sun.com/enterprisetechtips/entry/using_ssl_with_glassfish_v2.
When trying to import the certificate I get the following error,
# keytool -import -v -alias s1as -file s1as.cert -keystore keystore.jks -storepass
keytool error: java.lang.Exception: Failed to establish chain from reply
java.lang.Exception: Failed to establish chain from reply
It would be really nice if someone could help me out here and few forums suggest to convert the format of the certificate file to pkcs#7 format, but I dont find the exact commands to do it. I used the tool suggested in the below url, but didnt help.
It would be really nice if someone could help since I have been stuck with the issue for almost 4 weeks.
Thanks in Advance.