edu.vt.middleware.ldap.ssl
Class X509CredentialConfig

java.lang.Object
  extended by edu.vt.middleware.ldap.ssl.X509CredentialConfig
All Implemented Interfaces:
CredentialConfig

public class X509CredentialConfig
extends Object
implements CredentialConfig

Provides the properties necessary for creating an SSL context initializer with a X509CredentialReader.

Version:
$Revision: 1106 $ $Date: 2010-01-29 23:34:13 -0500 (Fri, 29 Jan 2010) $
Author:
Middleware Services

Field Summary
protected  X509CertificateCredentialReader certReader
          Reads X.509 certificate credential.
protected  X509CertificatesCredentialReader certsReader
          Reads X.509 certificates credential.
protected  PrivateKeyCredentialReader keyReader
          Reads private key credential.
 
Constructor Summary
X509CredentialConfig()
           
 
Method Summary
 SSLContextInitializer createSSLContextInitializer()
          Creates an SSLContextInitializer using the configured trust and authentication material in this config.
 String getAuthenticationCertificate()
          This returns the name of the authentication certificate to use.
 String getAuthenticationKey()
          This returns the name of the authentication key to use.
 String getTrustCertificates()
          This returns the name of the trust certificates to use.
 void setAuthenticationCertificate(String s)
          This sets the name of the authentication certificate to use.
 void setAuthenticationKey(String s)
          This sets the name of the authentication key to use.
 void setTrustCertificates(String s)
          This sets the name of the trust certificates to use.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

certsReader

protected X509CertificatesCredentialReader certsReader
Reads X.509 certificates credential.


certReader

protected X509CertificateCredentialReader certReader
Reads X.509 certificate credential.


keyReader

protected PrivateKeyCredentialReader keyReader
Reads private key credential.

Constructor Detail

X509CredentialConfig

public X509CredentialConfig()
Method Detail

getTrustCertificates

public String getTrustCertificates()
This returns the name of the trust certificates to use.

Returns:
String trust certificates name

setTrustCertificates

public void setTrustCertificates(String s)
This sets the name of the trust certificates to use.

Parameters:
s - String trust certificates name

getAuthenticationCertificate

public String getAuthenticationCertificate()
This returns the name of the authentication certificate to use.

Returns:
String authentication certificate name

setAuthenticationCertificate

public void setAuthenticationCertificate(String s)
This sets the name of the authentication certificate to use.

Parameters:
s - String authentication certificate name

getAuthenticationKey

public String getAuthenticationKey()
This returns the name of the authentication key to use.

Returns:
String authentication key name

setAuthenticationKey

public void setAuthenticationKey(String s)
This sets the name of the authentication key to use.

Parameters:
s - String authentication key name

createSSLContextInitializer

public SSLContextInitializer createSSLContextInitializer()
                                                  throws GeneralSecurityException
Creates an SSLContextInitializer using the configured trust and authentication material in this config.

Specified by:
createSSLContextInitializer in interface CredentialConfig
Returns:
SSLContextInitializer
Throws:
GeneralSecurityException - if the ssl context initializer cannot be created


Copyright © 2003-2010 Virginia Tech. All Rights Reserved.