A CertPathValidatorException
provides support for wrapping
exceptions. The getCause
method returns the throwable,
if any, that caused this exception to be thrown.
A CertPathValidatorException
may also include the
certification path that was being validated when the exception was thrown,
the index of the certificate in the certification path that caused the
exception to be thrown, and the reason that caused the failure. Use the
getCertPath
, getIndex
, and
getReason
methods to retrieve this information.
Concurrent Access
Unless otherwise specified, the methods defined in this class are not thread-safe. Multiple threads that need to access a single object concurrently should synchronize amongst themselves and provide the necessary locking. Multiple threads each manipulating separate objects need not synchronize.
CertPathValidator
Modifier and Type | Class and Description |
---|---|
public static enum | CertPathValidatorException.
The BasicReason enumerates the potential reasons that a certification path of any type may be invalid. |
public static interface | CertPathValidatorException.
The reason the validation algorithm failed. |
Modifier and Type | Field and Description |
---|---|
private final CertPath | |
private int | |
private CertPathValidatorException. | |
private static final long |
Access | Constructor and Description |
---|---|
public | |
public | CertPathValidatorException(String
the detail message msg)Creates a |
public | CertPathValidatorException(Throwable
the cause (which is saved for later retrieval by the
cause)getCause() method). (A null value is
permitted, and indicates that the cause is nonexistent or unknown.)Creates a |
public | CertPathValidatorException(String
the detail message msg, Throwable the cause (which is saved for later retrieval by the
cause)getCause() method). (A null value is
permitted, and indicates that the cause is nonexistent or unknown.)Creates a |
public | CertPathValidatorException(String
the detail message (or msg, Throwable null if none)the cause (or cause, CertPath null if none)the certification path that was in the process of
being validated when the error was encountered certPath, int the index of the certificate in the certification path
that caused the error (or -1 if not applicable). Note that
the list of certificates in a index)CertPath is zero based.Creates a |
public | CertPathValidatorException(String
the detail message (or msg, Throwable null if none)the cause (or cause, CertPath null if none)the certification path that was in the process of
being validated when the error was encountered certPath, int the index of the certificate in the certification path
that caused the error (or -1 if not applicable). Note that
the list of certificates in a index, CertPathValidatorException.CertPath is zero based.the reason the validation failed reasonCreates a |
Modifier and Type | Method and Description |
---|---|
public CertPath | Returns: theCertPath that was being validated when
the exception was thrown (or null if not specified)Returns the certification path that was being validated when the exception was thrown. |
public int | Returns: the index that has been set, or -1 if none has been setReturns the index of the certificate in the certification path that caused the exception to be thrown. |
public CertPathValidatorException. | Returns: the reason that the validation failed, orBasicReason.UNSPECIFIED if a reason has not been
specifiedReturns the reason that the validation failed. |
private void | readObject(ObjectInputStream
the stream)ObjectInputStream from which data is readHides java. Restores the state of this object from the stream. |
certPath | back to summary |
---|---|
private final CertPath certPath |
index | back to summary |
---|---|
private int index |
reason | back to summary |
---|---|
private CertPathValidatorException. |
serialVersionUID | back to summary |
---|---|
private static final long serialVersionUID Hides java. |
CertPathValidatorException | back to summary |
---|---|
public CertPathValidatorException() Creates a |
CertPathValidatorException | back to summary |
---|---|
public CertPathValidatorException(String msg) Creates a
|
CertPathValidatorException | back to summary |
---|---|
public CertPathValidatorException(Throwable cause) Creates a
|
CertPathValidatorException | back to summary |
---|---|
public CertPathValidatorException(String msg, Throwable cause) Creates a
|
CertPathValidatorException | back to summary |
---|---|
public CertPathValidatorException(String msg, Throwable cause, CertPath certPath, int index) Creates a
|
CertPathValidatorException | back to summary |
---|---|
public CertPathValidatorException(String msg, Throwable cause, CertPath certPath, int index, CertPathValidatorException. Creates a
|
getCertPath | back to summary |
---|---|
public CertPath getCertPath() Returns the certification path that was being validated when the exception was thrown.
|
getIndex | back to summary |
---|---|
public int getIndex() Returns the index of the certificate in the certification path
that caused the exception to be thrown. Note that the list of
certificates in a
|
getReason | back to summary |
---|---|
public CertPathValidatorException. Returns the reason that the validation failed. The reason is
associated with the index of the certificate returned by
|
readObject | back to summary |
---|---|
private void readObject(ObjectInputStream stream) throws ClassNotFoundException, IOException Hides java. Restores the state of this object from the stream.
|
Modifier and Type | Field and Description |
---|---|
public static final CertPathValidatorException. | ALGORITHM_CONSTRAINED
The public key or the signature algorithm has been constrained. |
public static final CertPathValidatorException. | EXPIRED
The certificate is expired. |
public static final CertPathValidatorException. | INVALID_SIGNATURE
The signature is invalid. |
public static final CertPathValidatorException. | NOT_YET_VALID
The certificate is not yet valid. |
public static final CertPathValidatorException. | REVOKED
The certificate is revoked. |
public static final CertPathValidatorException. | UNDETERMINED_REVOCATION_STATUS
The revocation status of the certificate could not be determined. |
public static final CertPathValidatorException. | UNSPECIFIED
Unspecified reason. |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public static CertPathValidatorException. | |
public static CertPathValidatorException. |
ALGORITHM_CONSTRAINED | back to summary |
---|---|
public static final CertPathValidatorException. The public key or the signature algorithm has been constrained. |
EXPIRED | back to summary |
---|---|
public static final CertPathValidatorException. The certificate is expired. |
INVALID_SIGNATURE | back to summary |
---|---|
public static final CertPathValidatorException. The signature is invalid. |
NOT_YET_VALID | back to summary |
---|---|
public static final CertPathValidatorException. The certificate is not yet valid. |
REVOKED | back to summary |
---|---|
public static final CertPathValidatorException. The certificate is revoked. |
UNDETERMINED_REVOCATION_STATUS | back to summary |
---|---|
public static final CertPathValidatorException. The revocation status of the certificate could not be determined. |
UNSPECIFIED | back to summary |
---|---|
public static final CertPathValidatorException. Unspecified reason. |
BasicReason | back to summary |
---|---|
private BasicReason() |
valueOf | back to summary |
---|---|
public static CertPathValidatorException. |
values | back to summary |
---|---|
public static CertPathValidatorException. |