public class SMProxyTrustStoreSingleton extends java.lang.Object implements LogoutListener
To overcome this limitation, this object is created as a Singleton, a single instance of a static object so that the required proxy SSL configuration parameters can be created from the static context of the SMProxySSLSocketFactory.getDefault() method.
Note: The SMProxyTrustStoreSingleton can be returned from any context by calling:
SMProxyTrustStoreSingleton.getSMProxyTrustStoreSingleton();
| Modifier and Type | Method and Description |
|---|---|
boolean |
addCertificate(java.security.cert.X509Certificate cert)
Adds a certificate to this object.
|
void |
addCertificates(java.security.cert.X509Certificate[] certs)
Adds a certificate to the SMProxy trustStore.
|
void |
clearTrustStore()
Clears the list of certificates, trustStore used by SMProxy.
|
JSSEX509KeyManager |
getKeyManager()
Returns a previously set JSSEX509KeyManager
|
java.security.cert.X509Certificate[] |
getSMProxyTrustStoreCerts()
Returns the list of trusted certificates that are stored by the
Singleton object.
|
static SMProxyTrustStoreSingleton |
getSMProxyTrustStoreSingleton()
Returns the SMProxyTrustStoreSingleton.
|
JSSEX509TrustManager |
getTrustManager()
Returns the JSSEX509TrustManager.
|
void |
logout()
The logout callback function; called from the user when logging out.
|
boolean |
removeCertificate(java.security.cert.X509Certificate cert)
Removes a certificate from the SMProxy trustStore if it is contained in the
trustStore
|
void |
setKeyManager(JSSEX509KeyManager keyManager)
Sets the JSSEX509KeyManager to use for SMProxy SSL connections
|
void |
setTrustManager(JSSEX509TrustManager trustManager)
Sets the JSSEX509TrustManager to use for SMProxy SSL connections
|
public boolean addCertificate(java.security.cert.X509Certificate cert)
cert - the certificate to addtrue if the certificate was added, false
if it was not addedpublic boolean removeCertificate(java.security.cert.X509Certificate cert)
cert - the certificate to addtrue if the certificate was removed, false
if it was not removed.public void addCertificates(java.security.cert.X509Certificate[] certs)
certs - the certificates to addpublic static SMProxyTrustStoreSingleton getSMProxyTrustStoreSingleton()
public java.security.cert.X509Certificate[] getSMProxyTrustStoreCerts()
public void clearTrustStore()
public JSSEX509TrustManager getTrustManager()
public void setTrustManager(JSSEX509TrustManager trustManager)
trustManager - the JSSEX509TrustManager to setpublic JSSEX509KeyManager getKeyManager()
public void setKeyManager(JSSEX509KeyManager keyManager)
keyManager - the JSSEX509KeyManager to setpublic void logout()
LogoutListenerlogout in interface LogoutListener