|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectice.cert.X509CertificateFactory
This class defines the functionality of a certificate factory, which is used to generate certificate objects from their encodings.
This implementation is compliant to the specifications given in
jdk1.2's java.security.cert.X509Certificate. However
few differences can be noticed:
generateCertificates() does not return a Collection
but an array of certificates
X509Certificate| Constructor Summary | |
X509CertificateFactory()
|
|
| Method Summary | |
X509Certificate |
generateCertificate(InputStream inStream)
Generates a certificate object and initializes it with the data read from the input stream inStream. |
X509Certificate[] |
generateCertificates(InputStream inStream)
Returns a (possibly empty) collection view of the certificates read from the given input stream inStream. |
Provider |
getProvider()
Returns the provider of this certificate factory. |
String |
getType()
Returns the name of the certificate type associated with this certificate factory. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public X509CertificateFactory()
| Method Detail |
public X509Certificate generateCertificate(InputStream inStream)
throws CertificateException
inStream.
The given input stream inStream must contain a single
X509 certificate. The
certificate provided in inStream must be DER-encoded and
may be supplied in binary or printable (Base64) encoding.
Note that this method will consume the entire input stream.
inStream - an input stream with the certificate data.
CertificateException - on parsing errors.
public X509Certificate[] generateCertificates(InputStream inStream)
throws CertificateException
inStream.
The given input stream See netscape site
for a description of the netscape certificate chain format, and
RSA Security site
for the PKCS#7 format.
Note that this method will
consume the entire input stream.
inStream must contain a
sequence of DER-encoded certificates in the formats described for
generateCertificate and
may be supplied in binary or printable (Base64) encoding.
In addition, inStream may contain a PKCS#7 certificate
chain or a Netscape certificate chain. These formats allow multiple
certificates to be downloaded at once.
If no certificates are present,
an empty collection is returned.
In the case of base64 encoding, the whole chain must be encoded
in one base64 sequence. If the stream contains several base64 encoded
objects (i.e. several "-----BEGIN XXX----- ... -----END XXX-----")
only the first one is read.
inStream - the input stream with the certificates.
CertificateException - on parsing errors.
public Provider getProvider()
public String getType()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||