Package edu.vt.middleware.ldap.ssl
Class KeyStoreCredentialConfig
- java.lang.Object
-
- edu.vt.middleware.ldap.ssl.KeyStoreCredentialConfig
-
- All Implemented Interfaces:
CredentialConfig
public class KeyStoreCredentialConfig extends java.lang.Object implements CredentialConfig
Provides the properties necessary for creating an SSL context initializer with aKeyStoreCredentialReader.- Version:
- $Revision: 1106 $ $Date: 2010-01-29 23:34:13 -0500 (Fri, 29 Jan 2010) $
- Author:
- Middleware Services
-
-
Field Summary
Fields Modifier and Type Field Description protected KeyStoreCredentialReaderkeyStoreReaderHandles loading keystores.
-
Constructor Summary
Constructors Constructor Description KeyStoreCredentialConfig()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SSLContextInitializercreateSSLContextInitializer()Creates anSSLContextInitializerusing the configured trust and authentication material in this config.java.lang.StringgetKeyStore()This returns the name of the keystore to use.java.lang.StringgetKeyStorePassword()This returns the password for the keystore.java.lang.StringgetKeyStoreType()This returns the type of the keystore.java.lang.StringgetTrustStore()This returns the name of the truststore to use.java.lang.StringgetTrustStorePassword()This returns the password for the truststore.java.lang.StringgetTrustStoreType()This returns the type of the truststore.voidsetKeyStore(java.lang.String s)This sets the name of the keystore to use.voidsetKeyStorePassword(java.lang.String s)This sets the password for the keystore.voidsetKeyStoreType(java.lang.String s)This sets the type of the keystore.voidsetTrustStore(java.lang.String s)This sets the name of the truststore to use.voidsetTrustStorePassword(java.lang.String s)This sets the password for the truststore.voidsetTrustStoreType(java.lang.String s)This sets the type of the truststore.
-
-
-
Field Detail
-
keyStoreReader
protected KeyStoreCredentialReader keyStoreReader
Handles loading keystores.
-
-
Method Detail
-
getTrustStore
public java.lang.String getTrustStore()
This returns the name of the truststore to use.- Returns:
Stringtruststore name
-
setTrustStore
public void setTrustStore(java.lang.String s)
This sets the name of the truststore to use.- Parameters:
s-Stringtruststore name
-
getTrustStorePassword
public java.lang.String getTrustStorePassword()
This returns the password for the truststore.- Returns:
Stringtruststore password
-
setTrustStorePassword
public void setTrustStorePassword(java.lang.String s)
This sets the password for the truststore.- Parameters:
s-Stringtruststore password
-
getTrustStoreType
public java.lang.String getTrustStoreType()
This returns the type of the truststore.- Returns:
Stringtruststore type
-
setTrustStoreType
public void setTrustStoreType(java.lang.String s)
This sets the type of the truststore.- Parameters:
s-Stringtruststore type
-
getKeyStore
public java.lang.String getKeyStore()
This returns the name of the keystore to use.- Returns:
Stringkeystore name
-
setKeyStore
public void setKeyStore(java.lang.String s)
This sets the name of the keystore to use.- Parameters:
s-Stringkeystore name
-
getKeyStorePassword
public java.lang.String getKeyStorePassword()
This returns the password for the keystore.- Returns:
Stringkeystore password
-
setKeyStorePassword
public void setKeyStorePassword(java.lang.String s)
This sets the password for the keystore.- Parameters:
s-Stringkeystore password
-
getKeyStoreType
public java.lang.String getKeyStoreType()
This returns the type of the keystore.- Returns:
Stringkeystore type
-
setKeyStoreType
public void setKeyStoreType(java.lang.String s)
This sets the type of the keystore.- Parameters:
s-Stringkeystore type
-
createSSLContextInitializer
public SSLContextInitializer createSSLContextInitializer() throws java.security.GeneralSecurityException
Creates anSSLContextInitializerusing the configured trust and authentication material in this config.- Specified by:
createSSLContextInitializerin interfaceCredentialConfig- Returns:
SSLContextInitializer- Throws:
java.security.GeneralSecurityException- if the ssl context initializer cannot be created
-
-