public class X509CredentialConfig extends Object implements CredentialConfig
X509CredentialReader
.Modifier and Type | Field and Description |
---|---|
protected X509CertificateCredentialReader |
certReader
Reads X.509 certificate credential.
|
protected X509CertificatesCredentialReader |
certsReader
Reads X.509 certificates credential.
|
protected PrivateKeyCredentialReader |
keyReader
Reads private key credential.
|
Constructor and Description |
---|
X509CredentialConfig() |
Modifier and Type | Method and Description |
---|---|
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.
|
protected X509CertificatesCredentialReader certsReader
protected X509CertificateCredentialReader certReader
protected PrivateKeyCredentialReader keyReader
public String getTrustCertificates()
String
trust certificates namepublic void setTrustCertificates(String s)
s
- String
trust certificates namepublic String getAuthenticationCertificate()
String
authentication certificate namepublic void setAuthenticationCertificate(String s)
s
- String
authentication certificate namepublic String getAuthenticationKey()
String
authentication key namepublic void setAuthenticationKey(String s)
s
- String
authentication key namepublic SSLContextInitializer createSSLContextInitializer() throws GeneralSecurityException
SSLContextInitializer
using the configured trust
and authentication material in this config.createSSLContextInitializer
in interface CredentialConfig
SSLContextInitializer
GeneralSecurityException
- if the ssl context initializer cannot be
createdCopyright © 2016. All rights reserved.