public class CertPath extends java.lang.Object implements IXMLEncodable
Modifier and Type | Field and Description |
---|---|
static int |
ERROR_BASIC_CONSTRAINTS_IS_CA |
static int |
ERROR_BASIC_CONSTRAINTS_IS_NO_CA |
static int |
ERROR_BASIC_CONSTRAINTS_PATH_TOO_LONG |
static int |
ERROR_KEY_USAGE |
static int |
ERROR_REVOCATION |
static int |
ERROR_UNKNOWN_CRITICAL_EXTENSION |
static int |
ERROR_VALIDITY |
static int |
ERROR_VALIDITY_SEVERE |
static int |
ERROR_VERIFICATION |
static int |
NO_ERRORS |
static java.lang.String |
XML_ATTR_CLASS |
static java.lang.String |
XML_ATTR_TYPE |
static java.lang.String |
XML_ELEMENT_NAME |
FIELD_XML_ELEMENT_CONTAINER_NAME, FIELD_XML_ELEMENT_NAME, XML_ATTR_ID, XML_ATTR_LANGUAGE, XML_ATTR_VERSION
Modifier and Type | Method and Description |
---|---|
boolean |
checkValidity(java.util.Date a_date)
Checks the validity of all certificates in the path.
|
int |
getErrorCode() |
int |
getErrorPosition() |
JAPCertificate |
getFirstCertificate()
Returns the certificate from the lowest Level of this CertPath (the one
that was added at first).
|
static CertPath |
getInstance(JAPCertificate a_firstCert,
int a_documentType,
java.util.Vector a_pathCertificates) |
JAPCertificate |
getLastCertificate()
Returns the top level certificate (it is the one that was last added)
|
CertPathInfo |
getPathInfo() |
static CertPath |
getRootInstance(JAPCertificate a_rootCert) |
JAPCertificate |
getSecondCertificate()
Returns the certificate from the second lowest Level of this CertPath
(the one that was added at Second).
|
boolean |
isValidPath() |
int |
length()
Returns the number of certificates in this CertPath
|
java.lang.String |
toString()
Creates a human readable List in String-Format using the CommonNames of
the included certs.
|
org.w3c.dom.Element |
toXmlElement(org.w3c.dom.Document a_doc)
Return an element that can be appended to the document.
|
boolean |
verify()
Tries to verify the top level certificate in this CertPath against the root certificates.
|
public static final java.lang.String XML_ELEMENT_NAME
public static final java.lang.String XML_ATTR_CLASS
public static final java.lang.String XML_ATTR_TYPE
public static final int NO_ERRORS
public static final int ERROR_VERIFICATION
public static final int ERROR_VALIDITY
public static final int ERROR_REVOCATION
public static final int ERROR_UNKNOWN_CRITICAL_EXTENSION
public static final int ERROR_BASIC_CONSTRAINTS_IS_CA
public static final int ERROR_BASIC_CONSTRAINTS_IS_NO_CA
public static final int ERROR_BASIC_CONSTRAINTS_PATH_TOO_LONG
public static final int ERROR_KEY_USAGE
public static final int ERROR_VALIDITY_SEVERE
public static CertPath getRootInstance(JAPCertificate a_rootCert)
public static CertPath getInstance(JAPCertificate a_firstCert, int a_documentType, java.util.Vector a_pathCertificates)
a_firstCert
- a_documentType
- a_pathCertificates
- public org.w3c.dom.Element toXmlElement(org.w3c.dom.Document a_doc)
IXMLEncodable
toXmlElement
in interface IXMLEncodable
a_doc
- a documentpublic JAPCertificate getLastCertificate()
public JAPCertificate getFirstCertificate()
public JAPCertificate getSecondCertificate()
public boolean checkValidity(java.util.Date a_date)
a_date
- the date for which the validity of the path is testedpublic boolean verify()
public int length()
public java.lang.String toString()
toString
in class java.lang.Object
public CertPathInfo getPathInfo()
public boolean isValidPath()
public int getErrorCode()
public int getErrorPosition()
Copyright © 2023. All rights reserved.