Package javax.net.ssl

Interface X509TrustManager

  • All Superinterfaces:
    TrustManager
    All Known Implementing Classes:
    TrustManagerImpl

    public interface X509TrustManager
    extends TrustManager
    The trust manager for X509 certificates to be used to perform authentication for secure sockets.
    • Method Detail

      • checkClientTrusted

        void checkClientTrusted​(X509Certificate[] chain,
                                String authType)
                         throws CertificateException
        Checks whether the specified certificate chain (partial or complete) can be validated and is trusted for client authentication for the specified authentication type.
        Parameters:
        chain - the certificate chain to validate.
        authType - the authentication type used.
        Throws:
        CertificateException - if the certificate chain can't be validated or isn't trusted.
        IllegalArgumentException - if the specified certificate chain is empty or null, or if the specified authentication type is null or an empty string.
      • checkServerTrusted

        void checkServerTrusted​(X509Certificate[] chain,
                                String authType)
                         throws CertificateException
        Checks whether the specified certificate chain (partial or complete) can be validated and is trusted for server authentication for the specified key exchange algorithm.
        Parameters:
        chain - the certificate chain to validate.
        authType - the key exchange algorithm name.
        Throws:
        CertificateException - if the certificate chain can't be validated or isn't trusted.
        IllegalArgumentException - if the specified certificate chain is empty or null, or if the specified authentication type is null or an empty string.
      • getAcceptedIssuers

        X509Certificate[] getAcceptedIssuers()
        Returns the list of certificate issuer authorities which are trusted for authentication of peers.
        Returns:
        the list of certificate issuer authorities which are trusted for authentication of peers.