|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.net.SocketFactory
javax.net.ssl.SSLSocketFactory
org.ldaptive.ssl.AbstractTLSSocketFactory
org.ldaptive.ssl.TLSSocketFactory
org.ldaptive.ssl.ThreadLocalTLSSocketFactory
public class ThreadLocalTLSSocketFactory
TLSSocketFactory implementation that uses a thread local variable to store configuration. Useful for SSL configurations that can only retrieve the SSLSocketFactory from getDefault().
| Field Summary |
|---|
| Fields inherited from class org.ldaptive.ssl.AbstractTLSSocketFactory |
|---|
DEFAULT_PROTOCOL, factory, logger |
| Constructor Summary | |
|---|---|
ThreadLocalTLSSocketFactory()
|
|
| Method Summary | |
|---|---|
static SocketFactory |
getDefault()
This returns the default SSL socket factory. |
static SSLSocketFactory |
getHostnameVerifierFactory(SslConfig config,
String[] names)
Returns an instance of this socket factory configured with a hostname verifying trust manager. |
SslConfig |
getSslConfig()
Returns the SSL configuration used by this socket factory. |
void |
removeSslConfig()
Removes the ssl config from the current thread-local value. |
void |
setSslConfig(SslConfig config)
Sets the SSL configuration used by this socket factory. |
String |
toString()
|
| Methods inherited from class org.ldaptive.ssl.TLSSocketFactory |
|---|
addHostnameVerifyingTrustManager, createSSLContextInitializer, initialize |
| Methods inherited from class org.ldaptive.ssl.AbstractTLSSocketFactory |
|---|
createSocket, createSocket, createSocket, createSocket, createSocket, createSocket, getDefaultCipherSuites, getFactory, getHostnameVerifier, getSocketConfig, getSupportedCipherSuites, initSSLSocket, setHostnameVerifier, setSocketConfig |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ThreadLocalTLSSocketFactory()
| Method Detail |
|---|
public SslConfig getSslConfig()
getSslConfig in class AbstractTLSSocketFactorypublic void setSslConfig(SslConfig config)
setSslConfig in class AbstractTLSSocketFactoryconfig - ssl configpublic void removeSslConfig()
public static SocketFactory getDefault()
public static SSLSocketFactory getHostnameVerifierFactory(SslConfig config,
String[] names)
HostnameVerifyingTrustManager with DefaultHostnameVerifier is set. See TLSSocketFactory.addHostnameVerifyingTrustManager(SslConfig, String[]).
config - to set on the socket factorynames - to use for hostname verification
public String toString()
toString in class TLSSocketFactory
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||