Class PKIXBuilderParameters

java.lang.Object
java.security.cert.PKIXParameters
java.security.cert.PKIXBuilderParameters
All Implemented Interfaces:
Cloneable, CertPathParameters

public class PKIXBuilderParameters
extends PKIXParameters
The parameter specification for a PKIX CertPathBuilder algorithm used to build certificate chains validated with the PKIX certification path validation.

The parameters must be created with trusted certificate authorities and constraints for the target certificates.

See Also:
CertPathBuilder, CertPathParameters
  • Constructor Details

  • Method Details

    • getMaxPathLength

      public int getMaxPathLength()
      Returns the maximum length of a certification path.

      This is the maximum number of non-self-signed certificates in a certification path.

      Returns:
      the maximum length of a certification path, or -1 if it is unlimited.
    • setMaxPathLength

      public void setMaxPathLength​(int maxPathLength)
      Set the maximum length of a certification path.

      This is the maximum number of non-self-signed certificates in a certification path.

      Parameters:
      maxPathLength - the maximum length of a certification path.
      Throws:
      InvalidParameterException - if maxPathLength is less than -1.
    • toString

      public String toString()
      Returns a string representation of this PKIXBuilderParameters instance.
      Overrides:
      toString in class PKIXParameters
      Returns:
      a string representation of this PKIXBuilderParameters instance.