Class SslClientConnectionFactory

java.lang.Object
org.eclipse.jetty.io.ssl.SslClientConnectionFactory
All Implemented Interfaces:
ClientConnectionFactory

public class SslClientConnectionFactory extends Object implements ClientConnectionFactory

A ClientConnectionFactory that creates client-side SslConnection instances.

  • Field Details

    • SSL_CONTEXT_FACTORY_CONTEXT_KEY

      public static final String SSL_CONTEXT_FACTORY_CONTEXT_KEY
      See Also:
    • SSL_PEER_HOST_CONTEXT_KEY

      public static final String SSL_PEER_HOST_CONTEXT_KEY
      See Also:
    • SSL_PEER_PORT_CONTEXT_KEY

      public static final String SSL_PEER_PORT_CONTEXT_KEY
      See Also:
    • SSL_ENGINE_CONTEXT_KEY

      public static final String SSL_ENGINE_CONTEXT_KEY
      See Also:
    • sslContextFactory

      private final SslContextFactory sslContextFactory
    • byteBufferPool

      private final ByteBufferPool byteBufferPool
    • executor

      private final Executor executor
    • connectionFactory

      private final ClientConnectionFactory connectionFactory
    • _directBuffersForEncryption

      private boolean _directBuffersForEncryption
    • _directBuffersForDecryption

      private boolean _directBuffersForDecryption
    • _requireCloseMessage

      private boolean _requireCloseMessage
  • Constructor Details

  • Method Details

    • setDirectBuffersForEncryption

      public void setDirectBuffersForEncryption(boolean useDirectBuffers)
    • setDirectBuffersForDecryption

      public void setDirectBuffersForDecryption(boolean useDirectBuffers)
    • isDirectBuffersForDecryption

      public boolean isDirectBuffersForDecryption()
    • isDirectBuffersForEncryption

      public boolean isDirectBuffersForEncryption()
    • isAllowMissingCloseMessage

      @Deprecated public boolean isAllowMissingCloseMessage()
      Deprecated.
      Returns:
      whether is not required that peers send the TLS close_notify message
    • setAllowMissingCloseMessage

      @Deprecated public void setAllowMissingCloseMessage(boolean allowMissingCloseMessage)
      Deprecated.
      Parameters:
      allowMissingCloseMessage - whether is not required that peers send the TLS close_notify message
    • isRequireCloseMessage

      public boolean isRequireCloseMessage()
      Returns:
      whether peers must send the TLS close_notify message
      See Also:
    • setRequireCloseMessage

      public void setRequireCloseMessage(boolean requireCloseMessage)
      Parameters:
      requireCloseMessage - whether peers must send the TLS close_notify message
      See Also:
    • newConnection

      public Connection newConnection(EndPoint endPoint, Map<String,Object> context) throws IOException
      Specified by:
      newConnection in interface ClientConnectionFactory
      Parameters:
      endPoint - the EndPoint to link the newly created connection to
      context - the context data to create the connection
      Returns:
      a new Connection
      Throws:
      IOException - if the connection cannot be created
    • newSslConnection

      protected SslConnection newSslConnection(ByteBufferPool byteBufferPool, Executor executor, EndPoint endPoint, SSLEngine engine)
    • customize

      public Connection customize(Connection connection, Map<String,Object> context)
      Specified by:
      customize in interface ClientConnectionFactory