users@glassfish.java.net

Re: Bug in Glassfish keystore and cacerts handling, can not recover key

From: Shing Wai Chan <Shing-Wai.Chan_at_Sun.COM>
Date: Thu, 05 Apr 2007 13:52:19 -0700

The command is
    asadmin change-master-password
You may need to revert the keystore password to the original one before
using the above command as they required the master-password to be
consistent with keystore password.
Regards,
    Shing Wai Chan

legolas wood wrote:
> Thanks,
> Can you tell me how to change the master password?
> keystore password is changeit and administration console password is
> adminadmin.
>
> I should say that when i delete the key that i insert myself into he
> keystore, it works fine, but when i insert my own key it bream.
>
> Thanks
>
>
> Shing Wai Chan wrote:
>> The error message seems to indicate that the master password does not
>> match with the keystore password
>>
>> Legolas Woodland wrote:
>>>
>>> Hi
>>> thank you for reading my post
>>> I think there is a bug in glasfish way of handling keystore and
>>> cacerts.
>>>
>>> as you can see in attached image (which is made using netbeans
>>> keytool module) I have two keys in my keystore file.
>>> when i start glassfish it shows an error like:
>>>
>>> java.lang.reflect.InvocationTargetException
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at com.sun.enterprise.server.PELaunch.main(PELaunch.java:272)
>>> Caused by: java.lang.ExceptionInInitializerError
>>> at
>>> com.sun.enterprise.security.SecurityLifecycle.onInitialization(SecurityLifecycle.java:88)
>>>
>>> at
>>> com.sun.enterprise.server.ApplicationServer.onInitialization
>>> (ApplicationServer.java:240)
>>> at
>>> com.sun.enterprise.server.ondemand.OnDemandServer.onInitialization(OnDemandServer.java:93)
>>>
>>> at com.sun.enterprise.server.PEMain.run(PEMain.java:316)
>>> at com.sun.enterprise.server.PEMain.main (PEMain.java:260)
>>> ... 5 more
>>> Caused by: java.lang.IllegalStateException:
>>> java.security.UnrecoverableKeyException: Cannot recover key
>>> at
>>> com.sun.enterprise.security.SSLUtils.<clinit>(SSLUtils.java :112)
>>> ... 10 more
>>> Caused by: java.security.UnrecoverableKeyException: Cannot recover key
>>> at
>>> sun.security.provider.KeyProtector.recover(KeyProtector.java:301)
>>> at sun.security.provider.JavaKeyStore.engineGetKey
>>> (JavaKeyStore.java:120)
>>> at java.security.KeyStore.getKey(KeyStore.java:731)
>>> at
>>> com.sun.net.ssl.internal.ssl.SunX509KeyManagerImpl.<init>(SunX509KeyManagerImpl.java:111)
>>>
>>> at
>>> com.sun.net.ssl.internal.ssl.KeyManagerFactoryImpl$SunX509.engineInit
>>> (KeyManagerFactoryImpl.java:41)
>>> at
>>> javax.net.ssl.KeyManagerFactory.init(KeyManagerFactory.java:192)
>>> at
>>> com.sun.enterprise.security.SSLUtils.initKeyManagers(SSLUtils.java:303)
>>> at com.sun.enterprise.security.SSLUtils
>>> .<clinit>(SSLUtils.java:89)
>>> ... 10 more
>>>
>>>
>>>
>>> do you know what is problem?
>>>
>>>
>>> ------------------------------------------------------------------------
>>>
>>>
>>> ------------------------------------------------------------------------
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
>>> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
>> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>