summaryrefslogtreecommitdiff
path: root/java/security/cert/CertificateFactorySpi.java
diff options
context:
space:
mode:
authorCasey Marshall <csm@gnu.org>2003-04-23 23:15:47 +0000
committerCasey Marshall <csm@gnu.org>2003-04-23 23:15:47 +0000
commitd6887a7fff9ec6fbb66d5599bb6d446480ef9bee (patch)
tree4da0c9675e444098d416e252f05c1d2a3e983500 /java/security/cert/CertificateFactorySpi.java
parent14981d2fe10159f77a50b13ea956532f222635cd (diff)
downloadclasspath-d6887a7fff9ec6fbb66d5599bb6d446480ef9bee.tar.gz
java/security/Makefile.am: removed Engine.java
java/security/AlgorithmParameterGenerator.java java/security/AlgorithmParameters.java java/security/KeyFactory.java java/security/KeyPairGenerator.java java/security/KeyStore.java java/security/MessageDigest.java java/security/SecureRandom.java java/security/Signature.java accomodate changes to Engine class. java/security/cert/Certificate.java: Added writeReplace() method. java/security/cert/CertificateFactory.java: (JDK 1.4 compatibility) (getInstance(String)) and modified to use generic getInstance method. (getInstance(String, String)) likewise. getInstance(String, Provider) method added. getInstance(String, String, Provider) method removed. generateCertPath(InputStream) method added. generateCertPath(InputStream, String) method added. generateCertPath(List) method added. getCertPathEncodings() method added. java/security/cert/CertificateFactorySpi.java: (1.4 compatibility) engineGenerateCertPath(InputStream) method added. engineGenerateCertPath(InputStream, String) method added. engineGenerateCertPath(List) method added. engineGetCertPathEncodings() method added.
Diffstat (limited to 'java/security/cert/CertificateFactorySpi.java')
-rw-r--r--java/security/cert/CertificateFactorySpi.java82
1 files changed, 77 insertions, 5 deletions
diff --git a/java/security/cert/CertificateFactorySpi.java b/java/security/cert/CertificateFactorySpi.java
index 81293909e..2bf8155e3 100644
--- a/java/security/cert/CertificateFactorySpi.java
+++ b/java/security/cert/CertificateFactorySpi.java
@@ -1,5 +1,5 @@
/* CertificateFactorySpi.java --- Certificate Factory Class
- Copyright (C) 1999 Free Software Foundation, Inc.
+ Copyright (C) 1999,2003 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -37,8 +37,12 @@ exception statement from your version. */
package java.security.cert;
+
import java.io.InputStream;
+
import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
/**
CertificateFactorySpi is the abstract class Service Provider
@@ -53,16 +57,22 @@ import java.util.Collection;
@since JDK 1.2
@author Mark Benvenuto
-*/
+ */
public abstract class CertificateFactorySpi
{
+ // Constructor.
+ // ------------------------------------------------------------------------
+
/**
- Constructs a new CertificateFactorySpi
- */
+ * Constructs a new CertificateFactorySpi
+ */
public CertificateFactorySpi()
{}
+ // Abstract methods.
+ // ------------------------------------------------------------------------
+
/**
Generates a Certificate based on the encoded data read
from the InputStream.
@@ -77,7 +87,7 @@ public abstract class CertificateFactorySpi
For X.509 certificates, the certificate in inStream must be
DER encoded and supplied in binary or printable (Base64)
encoding. If the certificate is in Base64 encoding, it must be
- bounded by -----BEGINCERTIFICATE-----, and
+ bounded by -----BEGIN CERTIFICATE-----, and
-----END CERTIFICATE-----.
@param inStream an input stream containing the certificate data
@@ -149,5 +159,67 @@ public abstract class CertificateFactorySpi
*/
public abstract Collection engineGenerateCRLs(InputStream inStream)
throws CRLException;
+
+ // 1.4 instance methods.
+ // ------------------------------------------------------------------------
+
+ /**
+ * Generate a {@link CertPath} and initialize it with data parsed from
+ * the input stream. The default encoding of this factory is used.
+ *
+ * @param inStream The InputStream containing the CertPath data.
+ * @return A CertPath initialized from the input stream data.
+ * @throws CertificateException If an error occurs decoding the
+ * CertPath.
+ */
+ public CertPath engineGenerateCertPath(InputStream inStream)
+ throws CertificateException
+ {
+ throw new UnsupportedOperationException("not implemented");
+ }
+
+ /**
+ * Generate a {@link CertPath} and initialize it with data parsed from
+ * the input stream, using the specified encoding.
+ *
+ * @param inStream The InputStream containing the CertPath data.
+ * @param encoding The encoding of the InputStream data.
+ * @return A CertPath initialized from the input stream data.
+ * @throws CertificateException If an error occurs decoding the
+ * CertPath.
+ */
+ public CertPath engineGenerateCertPath(InputStream inStream, String encoding)
+ throws CertificateException
+ {
+ throw new UnsupportedOperationException("not implemented");
+ }
+
+ /**
+ * Generate a {@link CertPath} and initialize it with the certificates
+ * in the {@link java.util.List} argument.
+ *
+ * @param certificates The list of certificates with which to create
+ * the CertPath.
+ * @return A CertPath initialized from the certificates.
+ * @throws CertificateException If an error occurs generating the
+ * CertPath.
+ */
+ public CertPath engineGenerateCertPath(List certificates)
+ throws CertificateException
+ {
+ throw new UnsupportedOperationException("not implemented");
+ }
+
+ /**
+ * Returns an Iterator of CertPath encodings supported by this
+ * factory, with the default encoding first. The returned Iterator
+ * cannot be modified.
+ *
+ * @return The Iterator of supported encodings.
+ */
+ public Iterator engineGetCertPathEncodings()
+ {
+ throw new UnsupportedOperationException("not implemented");
+ }
}