Class DefaultCertificateValidationResult

java.lang.Object
se.idsec.signservice.security.certificate.impl.DefaultCertificateValidationResult
All Implemented Interfaces:
CertificateValidationResult

public class DefaultCertificateValidationResult extends Object implements CertificateValidationResult
Default implementation of the SignatureValidationResult interface.
Author:
Martin Lindström (martin@idsec.se), Stefan Santesson (stefan@idsec.se)
  • Constructor Details

    • DefaultCertificateValidationResult

      public DefaultCertificateValidationResult(List<X509Certificate> validatedCertificatePath)
      Constructor assigning the validated certificate path.
      Parameters:
      validatedCertificatePath - the certificate path
  • Method Details

    • getValidatedCertificatePath

      public List<X509Certificate> getValidatedCertificatePath()
      Gets the certificate path that was used to validate the subject certificate.

      The certificate path starts with the subject certificate and ends with the trust anchor. Every certificate except the subject certificate must validate the certificate preceding it in the list.

      Specified by:
      getValidatedCertificatePath in interface CertificateValidationResult
      Returns:
      the certificate chain
    • getPKIXCertPathValidatorResult

      public PKIXCertPathValidatorResult getPKIXCertPathValidatorResult()
      Gets an optional path validation result.

      This result object is only relevant if the certificate validation function performed PKIX path validation from the target certificate to a trusted trust anchor certificate. If method returns null does not mean that certificate validation failed.

      Specified by:
      getPKIXCertPathValidatorResult in interface CertificateValidationResult
      Returns:
      a PKIXCertPathValidatorResult object or null if no path validation result is available
    • setPkixCertPathValidatorResult

      public void setPkixCertPathValidatorResult(PKIXCertPathValidatorResult pkixCertPathValidatorResult)
      Assigns the PKIX path validation result.
      Parameters:
      pkixCertPathValidatorResult - PKIX path validation result
    • toString

      public String toString()
      Overrides:
      toString in class Object