org.apache.tomcat.util.net

## Class AbstractJsseEndpoint<S>

- java.lang.Object
- - org.apache.tomcat.util.net.AbstractEndpoint<S>
  - - org.apache.tomcat.util.net.AbstractJsseEndpoint<S>

- Direct Known Subclasses:
    Nio2Endpoint, NioEndpoint

      public abstract class AbstractJsseEndpoint<S>
      extends AbstractEndpoint<S>

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class org.apache.tomcat.util.net.AbstractEndpoint

      `AbstractEndpoint.Acceptor, AbstractEndpoint.BindState, AbstractEndpoint.Handler<S>`

  - ### Field Summary

    - ### Fields inherited from class org.apache.tomcat.util.net.AbstractEndpoint

      `acceptors, acceptorThreadCount, acceptorThreadPriority, attributes, internalExecutor, negotiableProtocols, paused, processorCache, running, sm, socketProperties, sslHostConfigs, threadPriority`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractJsseEndpoint()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `createSSLContext(SSLHostConfig sslHostConfig)` Create the SSLContextfor the the given SSLHostConfig.
    `protected SSLEngine` | `createSSLEngine(String sniHostName, List<Cipher> clientRequestedCiphers, List<String> clientRequestedApplicationProtocols)`
    `protected InetSocketAddress` | `getLocalAddress()` Obtain the network address the server socket is bound to.
    `protected abstract NetworkChannel` | `getServerSocket()`
    `int` | `getSniParseLimit()`
    `SSLImplementation` | `getSslImplementation()`
    `String` | `getSslImplementationName()`
    `void` | `init()`
    `protected void` | `initialiseSsl()`
    `boolean` | `isAlpnSupported()` Identifies if the endpoint supports ALPN.
    `void` | `setSniParseLimit(int sniParseLimit)`
    `void` | `setSslImplementationName(String s)`
    `void` | `unbind()`

    - ### Methods inherited from class org.apache.tomcat.util.net.AbstractEndpoint

      `addNegotiatedProtocol, addSslHostConfig, addSslHostConfig, bind, closeServerSocketGraceful, countDownConnection, countUpOrAwaitConnection, createAcceptor, createExecutor, createSocketProcessor, destroy, destroySsl, doCloseServerSocket, findSslHostConfigs, getAcceptCount, getAcceptorThreadCount, getAcceptorThreadPriority, getAddress, getAttribute, getBacklog, getBindOnInit, getConnectionCount, getConnectionLinger, getConnectionTimeout, getCurrentThreadCount, getCurrentThreadsBusy, getDaemon, getDefaultSSLHostConfigName, getDeferAccept, getDomain, getExecutor, getExecutorTerminationTimeoutMillis, getHandler, getKeepAliveTimeout, getLocalPort, getLog, getMaxConnections, getMaxHeaderCount, getMaxKeepAliveRequests, getMaxThreads, getMinSpareThreads, getName, getPort, getProperty, getSocketProperties, getSoLinger, getSoTimeout, getSSLHostConfig, getTcpNoDelay, getThreadPriority, getUseAsyncIO, getUseSendfile, handleExceptionWithDelay, hasNegotiableProtocols, initializeConnectionLatch, isPaused, isRunning, isSSLEnabled, pause, processSocket, releaseConnectionLatch, releaseSSLContext, reloadSslHostConfig, reloadSslHostConfigs, removeSslHostConfig, resume, setAcceptCount, setAcceptorThreadCount, setAcceptorThreadPriority, setAddress, setAttribute, setBacklog, setBindOnInit, setConnectionLinger, setConnectionTimeout, setDaemon, setDefaultSSLHostConfigName, setDomain, setExecutor, setExecutorTerminationTimeoutMillis, setHandler, setKeepAliveTimeout, setMaxConnections, setMaxHeaderCount, setMaxKeepAliveRequests, setMaxThreads, setMinSpareThreads, setName, setPort, setProperty, setSoLinger, setSoTimeout, setSSLEnabled, setTcpNoDelay, setThreadPriority, setUseAsyncIO, setUseSendfile, shutdownExecutor, start, startAcceptorThreads, startInternal, stop, stopInternal, toTimeout, unlockAccept`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### AbstractJsseEndpoint

          public AbstractJsseEndpoint()

  - ### Method Detail

    - #### getSslImplementationName

          public String getSslImplementationName()

    - #### setSslImplementationName

          public void setSslImplementationName(String s)

    - #### getSslImplementation

          public SSLImplementation getSslImplementation()

    - #### getSniParseLimit

          public int getSniParseLimit()

    - #### setSniParseLimit

          public void setSniParseLimit(int sniParseLimit)

    - #### initialiseSsl

          protected void initialiseSsl()
                                throws Exception

      Throws:
        `Exception`

    - #### createSSLContext

          protected void createSSLContext(SSLHostConfig sslHostConfig)
                                   throws IllegalArgumentException

      Description copied from class: `AbstractEndpoint`
      Create the SSLContextfor the the given SSLHostConfig.
      Specified by:
        `createSSLContext` in class `AbstractEndpoint<S>`
      Parameters:
        `sslHostConfig` - The SSLHostConfig for which the SSLContext should be created
      Throws:
        `IllegalArgumentException`

    - #### createSSLEngine

          protected SSLEngine createSSLEngine(String sniHostName,
                                  List<Cipher> clientRequestedCiphers,
                                  List<String> clientRequestedApplicationProtocols)

    - #### isAlpnSupported

          public boolean isAlpnSupported()

      Description copied from class: `AbstractEndpoint`
      Identifies if the endpoint supports ALPN. Note that a return value of `true` implies that `AbstractEndpoint.isSSLEnabled()` will also return `true`.
      Specified by:
        `isAlpnSupported` in class `AbstractEndpoint<S>`
      Returns:
        `true` if the endpoint supports ALPN in its current configuration, otherwise `false`.

    - #### init

          public void init()
                    throws Exception

      Overrides:
        `init` in class `AbstractEndpoint<S>`
      Throws:
        `Exception`

    - #### unbind

          public void unbind()
                      throws Exception

      Specified by:
        `unbind` in class `AbstractEndpoint<S>`
      Throws:
        `Exception`

    - #### getServerSocket

          protected abstract NetworkChannel getServerSocket()

    - #### getLocalAddress

          protected final InetSocketAddress getLocalAddress()
                                                     throws IOException

      Description copied from class: `AbstractEndpoint`
      Obtain the network address the server socket is bound to. This primarily exists to enable the correct address to be used when unlocking the server socket since it removes the guess-work involved if no address is specifically set.
      Specified by:
        `getLocalAddress` in class `AbstractEndpoint<S>`
      Returns:
        The network address that the server socket is listening on or null if the server socket is not currently bound.
      Throws:
        `IOException` - If there is a problem determining the currently bound socket

Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.