java.lang.Object | |
↳ | sun.security.x509.X509CertInfo |
The X509CertInfo class represents X.509 certificate information.
X.509 certificates have several base data elements, including:
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
String | ALGORITHM_ID | ||||||||||
String | EXTENSIONS | ||||||||||
String | IDENT | Identifier for this attribute, to be used with the get, set, delete methods of Certificate, x509 type. | |||||||||
String | ISSUER | ||||||||||
String | ISSUER_ID | ||||||||||
String | KEY | ||||||||||
String | NAME | ||||||||||
String | SERIAL_NUMBER | ||||||||||
String | SUBJECT | ||||||||||
String | SUBJECT_ID | ||||||||||
String | VALIDITY | ||||||||||
String | VERSION |
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
algId | |||||||||||
extensions | |||||||||||
interval | |||||||||||
issuer | |||||||||||
issuerUniqueId | |||||||||||
pubKey | |||||||||||
serialNum | |||||||||||
subject | |||||||||||
subjectUniqueId | |||||||||||
version |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Construct an uninitialized X509CertInfo on which
decode must later be called (or which may be deserialized).
| |||||||||||
Unmarshals a certificate from its encoded form, parsing the
encoded bytes.
| |||||||||||
Unmarshal a certificate from its encoded form, parsing a DER value.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Delete the certificate attribute.
| |||||||||||
Appends the certificate to an output stream.
| |||||||||||
Compares two X509CertInfo objects.
| |||||||||||
Compares two certificates, returning false if any data
differs between the two.
| |||||||||||
Get the certificate attribute.
| |||||||||||
Return an enumeration of names of attributes existing within this
attribute.
| |||||||||||
Returns the encoded certificate info.
| |||||||||||
Return the name of this attribute.
| |||||||||||
Calculates a hash code value for the object.
| |||||||||||
Set the certificate attribute.
| |||||||||||
Returns a printable representation of the certificate.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() |
Identifier for this attribute, to be used with the get, set, delete methods of Certificate, x509 type.
Construct an uninitialized X509CertInfo on which decode must later be called (or which may be deserialized).
Unmarshals a certificate from its encoded form, parsing the encoded bytes. This form of constructor is used by agents which need to examine and use certificate contents. That is, this is one of the more commonly used constructors. Note that the buffer must include only a certificate, and no "garbage" may be left at the end. If you need to ignore data at the end of a certificate, use another constructor.
cert | the encoded bytes, with no trailing data. |
---|
CertificateParsingException | on parsing errors. |
---|
Unmarshal a certificate from its encoded form, parsing a DER value. This form of constructor is used by agents which need to examine and use certificate contents.
derVal | the der value containing the encoded cert. |
---|
CertificateParsingException | on parsing errors. |
---|
Delete the certificate attribute.
name | the name of the attribute to delete. |
---|
CertificateException | on invalid attributes. |
---|---|
IOException | on other errors. |
Appends the certificate to an output stream.
out | an output stream to which the certificate is appended. |
---|
CertificateException | on encoding errors. |
---|---|
IOException | on other errors. |
Compares two X509CertInfo objects. This is false if the certificates are not both X.509 certs, otherwise it compares them as binary data.
other | the object being compared with this one |
---|
Compares two certificates, returning false if any data differs between the two.
other | the object being compared with this one |
---|
Get the certificate attribute.
name | the name of the attribute to return. |
---|
CertificateException | on invalid attributes. |
---|---|
IOException | on other errors. |
Return an enumeration of names of attributes existing within this attribute.
Returns the encoded certificate info.
CertificateEncodingException | on encoding information errors. |
---|
Calculates a hash code value for the object. Objects which are equal will also have the same hashcode.
Set the certificate attribute.
name | the name of the attribute (e.g. "x509.info.key") |
---|---|
val | the attribute object. |
CertificateException | on invalid attributes. |
---|---|
IOException | on other errors. |
Returns a printable representation of the certificate.