Class X509CredentialConfig

  • All Implemented Interfaces:
    CredentialConfig

    public class X509CredentialConfig
    extends java.lang.Object
    implements CredentialConfig
    Provides the properties necessary for creating an SSL context initializer with an X.509 credential reader.
    Author:
    Middleware Services
    • Constructor Detail

      • X509CredentialConfig

        public X509CredentialConfig()
    • Method Detail

      • getTrustCertificates

        public java.lang.String getTrustCertificates()
        Returns the name of the trust certificates to use.
        Returns:
        trust certificates name
      • setTrustCertificates

        public void setTrustCertificates​(java.lang.String name)
        Sets the name of the trust certificates to use.
        Parameters:
        name - trust certificates name
      • getAuthenticationCertificate

        public java.lang.String getAuthenticationCertificate()
        Returns the name of the authentication certificate to use.
        Returns:
        authentication certificate name
      • setAuthenticationCertificate

        public void setAuthenticationCertificate​(java.lang.String name)
        Sets the name of the authentication certificate to use.
        Parameters:
        name - authentication certificate name
      • getAuthenticationKey

        public java.lang.String getAuthenticationKey()
        Returns the name of the authentication key to use.
        Returns:
        authentication key name
      • setAuthenticationKey

        public void setAuthenticationKey​(java.lang.String name)
        Sets the name of the authentication key to use.
        Parameters:
        name - authentication key name
      • createSSLContextInitializer

        public SSLContextInitializer createSSLContextInitializer()
                                                          throws java.security.GeneralSecurityException
        Description copied from interface: CredentialConfig
        Creates an SSL context initializer using the configured trust and authentication material in this config.
        Specified by:
        createSSLContextInitializer in interface CredentialConfig
        Returns:
        SSL context initializer
        Throws:
        java.security.GeneralSecurityException - if the ssl context initializer cannot be created
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object