iaik.x509
Class CertificateFactory

java.lang.Object
  |
  +--java.security.cert.CertificateFactorySpi
        |
        +--iaik.x509.CertificateFactory
Direct Known Subclasses:
QualifiedCertificateFactory

public class CertificateFactory
extends CertificateFactorySpi

This class implements a CertificateFactory for X.509.

Certificate Factories are used for reading encoded certificates and Certificate Recovation Lists (CRLs) from input streams.

For instantiating the IAIK certificate factory call the getInstance factory method of the java.security.cert.CertificateFactory engine class, thereby supplying the certificate type ("X.509") and the name of the IAIK provider:

 CertifiacteFactory certFactory =
		CertificateFactory.getInstance("X.509", "IAIK");
 
Subsequently use the generateCertificate, generateCertificates, generateCRL, or generateCRLs method for pasrsing a X.509 certificate, a collection of X.509 certificates, a X.509 CRL, or a collection of X.509 CRLs, respectively, e.g.:
 Collection c = certFactory.generateCertificates(is);
 

Version:
File Revision 14
See Also:
X509Certificate, X509CRL

Constructor Summary
CertificateFactory()
           
 
Method Summary
 Certificate engineGenerateCertificate(InputStream is)
          Parses a X.509 certificate from the supplied input stream.
 Collection engineGenerateCertificates(InputStream is)
          Parses a collection of X.509 certificates from the supplied input stream.
 CRL engineGenerateCRL(InputStream is)
          Parses a X.509 CRL from the supplied input stream.
 Collection engineGenerateCRLs(InputStream is)
          Parses a collection of X.509 CRLs from the supplied input stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CertificateFactory

public CertificateFactory()
Method Detail

engineGenerateCertificate

public Certificate engineGenerateCertificate(InputStream is)
                                      throws CertificateException
Parses a X.509 certificate from the supplied input stream.
Overrides:
engineGenerateCertificate in class CertificateFactorySpi
Parameters:
is - the input stream supplying the encoded certificate
Returns:
the X509Certificate parsed from the stream
Throws:
CertificateException - if an decoding/parsing error occurs

engineGenerateCertificates

public Collection engineGenerateCertificates(InputStream is)
                                      throws CertificateException
Parses a collection of X.509 certificates from the supplied input stream. The collection may be supplied in one of the following formats (encoding = DER):
  1. PKCS7CertList
  2. Chain of DER encoded X.509 certificates
  3. NetscapeCertList
Overrides:
engineGenerateCertificates in class CertificateFactorySpi
Parameters:
is - the input stream supplying the encoded certificates
Returns:
the collection of X509Certificates parsed from the stream
Throws:
CertificateException - if an decoding/parsing error occurs

engineGenerateCRL

public CRL engineGenerateCRL(InputStream is)
                      throws CRLException
Parses a X.509 CRL from the supplied input stream.
Overrides:
engineGenerateCRL in class CertificateFactorySpi
Parameters:
is - the input stream supplying the encoded CRL
Returns:
the X509CRL parsed from the stream
Throws:
CRLException - if an decoding/parsing error occurs

engineGenerateCRLs

public Collection engineGenerateCRLs(InputStream is)
                              throws CRLException
Parses a collection of X.509 CRLs from the supplied input stream. The collection may be supplied in one of the following formats (encoding = DER):
  1. PKCS7CRLList
  2. Chain of DER encoded X.509 CRLs
Overrides:
engineGenerateCRLs in class CertificateFactorySpi
Parameters:
is - the input stream supplying the encoded CRLs
Returns:
the collection of X509CRLs parsed from the stream
Throws:
CRLException - if an decoding/parsing error occurs

This Javadoc may contain text parts from Internet Standard specifications (RFC 2459, 3280, 3039, 2560, 1521, 821, 822, 2253, 1319, 1321, ,2630, 2631, 2268, 3058, 2984, 2104, 2144, 2040, 2311, 2279, see copyright note) and RSA Data Security Public-Key Cryptography Standards (PKCS#1,3,5,7,8,9,10,12, see copyright note).

IAIK-JCE 3.1 with IAIK-JCE CC Core 3.1, (c) 1997-2004 IAIK