Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between keyStorePassword and keyManagerPassword in Jetty?

I am looking at SSL for Jetty: http://wiki.eclipse.org/Jetty/Reference/SSL_Connectors

There are properties for both keyStorePassword and keyManagerPassword. I suppose the keyManagerPassword is used by a Javax KeyManager, and so is a password for recovering keys from the key store?

So do keyStorePassword and keyManagerPassword then generally have the same value?

like image 295
jareilly Avatar asked Jun 01 '12 09:06

jareilly


2 Answers

Keymanagerfactory does have a password.

hmmm it is a little history and evolution in these APIs and they could perhaps be made clearer.

The keyManagerPassword is passed as the password arg to KeyManagerFactory.init(...) If there is no keymanagerpassword, then the keystorepassword is used instead. If there is no trustmanager set, then the keystore is used as the trust store and the keystorepassword is used as the truststore password.

like image 85
Greg Wilkins Avatar answered Sep 27 '22 21:09

Greg Wilkins


keyManagerPassword looks like a misfeature. It is the keystore that has the password, not the KeyManager. There's no reference to a key manager password in the Javadoc for the classes concerned.

like image 43
user207421 Avatar answered Sep 27 '22 21:09

user207421