com.verisign.epp.transport.client

## Class EPPSSLConfig

- java.lang.Object
- - com.verisign.epp.transport.client.EPPSSLConfig

-     public class EPPSSLConfig
      extends java.lang.Object

  The `EPPSSLConfig` class contains SSL configuration properties that can be used in conjunction with `EPPSSLImpl.initialize(EPPSSLConfig)` to initialize an `EPPSSLContext`. The required properties include:
  1. `sslProtocol` that defines the SSL protocol to use. For example, "TLS".
  2. `identityStoreType` that defines the type of the identity KeyStore. For example, "JKS".
  3. `identityFileName` that defines the name of the identity KeyStore file. For example, "identity.jks".
  4. `identityPassPhrase` that defines the passphrase/password to access the identity KeyStore file defined by the `identityFileName` property.
  The optional properties include:
  1. `identityKeyPassPhrase` that defines the passphrase/password for the private key stored in the identity KeyStore. If not defined, the value of the `identityPassPhrase` will be used.
  2. `trustStoreType` that defines the KeyStore type of the Trust Store. This is only required if the Trust Store is defined by the `trustStoreFileName` property. For example, "JKS".
  3. `trustStoreFileName` that defines the name of the Trust Store file. For example, "trust.jks". If note defined, the default JDK Trust Store will be used that is located at the path `$JAVA_HOME/lib/security/cacerts`.
  4. `trustStorePassPhrase` that defines the passphrase/password to access the identity KeyStore file defined by the `trustStoreFileName` property. This is only required if the Trust Store is defined by the `trustStoreFileName` property.
  5. `sslDebug` that defines that value of the SSL debug Java system property `javax.net.debug`. If not set, than the `javax.net.debug` system property will not set. The possible values include "none" and "all" and since it sets a Java system property it will global apply across all SSL connections om the Java process.
  6. `sslEnabledProtocols` that defines the support SSL protocols supported. If not defined, the default protocols provided by the JSSE provider will be used. For example, {"TLSv1", "SSLv3"}.
  7. `sslEnabledCipherSuites` that defines the support SSL cipher suites supported. If not defined, the default cipher suites provided by the JSSE provider will be used. For example, `SSL_RSA_WITH_RC4_128_MD5 SSL_RSA_WITH_RC4_128_SHA`.
  See Also:
    `EPPSSLImpl`, `EPPSSLContext`

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `EPPSSLConfig()` Default constructor.
    `EPPSSLConfig(java.lang.String aSslProtocol, java.lang.String aIdentityStoreType, java.lang.String aIdentityFileName, java.lang.String aIdentityPassPhrase)` Creates an instance of `EPPSSLConfig` that takes the required set of attributes.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `getIdentityFileName()` Gets the Identity File Name `String`.
    `java.lang.String` | `getIdentityKeyPassPhrase()` Gets the Identity Key Pass Phrase `String` using the Identity Pass Phrase as the default value.
    `char[]` | `getIdentityKeyPassPhraseCharArray()` Gets the Identity Key Pass Phrase as `char[]` using the Identity Pass Phrase as the default value.
    `java.lang.String` | `getIdentityPassPhrase()` Gets the Identity Pass Phrase `String`.
    `char[]` | `getIdentityPassPhraseCharArray()` Gets the Identity Pass Phrase as a `char[]`.
    `java.lang.String` | `getIdentityStoreType()` Gets the Identity Store Type `String`.
    `java.lang.String` | `getSslDebug()` Gets the SSL Debug `String`.
    `java.lang.String[]` | `getSSLEnabledCipherSuites()` Gets the optional SSL enabled cipher suites `String` array.
    `java.lang.String[]` | `getSSLEnabledProtocols()` Gets the optional SSL enabled protocols `String` array.
    `java.lang.String` | `getSslProtocol()` Gets the SSL Protocol `String`.
    `java.lang.String` | `getTrustStoreFileName()` Gets the Trust Store File Name `String`.
    `java.lang.String` | `getTrustStorePassPhrase()` Gets the Trust Store Pass Phrase `String`.
    `char[]` | `getTrustStorePassPhraseCharArray()` Gets the Trust Store Pass Phrase as `char[]`.
    `java.lang.String` | `getTrustStoreType()` Gets the Trust Store Type `String`.
    `void` | `setIdentityFileName(java.lang.String aIdentityFileName)` Sets the Identity File Name `String`.
    `void` | `setIdentityKeyPassPhrase(java.lang.String aIdentityKeyPassPhrase)` Sets the Identity Key Pass Phrase `String`.
    `void` | `setIdentityPassPhrase(java.lang.String aIdentityPassPhrase)` Sets the Identity Pass Phrase `String`.
    `void` | `setIdentityStoreType(java.lang.String aIdentityStoreType)` Sets the Identity Store Type `String`.
    `void` | `setSslDebug(java.lang.String aSslDebug)` Sets the SSL Debug `String`.
    `void` | `setSSLEnabledCipherSuites(java.lang.String aSslEnabledCipherSuites)` Sets the optional SSL enabled cipher suites using a space delimited list of cipher suites.
    `void` | `setSSLEnabledCipherSuites(java.lang.String[] aSslEnabledCipherSuites)` Sets the optional SSL enabled cipher suites `String` array.
    `void` | `setSSLEnabledProtocols(java.lang.String aSslEnabledProtocols)` Sets the optional SSL enabled protocols using a space delimited list of protocols.
    `void` | `setSSLEnabledProtocols(java.lang.String[] aSslEnabledProtocols)` Sets the optional SSL enabled protocols `String` array.
    `void` | `setSslProtocol(java.lang.String aSslProtocol)` Sets the SSL Protocol `String`.
    `void` | `setTrustStore(java.lang.String aTrustStoreType, java.lang.String aTrustStoreFileName, java.lang.String aTrustStorePassPhrase)` Sets the required Trust Store properties if the Trust Store is explicitely set.
    `void` | `setTrustStoreFileName(java.lang.String aTrustStoreFileName)` Sets the Trust Store File Name `String`.
    `void` | `setTrustStorePassPhrase(java.lang.String aTrustStorePassPhrase)` Sets the Trust Store Pass Phrase `String`.
    `void` | `setTrustStoreType(java.lang.String aTrustStoreType)` Sets the Trust Store Type `String`.
    `java.lang.String` | `toString()` Output the contents of the `EPPSSLConfig` instance which includes a comma seperated list of `EPPSSLConfig` properties with the values.
    `void` | `validate()` Validates the properties of the `EPPSSLConfig` by checking that the required properties are set.

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

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

- - ### Constructor Detail

    - #### EPPSSLConfig

          public EPPSSLConfig()

      Default constructor.

    - #### EPPSSLConfig

          public EPPSSLConfig(java.lang.String aSslProtocol,
                              java.lang.String aIdentityStoreType,
                              java.lang.String aIdentityFileName,
                              java.lang.String aIdentityPassPhrase)

      Creates an instance of `EPPSSLConfig` that takes the required set of attributes.
      Parameters:
        `aSslProtocol` - SSL Protocol like "TLS"
        `aIdentityStoreType` - Identity store type like "JKS"
        `aIdentityFileName` - Identity store file name
        `aIdentityPassPhrase` - Identity store passphrase/password

  - ### Method Detail

    - #### getIdentityFileName

          public java.lang.String getIdentityFileName()

      Gets the Identity File Name `String`.
      Returns:
        `String` if set; `null` otherwise.

    - #### setIdentityFileName

          public void setIdentityFileName(java.lang.String aIdentityFileName)

      Sets the Identity File Name `String`.
      Parameters:
        `aIdentityFileName` - `String`.

    - #### getIdentityKeyPassPhrase

          public java.lang.String getIdentityKeyPassPhrase()

      Gets the Identity Key Pass Phrase `String` using the Identity Pass Phrase as the default value.
      Returns:
        Identity Key Pass Phrase if set; otherwise the Identity Pass Phrase

    - #### getIdentityKeyPassPhraseCharArray

          public char[] getIdentityKeyPassPhraseCharArray()

      Gets the Identity Key Pass Phrase as `char[]` using the Identity Pass Phrase as the default value.
      Returns:
        Identity Key Pass Phrase if set; otherwise the Identity Pass Phrase as `char[]`

    - #### setIdentityKeyPassPhrase

          public void setIdentityKeyPassPhrase(java.lang.String aIdentityKeyPassPhrase)

      Sets the Identity Key Pass Phrase `String`.
      Parameters:
        `aIdentityKeyPassPhrase` - `String`.

    - #### getIdentityPassPhrase

          public java.lang.String getIdentityPassPhrase()

      Gets the Identity Pass Phrase `String`.
      Returns:
        Identity Pass Phrase if set; `null` otherwise.

    - #### getIdentityPassPhraseCharArray

          public char[] getIdentityPassPhraseCharArray()

      Gets the Identity Pass Phrase as a `char[]`.
      Returns:
        Identity Pass Phrase if set; `null` otherwise.

    - #### setIdentityPassPhrase

          public void setIdentityPassPhrase(java.lang.String aIdentityPassPhrase)

      Sets the Identity Pass Phrase `String`.
      Parameters:
        `aIdentityPassPhrase` - `String`.

    - #### getIdentityStoreType

          public java.lang.String getIdentityStoreType()

      Gets the Identity Store Type `String`.
      Returns:
        `String` if set; `null` otherwise.

    - #### setIdentityStoreType

          public void setIdentityStoreType(java.lang.String aIdentityStoreType)

      Sets the Identity Store Type `String`.
      Parameters:
        `aIdentityStoreType` - `String`.

    - #### getSslDebug

          public java.lang.String getSslDebug()

      Gets the SSL Debug `String`.
      Returns:
        `String` if set; `null` otherwise.

    - #### setSslDebug

          public void setSslDebug(java.lang.String aSslDebug)

      Sets the SSL Debug `String`.
      Parameters:
        `aSslDebug` - `String`.

    - #### getSslProtocol

          public java.lang.String getSslProtocol()

      Gets the SSL Protocol `String`.
      Returns:
        `String` if set; `null` otherwise.

    - #### setSslProtocol

          public void setSslProtocol(java.lang.String aSslProtocol)

      Sets the SSL Protocol `String`.
      Parameters:
        `aSslProtocol` - `String`.

    - #### setTrustStore

          public void setTrustStore(java.lang.String aTrustStoreType,
                                    java.lang.String aTrustStoreFileName,
                                    java.lang.String aTrustStorePassPhrase)

      Sets the required Trust Store properties if the Trust Store is explicitely set.
      Parameters:
        `aTrustStoreType` - Keystore type of the Trust Store like "JKS"
        `aTrustStoreFileName` - Trust Store file name
        `aTrustStorePassPhrase` - Trust Store passphrase/password

    - #### getTrustStoreType

          public java.lang.String getTrustStoreType()

      Gets the Trust Store Type `String`.
      Returns:
        `String` if set; `null` otherwise.

    - #### setTrustStoreType

          public void setTrustStoreType(java.lang.String aTrustStoreType)

      Sets the Trust Store Type `String`.
      Parameters:
        `aTrustStoreType` - `String`.

    - #### getTrustStoreFileName

          public java.lang.String getTrustStoreFileName()

      Gets the Trust Store File Name `String`.
      Returns:
        `String` if set; `null` otherwise.

    - #### setTrustStoreFileName

          public void setTrustStoreFileName(java.lang.String aTrustStoreFileName)

      Sets the Trust Store File Name `String`.
      Parameters:
        `aTrustStoreFileName` - `String`.

    - #### getTrustStorePassPhrase

          public java.lang.String getTrustStorePassPhrase()

      Gets the Trust Store Pass Phrase `String`.
      Returns:
        Trust Store Pass Phrase if set; `null` otherwise.

    - #### getTrustStorePassPhraseCharArray

          public char[] getTrustStorePassPhraseCharArray()

      Gets the Trust Store Pass Phrase as `char[]`.
      Returns:
        Trust Store Pass Phrase if set; `null` otherwise.

    - #### setTrustStorePassPhrase

          public void setTrustStorePassPhrase(java.lang.String aTrustStorePassPhrase)

      Sets the Trust Store Pass Phrase `String`.
      Parameters:
        `aTrustStorePassPhrase` - `String`.

    - #### getSSLEnabledProtocols

          public java.lang.String[] getSSLEnabledProtocols()

      Gets the optional SSL enabled protocols `String` array.
      Returns:
        `String` array if set; `null` otherwise.

    - #### setSSLEnabledProtocols

          public void setSSLEnabledProtocols(java.lang.String[] aSslEnabledProtocols)

      Sets the optional SSL enabled protocols `String` array.
      Parameters:
        `aSslEnabledProtocols` - `String` array of enabled SSL protocols

    - #### setSSLEnabledProtocols

          public void setSSLEnabledProtocols(java.lang.String aSslEnabledProtocols)

      Sets the optional SSL enabled protocols using a space delimited list of protocols.
      Parameters:
        `aSslEnabledProtocols` - space delimited list of enabled SSL protocols

    - #### getSSLEnabledCipherSuites

          public java.lang.String[] getSSLEnabledCipherSuites()

      Gets the optional SSL enabled cipher suites `String` array.
      Returns:
        `>String` array if set; `null` otherwise.

    - #### setSSLEnabledCipherSuites

          public void setSSLEnabledCipherSuites(java.lang.String[] aSslEnabledCipherSuites)

      Sets the optional SSL enabled cipher suites `String` array.
      Parameters:
        `aSslEnabledCipherSuites` - `String` array of enabled SSL cipher suites

    - #### setSSLEnabledCipherSuites

          public void setSSLEnabledCipherSuites(java.lang.String aSslEnabledCipherSuites)

      Sets the optional SSL enabled cipher suites using a space delimited list of cipher suites.
      Parameters:
        `aSslEnabledCipherSuites` - space delimited list of enabled SSL cipher suites

    - #### validate

          public void validate()
                        throws EPPException

      Validates the properties of the `EPPSSLConfig` by checking that the required properties are set.
      Throws:
        `EPPException` - On error

    - #### toString

          public java.lang.String toString()

      Output the contents of the `EPPSSLConfig` instance which includes a comma seperated list of `EPPSSLConfig` properties with the values. For example, "sslProtocol = <value>".
      Overrides:
        `toString` in class `java.lang.Object`
      Returns:
        `String` containing the `EPPSSLConfig` properties and values