java.lang.Object | |
↳ | javax.security.cert.Certificate |
Known Direct Subclasses |
Abstract class to represent identity certificates. It represents a way to verify the binding of a Principal and its public key. Examples are X.509, PGP, and SDSI.
Note: This package is provided only for compatibility reasons. It contains a simplified version of the java.security.cert package that was previously used by JSSE (Java SSL package). All applications that do not have to be compatible with older versions of JSSE (that is before Java SDK 1.5) should only use java.security.cert.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates a new
Certificate . |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Compares the argument to this Certificate.
| |||||||||||
Returns the encoded representation for this certificate.
| |||||||||||
Returns the public key corresponding to this certificate.
| |||||||||||
Returns an integer hash code for the receiver.
| |||||||||||
Returns a string containing a concise, human-readable description of the
receiver.
| |||||||||||
Verifies that this certificate was signed with the given public key.
| |||||||||||
Verifies that this certificate was signed with the given public key.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class java.lang.Object
|
Creates a new Certificate
.
Compares the argument to this Certificate. If both have the same bytes they are assumed to be equal.
obj | the Certificate to compare with this object |
---|
true
if obj
is the same as this
Certificate
, false
otherwiseReturns the encoded representation for this certificate.
CertificateEncodingException | if encoding fails. |
---|
Returns the public key corresponding to this certificate.
Returns an integer hash code for the receiver. Any two objects which
return true
when passed to equals
must answer
the same value for this method.
Returns a string containing a concise, human-readable description of the receiver.
Verifies that this certificate was signed with the given public key. Uses the signature algorithm given by the provider.
key | public key for which verification should be performed. |
---|---|
sigProvider | the name of the signature provider. |
CertificateException | if encoding errors are detected |
---|---|
NoSuchAlgorithmException | if an unsupported algorithm is detected |
InvalidKeyException | if an invalid key is detected |
NoSuchProviderException | if the specified provider does not exists. |
SignatureException | if signature errors are detected |
Verifies that this certificate was signed with the given public key.
key | public key for which verification should be performed. |
---|
CertificateException | if encoding errors are detected |
---|---|
NoSuchAlgorithmException | if an unsupported algorithm is detected |
InvalidKeyException | if an invalid key is detected |
NoSuchProviderException | if there is no default provider |
SignatureException | if signature errors are detected |