Class Ssl

java.lang.Object
com.linecorp.armeria.spring.Ssl

public class Ssl extends Object
Simple server-independent abstraction for SSL configuration.
  • Constructor Details

    • Ssl

      public Ssl()
  • Method Details

    • isEnabled

      public boolean isEnabled()
      Returns whether to enable SSL support.
      Returns:
      whether to enable SSL support
    • setEnabled

      public Ssl setEnabled(boolean enabled)
      Enables (or disables) SSL support.
    • getProvider

      @Nullable public @Nullable io.netty.handler.ssl.SslProvider getProvider()
      Returns Netty SSL Provider.
      Returns:
      Netty SSL Provider
    • setProvider

      public void setProvider(io.netty.handler.ssl.SslProvider provider)
      Sets Netty SSL Provider namely JDK or OPENSSL SslProvider.
      Parameters:
      provider - Netty SSL Provider
    • getClientAuth

      @Nullable public @Nullable io.netty.handler.ssl.ClientAuth getClientAuth()
      Returns whether client authentication is not wanted ("none"), wanted ("want") or needed ("need"). Requires a trust store.
      Returns:
      the ClientAuth to use
    • setClientAuth

      public Ssl setClientAuth(io.netty.handler.ssl.ClientAuth clientAuth)
      Sets whether the client authentication is not none (ClientAuth.NONE), optional (ClientAuth.OPTIONAL) or required (ClientAuth.REQUIRE).
    • getCiphers

      @Nullable public @Nullable List<String> getCiphers()
      Returns the supported SSL ciphers.
      Returns:
      the supported SSL ciphers
    • setCiphers

      public Ssl setCiphers(List<String> ciphers)
      Sets the supported SSL ciphers.
    • getEnabledProtocols

      @Nullable public @Nullable List<String> getEnabledProtocols()
      Returns the enabled SSL protocols.
      Returns:
      the enabled SSL protocols.
    • setEnabledProtocols

      public Ssl setEnabledProtocols(List<String> enabledProtocols)
      Sets the enabled SSL protocols.
    • getKeyAlias

      @Nullable public @Nullable String getKeyAlias()
      Returns the alias that identifies the key in the key store.
      Returns:
      the key alias
    • setKeyAlias

      public Ssl setKeyAlias(String keyAlias)
      Sets the alias that identifies the key in the key store.
    • getKeyPassword

      @Nullable public @Nullable String getKeyPassword()
      Returns the password used to access the key in the key store.
      Returns:
      the key password
    • setKeyPassword

      public Ssl setKeyPassword(String keyPassword)
      Sets the password used to access the key in the key store.
    • getKeyStore

      @Nullable public @Nullable String getKeyStore()
      Returns the path to the key store that holds the SSL certificate (typically a jks file).
      Returns:
      the path to the key store
    • setKeyStore

      public Ssl setKeyStore(String keyStore)
      Sets the path to the key store that holds the SSL certificate (typically a jks file).
    • getKeyStorePassword

      @Nullable public @Nullable String getKeyStorePassword()
      Returns the password used to access the key store.
      Returns:
      the key store password
    • setKeyStorePassword

      public Ssl setKeyStorePassword(String keyStorePassword)
      Sets the password used to access the key store.
    • getKeyStoreType

      @Nullable public @Nullable String getKeyStoreType()
      Returns the type of the key store.
      Returns:
      the key store type
    • setKeyStoreType

      public Ssl setKeyStoreType(String keyStoreType)
      Sets the type of the key store.
    • getKeyStoreProvider

      @Nullable public @Nullable String getKeyStoreProvider()
      Returns the provider for the key store.
      Returns:
      the key store provider
    • setKeyStoreProvider

      public Ssl setKeyStoreProvider(String keyStoreProvider)
      Sets the provider for the key store.
    • getTrustStore

      @Nullable public @Nullable String getTrustStore()
      Returns the trust store that holds SSL certificates.
      Returns:
      the trust store
    • setTrustStore

      public Ssl setTrustStore(String trustStore)
      Sets the trust store that holds SSL certificates.
    • getTrustStorePassword

      @Nullable public @Nullable String getTrustStorePassword()
      Returns the password used to access the trust store.
      Returns:
      the trust store password
    • setTrustStorePassword

      public Ssl setTrustStorePassword(String trustStorePassword)
      Sets the password used to access the trust store.
    • getTrustStoreType

      @Nullable public @Nullable String getTrustStoreType()
      Returns the type of the trust store.
      Returns:
      the trust store type
    • setTrustStoreType

      public Ssl setTrustStoreType(String trustStoreType)
      Sets the type of the trust store.
    • getTrustStoreProvider

      @Nullable public @Nullable String getTrustStoreProvider()
      Returns the provider for the trust store.
      Returns:
      the trust store provider
    • setTrustStoreProvider

      public Ssl setTrustStoreProvider(String trustStoreProvider)
      Sets the provider for the trust store.