Class TLS

  • All Implemented Interfaces:
    Lifecycle

    public class TLS
    extends java.lang.Object
    implements Lifecycle
    Component to configure TLS in protocols (TCP and TUNNEL).
    Since:
    5.2.15
    Author:
    Bela Ban
    • Field Detail

      • enabled

        protected boolean enabled
      • protocols

        protected java.lang.String[] protocols
      • cipher_suites

        protected java.lang.String[] cipher_suites
      • provider

        protected java.lang.String provider
      • keystore_path

        protected java.lang.String keystore_path
      • keystore_password

        protected java.lang.String keystore_password
      • keystore_type

        protected java.lang.String keystore_type
      • keystore_alias

        protected java.lang.String keystore_alias
      • truststore_path

        protected java.lang.String truststore_path
      • truststore_password

        protected java.lang.String truststore_password
      • truststore_type

        protected java.lang.String truststore_type
      • ssl_context

        protected javax.net.ssl.SSLContext ssl_context
      • sni_matchers

        protected java.util.List<javax.net.ssl.SNIMatcher> sni_matchers
    • Constructor Detail

      • TLS

        public TLS()
    • Method Detail

      • enabled

        public boolean enabled()
      • enabled

        public TLS enabled​(boolean e)
      • getProtocols

        public java.lang.String[] getProtocols()
      • setProtocols

        public TLS setProtocols​(java.lang.String[] p)
      • getCipherSuites

        public java.lang.String[] getCipherSuites()
      • setCipherSuites

        public TLS setCipherSuites​(java.lang.String[] c)
      • getProvider

        public java.lang.String getProvider()
      • setProvider

        public TLS setProvider​(java.lang.String p)
      • getKeystorePath

        public java.lang.String getKeystorePath()
      • setKeystorePath

        public TLS setKeystorePath​(java.lang.String k)
      • getKeystorePassword

        public java.lang.String getKeystorePassword()
      • setKeystorePassword

        public TLS setKeystorePassword​(java.lang.String k)
      • getKeystoreType

        public java.lang.String getKeystoreType()
      • setKeystoreType

        public TLS setKeystoreType​(java.lang.String k)
      • getKeystoreAlias

        public java.lang.String getKeystoreAlias()
      • setKeystoreAlias

        public TLS setKeystoreAlias​(java.lang.String k)
      • getTruststorePath

        public java.lang.String getTruststorePath()
      • setTruststorePath

        public TLS setTruststorePath​(java.lang.String t)
      • getTruststorePassword

        public java.lang.String getTruststorePassword()
      • setTruststorePassword

        public TLS setTruststorePassword​(java.lang.String t)
      • getTruststoreType

        public java.lang.String getTruststoreType()
      • setTruststoreType

        public TLS setTruststoreType​(java.lang.String t)
      • getSSLContext

        public javax.net.ssl.SSLContext getSSLContext()
      • setSSLContext

        public TLS setSSLContext​(javax.net.ssl.SSLContext c)
      • getSniMatchers

        public java.util.List<javax.net.ssl.SNIMatcher> getSniMatchers()
      • setSniMatchers

        public TLS setSniMatchers​(java.util.List<javax.net.ssl.SNIMatcher> s)
      • setWatcher

        public void setWatcher​(FileWatcher watcher)
      • init

        public void init()
                  throws java.lang.Exception
        Description copied from interface: Lifecycle
        Called after an instance has been created and before it is started.
        Specified by:
        init in interface Lifecycle
        Throws:
        java.lang.Exception - Thrown if the instance cannot be initialized successfully.
      • createContext

        public javax.net.ssl.SSLContext createContext()
      • createSocketFactory

        public SocketFactory createSocketFactory()
      • createSocketFactory

        public SocketFactory createSocketFactory​(javax.net.ssl.SSLContext context)