org.apache.camel.util.jsse
Class BaseSSLContextParameters.SSLContextSpiDecorator

java.lang.Object
  extended by javax.net.ssl.SSLContextSpi
      extended by org.apache.camel.util.jsse.BaseSSLContextParameters.SSLContextSpiDecorator
Enclosing class:
BaseSSLContextParameters

protected static final class BaseSSLContextParameters.SSLContextSpiDecorator
extends SSLContextSpi

Class needed to provide decoration of an existing SSLContext. Since SSLContext is an abstract class and requires an instance of SSLContextSpi, this class effectively wraps an SSLContext as if it were an SSLContextSpi, allowing us to achieve decoration.


Constructor Summary
BaseSSLContextParameters.SSLContextSpiDecorator(SSLContext context, List<org.apache.camel.util.jsse.BaseSSLContextParameters.Configurer<SSLEngine>> sslEngineConfigurers, List<org.apache.camel.util.jsse.BaseSSLContextParameters.Configurer<SSLSocketFactory>> sslSocketFactoryConfigurers, List<org.apache.camel.util.jsse.BaseSSLContextParameters.Configurer<SSLServerSocketFactory>> sslServerSocketFactoryConfigurers)
           
 
Method Summary
protected  SSLEngine configureSSLEngine(SSLEngine engine)
          Configures an SSLEngine based on the configurers in instance.
protected  SSLServerSocketFactory configureSSLServerSocketFactory(SSLServerSocketFactory factory)
          Configures an SSLServerSocketFactory based on the configurers in this instance.
protected  SSLSocketFactory configureSSLSocketFactory(SSLSocketFactory factory)
          Configures an SSLSocketFactory based on the configurers in this instance.
protected  SSLEngine engineCreateSSLEngine()
           
protected  SSLEngine engineCreateSSLEngine(String peerHost, int peerPort)
           
protected  SSLSessionContext engineGetClientSessionContext()
           
protected  SSLSessionContext engineGetServerSessionContext()
           
protected  SSLServerSocketFactory engineGetServerSocketFactory()
           
protected  SSLSocketFactory engineGetSocketFactory()
           
protected  void engineInit(KeyManager[] km, TrustManager[] tm, SecureRandom random)
           
protected  SSLContext getDelegate()
           
 
Methods inherited from class javax.net.ssl.SSLContextSpi
engineGetDefaultSSLParameters, engineGetSupportedSSLParameters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseSSLContextParameters.SSLContextSpiDecorator

public BaseSSLContextParameters.SSLContextSpiDecorator(SSLContext context,
                                                       List<org.apache.camel.util.jsse.BaseSSLContextParameters.Configurer<SSLEngine>> sslEngineConfigurers,
                                                       List<org.apache.camel.util.jsse.BaseSSLContextParameters.Configurer<SSLSocketFactory>> sslSocketFactoryConfigurers,
                                                       List<org.apache.camel.util.jsse.BaseSSLContextParameters.Configurer<SSLServerSocketFactory>> sslServerSocketFactoryConfigurers)
Method Detail

engineCreateSSLEngine

protected SSLEngine engineCreateSSLEngine()
Specified by:
engineCreateSSLEngine in class SSLContextSpi

engineCreateSSLEngine

protected SSLEngine engineCreateSSLEngine(String peerHost,
                                          int peerPort)
Specified by:
engineCreateSSLEngine in class SSLContextSpi

engineGetClientSessionContext

protected SSLSessionContext engineGetClientSessionContext()
Specified by:
engineGetClientSessionContext in class SSLContextSpi

engineGetServerSessionContext

protected SSLSessionContext engineGetServerSessionContext()
Specified by:
engineGetServerSessionContext in class SSLContextSpi

engineGetServerSocketFactory

protected SSLServerSocketFactory engineGetServerSocketFactory()
Specified by:
engineGetServerSocketFactory in class SSLContextSpi

engineGetSocketFactory

protected SSLSocketFactory engineGetSocketFactory()
Specified by:
engineGetSocketFactory in class SSLContextSpi

engineInit

protected void engineInit(KeyManager[] km,
                          TrustManager[] tm,
                          SecureRandom random)
                   throws KeyManagementException
Specified by:
engineInit in class SSLContextSpi
Throws:
KeyManagementException

getDelegate

protected SSLContext getDelegate()

configureSSLEngine

protected SSLEngine configureSSLEngine(SSLEngine engine)
Configures an SSLEngine based on the configurers in instance. The return value from this method may be engine or it may be a decorated instance there of. Consequently, any subsequent actions on engine must be performed using the returned value.

Parameters:
engine - the engine to configure
Returns:
engine or a decorated instance there of

configureSSLSocketFactory

protected SSLSocketFactory configureSSLSocketFactory(SSLSocketFactory factory)
Configures an SSLSocketFactory based on the configurers in this instance. The return value from this method may be factory or it may be a decorated instance there of. Consequently, any subsequent actions on factory must be performed using the returned value.

Parameters:
factory - the factory to configure
Returns:
factory or a decorated instance there of

configureSSLServerSocketFactory

protected SSLServerSocketFactory configureSSLServerSocketFactory(SSLServerSocketFactory factory)
Configures an SSLServerSocketFactory based on the configurers in this instance. The return value from this method may be factory or it may be a decorated instance there of. Consequently, any subsequent actions on factory must be performed using the returned value.

Parameters:
factory - the factory to configure
Returns:
factory or a decorated instance there of


Apache CAMEL