[kaffe] CVS kaffe (robilad): Resynced with GNU Classpath: small cleanups in java.security

Kaffe CVS cvs-commits at kaffe.org
Sat Oct 23 11:22:13 PDT 2004


PatchSet 5341 
Date: 2004/10/23 18:18:12
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
Resynced with GNU Classpath: small cleanups in java.security

2004-10-23  Dalibor Topic  <robilad at kaffe.org>

        * libraries/javalib/java/security/AlgorithmParametersSpi.java,
        libraries/javalib/java/security/AllPermission.java,
        libraries/javalib/java/security/BasicPermission.java,
        libraries/javalib/java/security/Certificate.java,
        libraries/javalib/java/security/CodeSource.java,
        libraries/javalib/java/security/DigestOutputStream.java,
        libraries/javalib/java/security/GuardedObject.java,
        libraries/javalib/java/security/KeyFactorySpi.java,
        libraries/javalib/java/security/KeyStoreSpi.java,
        libraries/javalib/java/security/Permissions.java,
        libraries/javalib/java/security/Signer.java,
        libraries/javalib/java/security/UnresolvedPermission.java,
        libraries/javalib/java/security/cert/X509CRLSelector.java,
        libraries/javalib/java/security/cert/X509CertSelector.java,
        libraries/javalib/java/security/spec/DSAParameterSpec.java:
        Resynced with GNU Classpath.

        2004-10-21  Michael Koch  <konqueror at gmx.de>

        * java/security/AlgorithmParameterGenerator.java,
        java/security/AlgorithmParameters.java,
        java/security/AlgorithmParametersSpi.java,
        java/security/AllPermission.java,
        java/security/BasicPermission.java,
        java/security/Certificate.java,
        java/security/CodeSource.java,
        java/security/DigestInputStream.java,
        java/security/DigestOutputStream.java,
        java/security/GuardedObject.java,
        java/security/KeyFactory.java,
        java/security/KeyFactorySpi.java,
        java/security/KeyPairGenerator.java,
        java/security/KeyStore.java,
        java/security/KeyStoreSpi.java,
        java/security/Permissions.java,
        java/security/Security.java,
        java/security/Signature.java,
        java/security/UnresolvedPermission.java,
        java/security/cert/CertPathBuilder.java,
        java/security/cert/CertPathValidator.java,
        java/security/cert/CertStore.java,
        java/security/cert/Certificate.java,
        java/security/cert/CertificateFactory.java,
        java/security/cert/PolicyQualifierInfo.java,
        java/security/cert/TrustAnchor.java,
        java/security/cert/X509CRL.java,
        java/security/cert/X509CRLSelector.java,
        java/security/cert/X509CertSelector.java:
        Import cleanup.

Members: 
	ChangeLog:1.2893->1.2894 
	libraries/javalib/java/security/AlgorithmParametersSpi.java:1.3->1.4 
	libraries/javalib/java/security/AllPermission.java:1.2->1.3 
	libraries/javalib/java/security/BasicPermission.java:1.5->1.6 
	libraries/javalib/java/security/Certificate.java:1.4->1.5 
	libraries/javalib/java/security/CodeSource.java:1.6->1.7 
	libraries/javalib/java/security/DigestOutputStream.java:1.3->1.4 
	libraries/javalib/java/security/GuardedObject.java:1.2->1.3 
	libraries/javalib/java/security/KeyFactorySpi.java:1.3->1.4 
	libraries/javalib/java/security/KeyStoreSpi.java:1.3->1.4 
	libraries/javalib/java/security/Permissions.java:1.3->1.4 
	libraries/javalib/java/security/Signer.java:1.1->1.2 
	libraries/javalib/java/security/UnresolvedPermission.java:1.3->1.4 
	libraries/javalib/java/security/cert/X509CRLSelector.java:1.2->1.3 
	libraries/javalib/java/security/cert/X509CertSelector.java:1.1->1.2 
	libraries/javalib/java/security/spec/DSAParameterSpec.java:1.4->1.5 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.2893 kaffe/ChangeLog:1.2894
--- kaffe/ChangeLog:1.2893	Sat Oct 23 18:03:34 2004
+++ kaffe/ChangeLog	Sat Oct 23 18:18:12 2004
@@ -1,5 +1,57 @@
 2004-10-23  Dalibor Topic  <robilad at kaffe.org>
 
+	* libraries/javalib/java/security/AlgorithmParametersSpi.java,
+	libraries/javalib/java/security/AllPermission.java,
+	libraries/javalib/java/security/BasicPermission.java,
+	libraries/javalib/java/security/Certificate.java,
+	libraries/javalib/java/security/CodeSource.java,
+	libraries/javalib/java/security/DigestOutputStream.java,
+	libraries/javalib/java/security/GuardedObject.java,
+	libraries/javalib/java/security/KeyFactorySpi.java,
+	libraries/javalib/java/security/KeyStoreSpi.java,
+	libraries/javalib/java/security/Permissions.java,
+	libraries/javalib/java/security/Signer.java,
+	libraries/javalib/java/security/UnresolvedPermission.java,
+	libraries/javalib/java/security/cert/X509CRLSelector.java,
+	libraries/javalib/java/security/cert/X509CertSelector.java,
+	libraries/javalib/java/security/spec/DSAParameterSpec.java:
+	Resynced with GNU Classpath.
+
+	2004-10-21  Michael Koch  <konqueror at gmx.de>
+
+        * java/security/AlgorithmParameterGenerator.java,
+        java/security/AlgorithmParameters.java,
+        java/security/AlgorithmParametersSpi.java,
+        java/security/AllPermission.java,
+        java/security/BasicPermission.java,
+        java/security/Certificate.java,
+        java/security/CodeSource.java,
+        java/security/DigestInputStream.java,
+        java/security/DigestOutputStream.java,
+        java/security/GuardedObject.java,
+        java/security/KeyFactory.java,
+        java/security/KeyFactorySpi.java,
+        java/security/KeyPairGenerator.java,
+        java/security/KeyStore.java,
+        java/security/KeyStoreSpi.java,
+        java/security/Permissions.java,
+        java/security/Security.java,
+        java/security/Signature.java,
+        java/security/UnresolvedPermission.java,
+        java/security/cert/CertPathBuilder.java,
+        java/security/cert/CertPathValidator.java,
+        java/security/cert/CertStore.java,
+        java/security/cert/Certificate.java,
+        java/security/cert/CertificateFactory.java,
+        java/security/cert/PolicyQualifierInfo.java,
+        java/security/cert/TrustAnchor.java,
+        java/security/cert/X509CRL.java,
+        java/security/cert/X509CRLSelector.java,
+        java/security/cert/X509CertSelector.java:
+        Import cleanup.
+
+2004-10-23  Dalibor Topic  <robilad at kaffe.org>
+
 	* libraries/javalib/java/rmi/MarshalledObject.java,
 	libraries/javalib/java/rmi/Naming.java,
 	libraries/javalib/java/rmi/activation/Activatable.java,
Index: kaffe/libraries/javalib/java/security/AlgorithmParametersSpi.java
diff -u kaffe/libraries/javalib/java/security/AlgorithmParametersSpi.java:1.3 kaffe/libraries/javalib/java/security/AlgorithmParametersSpi.java:1.4
--- kaffe/libraries/javalib/java/security/AlgorithmParametersSpi.java:1.3	Fri Sep 24 00:13:32 2004
+++ kaffe/libraries/javalib/java/security/AlgorithmParametersSpi.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* AlgorithmParametersSpi.java --- Algorithm Parameters SPI
-   Copyright (C) 1999 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,79 +35,83 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.security;
-import java.security.spec.InvalidParameterSpecException;
-import java.security.spec.AlgorithmParameterSpec;
+
 import java.io.IOException;
+import java.security.spec.AlgorithmParameterSpec;
+import java.security.spec.InvalidParameterSpecException;
 
 /**
-   AlgorithmParametersSpi is the Service Provider Interface
-   for the Algorithm Parameters class. This class is used
-   to manage the algorithm parameters.
-
-   @since JDK 1.2
-   @author Mark Benvenuto
+ * AlgorithmParametersSpi is the Service Provider Interface
+ * for the Algorithm Parameters class. This class is used
+ * to manage the algorithm parameters.
+ *
+ * @since 1.2
+ * @author Mark Benvenuto
  */
 public abstract class AlgorithmParametersSpi
 {
   /**
-     Creates a new instance of AlgorithmParametersSpi
+   * Creates a new instance of AlgorithmParametersSpi
    */
   public AlgorithmParametersSpi()
   {
   }
 
   /**
-     Initializes the engine with the specified 
-     AlgorithmParameterSpec class.
-
-     @param paramSpec A AlgorithmParameterSpec to initialize with
-
-     @throws InvalidParameterSpecException For an inapporiate ParameterSpec class
+   * Initializes the engine with the specified 
+   * AlgorithmParameterSpec class.
+   *
+   * @param paramSpec A AlgorithmParameterSpec to initialize with
+   *
+   * @throws InvalidParameterSpecException For an inapporiate
+   * ParameterSpec class
    */
-  protected abstract void engineInit(AlgorithmParameterSpec paramSpec) throws
-    InvalidParameterSpecException;
+  protected abstract void engineInit(AlgorithmParameterSpec paramSpec)
+    throws InvalidParameterSpecException;
 
   /**
-     Initializes the engine with the specified 
-     parameters stored in the byte array and decodes them
-     according to the ASN.1 specification. If the ASN.1
-     specification exists then it succeeds or else it throws
-     IOException.
-
-     @param params Parameters to initialize with
-
-     @throws IOException Decoding Error
+   * Initializes the engine with the specified 
+   * parameters stored in the byte array and decodes them
+   * according to the ASN.1 specification. If the ASN.1
+   * specification exists then it succeeds or else it throws
+   * IOException.
+   *
+   * @param params Parameters to initialize with
+   *
+   * @throws IOException Decoding Error
    */
   protected abstract void engineInit(byte[]params) throws IOException;
 
   /**
-     Initializes the engine with the specified 
-     parameters stored in the byte array and decodes them
-     according to the specified decoding specification. 
-     If format is null, then it is decoded using the ASN.1 
-     specification if it exists or else it throws
-     IOException.
-
-     @param params Parameters to initialize with
-     @param format Name of decoding format to use
-
-     @throws IOException Decoding Error
-   */
-  protected abstract void engineInit(byte[]params,
-				     String format) throws IOException;
+   * Initializes the engine with the specified 
+   * parameters stored in the byte array and decodes them
+   * according to the specified decoding specification. 
+   * If format is null, then it is decoded using the ASN.1 
+   * specification if it exists or else it throws
+   * IOException.
+   *
+   * @param params Parameters to initialize with
+   * @param format Name of decoding format to use
+   *
+   * @throws IOException Decoding Error
+   */
+  protected abstract void engineInit(byte[]params, String format)
+    throws IOException;
 
 
   /**
-     Returns a specification of this AlgorithmParameters object.
-     paramSpec identifies the class to return the AlgortihmParameters
-     in. 
-
-     @param paramSpec Class to return AlgorithmParameters in
-
-     @return the parameter specification
-
-     @throws InvalidParameterSpecException if the paramSpec is an invalid parameter class
+   * Returns a specification of this AlgorithmParameters object.
+   * paramSpec identifies the class to return the AlgortihmParameters
+   * in.
+   *
+   * @param paramSpec Class to return AlgorithmParameters in
+   *
+   * @return the parameter specification
+   *
+   * @throws InvalidParameterSpecException if the paramSpec is an
+   * invalid parameter class
    */
   protected abstract AlgorithmParameterSpec engineGetParameterSpec(Class
 								   paramSpec)
@@ -115,31 +119,31 @@
 
 
   /**
-     Returns the parameters in the default encoding format. 
-     The primary encoding format is ASN.1 format if it exists
-     for the specified type.
-
-     @return byte array representing the parameters
+   * Returns the parameters in the default encoding format. 
+   * The primary encoding format is ASN.1 format if it exists
+   * for the specified type.
+   *
+   * @return byte array representing the parameters
    */
   protected abstract byte[] engineGetEncoded() throws IOException;
 
 
   /**
-     Returns the parameters in the specified encoding format. 
-     If <code>format</code> is <code>null</code> then the 
-     primary encoding format is used, the ASN.1 format, 
-     if it exists for the specified type.
-
-     @return byte array representing the parameters
-   */
-  protected abstract byte[] engineGetEncoded(String format) throws
-    IOException;
+   * Returns the parameters in the specified encoding format. 
+   * If <code>format</code> is <code>null</code> then the 
+   * primary encoding format is used, the ASN.1 format, 
+   * if it exists for the specified type.
+   *
+   * @return byte array representing the parameters
+   */
+  protected abstract byte[] engineGetEncoded(String format)
+    throws IOException;
 
   /**
-     Returns a string describing the parameters in the 
-     AlgorithmParametersSpi class.
-
-     @return A string representing the format of the parameters.
+   * Returns a string describing the parameters in the 
+   * AlgorithmParametersSpi class.
+   *
+   * @return A string representing the format of the parameters.
    */
   protected abstract String engineToString();
 }
Index: kaffe/libraries/javalib/java/security/AllPermission.java
diff -u kaffe/libraries/javalib/java/security/AllPermission.java:1.2 kaffe/libraries/javalib/java/security/AllPermission.java:1.3
--- kaffe/libraries/javalib/java/security/AllPermission.java:1.2	Mon Mar 22 11:24:59 2004
+++ kaffe/libraries/javalib/java/security/AllPermission.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* AllPermission.java -- Permission to do anything
-   Copyright (C) 1998, 2001, 2002 Free Software Foundation, Inc.
+   Copyright (C) 1998, 2001, 2002, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,6 +35,7 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.security;
 
 import gnu.java.util.EmptyEnumeration;
@@ -47,8 +48,8 @@
  * this permission effectively grants all others.  Extreme caution should
  * be exercised in granting this permission.
  *
- * @author Aaron M. Renn <arenn at urbanophile.com>
- * @author Eric Blake <ebb9 at email.byu.edu>
+ * @author Aaron M. Renn (arenn at urbanophile.com)
+ * @author Eric Blake (ebb9 at email.byu.edu)
  * @see AccessController
  * @see Permissions
  * @see SecurityManager
Index: kaffe/libraries/javalib/java/security/BasicPermission.java
diff -u kaffe/libraries/javalib/java/security/BasicPermission.java:1.5 kaffe/libraries/javalib/java/security/BasicPermission.java:1.6
--- kaffe/libraries/javalib/java/security/BasicPermission.java:1.5	Tue Sep 28 20:29:09 2004
+++ kaffe/libraries/javalib/java/security/BasicPermission.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* BasicPermission.java -- implements a simple named permission
-   Copyright (C) 1998, 1999, 2002, 2003 Free Software Foundation, Inc.
+   Copyright (C) 1998, 1999, 2002, 2003, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,11 +35,12 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.security;
 
 import java.io.Serializable;
-import java.util.Hashtable;
 import java.util.Enumeration;
+import java.util.Hashtable;
 
 /**
  * This class implements a simple model for named permissions without an
Index: kaffe/libraries/javalib/java/security/Certificate.java
diff -u kaffe/libraries/javalib/java/security/Certificate.java:1.4 kaffe/libraries/javalib/java/security/Certificate.java:1.5
--- kaffe/libraries/javalib/java/security/Certificate.java:1.4	Mon Mar 22 11:24:59 2004
+++ kaffe/libraries/javalib/java/security/Certificate.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* Certificate.java -- deprecated interface for modeling digital certificates
-   Copyright (C) 1998, 2002 Free Software Foundation, Inc.
+   Copyright (C) 1998, 2002, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
Index: kaffe/libraries/javalib/java/security/CodeSource.java
diff -u kaffe/libraries/javalib/java/security/CodeSource.java:1.6 kaffe/libraries/javalib/java/security/CodeSource.java:1.7
--- kaffe/libraries/javalib/java/security/CodeSource.java:1.6	Sat Sep 25 22:06:40 2004
+++ kaffe/libraries/javalib/java/security/CodeSource.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* CodeSource.java -- Code location and certifcates
-   Copyright (C) 1998, 2002 Free Software Foundation, Inc.
+   Copyright (C) 1998, 2002, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -43,13 +43,13 @@
 import java.io.ObjectInputStream;
 import java.io.ObjectOutputStream;
 import java.io.Serializable;
-import java.net.URL;
 import java.net.SocketPermission;
+import java.net.URL;
 // Note that this overrides Certificate in this package.
 import java.security.cert.Certificate;
-import java.security.cert.CertificateFactory;
 import java.security.cert.CertificateEncodingException;
 import java.security.cert.CertificateException;
+import java.security.cert.CertificateFactory;
 import java.util.Arrays;
 import java.util.HashSet;
 import java.util.Iterator;
@@ -59,8 +59,8 @@
  * represented by a URL), and the list of certificates that are used to
  * check the signatures of signed code loaded from this source.
  *
- * @author Aaron M. Renn <arenn at urbanophile.com>
- * @author Eric Blake <ebb9 at email.byu.edu>
+ * @author Aaron M. Renn (arenn at urbanophile.com)
+ * @author Eric Blake (ebb9 at email.byu.edu)
  * @since 1.1
  * @status updated to 1.4
  */
Index: kaffe/libraries/javalib/java/security/DigestOutputStream.java
diff -u kaffe/libraries/javalib/java/security/DigestOutputStream.java:1.3 kaffe/libraries/javalib/java/security/DigestOutputStream.java:1.4
--- kaffe/libraries/javalib/java/security/DigestOutputStream.java:1.3	Wed Sep 22 00:05:42 2004
+++ kaffe/libraries/javalib/java/security/DigestOutputStream.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* DigestOutputStream.java --- An output stream tied to a message digest
-   Copyright (C) 1999 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,28 +35,29 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.security;
 
-import java.io.OutputStream;
 import java.io.FilterOutputStream;
 import java.io.IOException;
+import java.io.OutputStream;
 
 /**
-   DigestOutputStream is a class that ties an OutputStream with a
-   MessageDigest. The Message Digest is used by the class to update it
-   self as bytes are written to the OutputStream.
-
-   The updating to the digest depends on the on flag which is set to
-   true by default that tells the class to update the data in the
-   message digest.
-
-   @version 0.0
-   @author Mark Benvenuto <ivymccough at worldnet.att.net>
+ * DigestOutputStream is a class that ties an OutputStream with a
+ * MessageDigest. The Message Digest is used by the class to update it
+ * self as bytes are written to the OutputStream.
+ *
+ * The updating to the digest depends on the on flag which is set to
+ * true by default that tells the class to update the data in the
+ * message digest.
+ *
+ * @version 0.0
+ * @author Mark Benvenuto <ivymccough at worldnet.att.net>
  */
 public class DigestOutputStream extends FilterOutputStream
 {
   /**
-     The message digest for the DigestOutputStream
+   * The message digest for the DigestOutputStream
    */
   protected MessageDigest digest;
 
@@ -64,12 +65,12 @@
   private boolean state = true;
 
   /**
-     Constructs a new DigestOutputStream.  It associates a
-     MessageDigest with the stream to compute the stream as data is
-     written.
-
-     @param stream An OutputStream to associate this stream with
-     @param digest A MessageDigest to hash the stream with
+   * Constructs a new DigestOutputStream.  It associates a
+   * MessageDigest with the stream to compute the stream as data is
+   * written.
+   *
+   * @param stream An OutputStream to associate this stream with
+   * @param digest A MessageDigest to hash the stream with
    */
   public DigestOutputStream(OutputStream stream, MessageDigest digest)
   {
@@ -78,9 +79,9 @@
   }
 
   /**
-     Returns the MessageDigest associated with this DigestOutputStream
-
-     @return The MessageDigest used to hash this stream
+   * Returns the MessageDigest associated with this DigestOutputStream
+   *
+   * @return The MessageDigest used to hash this stream
    */
   public MessageDigest getMessageDigest()
   {
@@ -88,9 +89,9 @@
   }
 
   /**
-     Sets the current MessageDigest to current parameter
-
-     @param digest A MessageDigest to associate with this stream
+   * Sets the current MessageDigest to current parameter
+   *
+   * @param digest A MessageDigest to associate with this stream
    */
   public void setMessageDigest(MessageDigest digest)
   {
@@ -99,13 +100,13 @@
 
 
   /**
-     Updates the hash if the on flag is true and then writes a byte to
-     the underlying output stream.
-
-     @param b A byte to write to the output stream
-
-     @exception IOException if the underlying output stream 
-     cannot write the byte, this is thrown.
+   * Updates the hash if the on flag is true and then writes a byte to
+   * the underlying output stream.
+   *
+   * @param b A byte to write to the output stream
+   *
+   * @exception IOException if the underlying output stream 
+   * cannot write the byte, this is thrown.
    */
   public void write(int b) throws IOException
   {
@@ -116,15 +117,15 @@
   }
 
   /**
-     Updates the hash if the on flag is true and then writes the bytes
-     to the underlying output stream.
-
-     @param b Bytes to write to the output stream
-     @param off Offset to start to start at in array
-     @param len Length of data to write
-
-     @exception IOException if the underlying output stream 
-     cannot write the bytes, this is thrown.
+   * Updates the hash if the on flag is true and then writes the bytes
+   * to the underlying output stream.
+   *
+   * @param b Bytes to write to the output stream
+   * @param off Offset to start to start at in array
+   * @param len Length of data to write
+   *
+   * @exception IOException if the underlying output stream 
+   * cannot write the bytes, this is thrown.
    */
   public void write(byte[]b, int off, int len) throws IOException
   {
@@ -135,10 +136,10 @@
   }
 
   /**
-     Sets the flag specifying if this DigestOutputStream updates the
-     digest in the write() methods. The default is on;
-
-     @param on True means it digests stream, false means it does not
+   * Sets the flag specifying if this DigestOutputStream updates the
+   * digest in the write() methods. The default is on;
+   *
+   * @param on True means it digests stream, false means it does not
    */
   public void on(boolean on)
   {
@@ -146,9 +147,9 @@
   }
 
   /**
-     Converts the output stream and underlying message digest to a string.
-
-     @return A string representing the output stream and message digest.
+   * Converts the output stream and underlying message digest to a string.
+   *
+   * @return A string representing the output stream and message digest.
    */
   public String toString()
   {
Index: kaffe/libraries/javalib/java/security/GuardedObject.java
diff -u kaffe/libraries/javalib/java/security/GuardedObject.java:1.2 kaffe/libraries/javalib/java/security/GuardedObject.java:1.3
--- kaffe/libraries/javalib/java/security/GuardedObject.java:1.2	Wed Sep 22 08:11:09 2004
+++ kaffe/libraries/javalib/java/security/GuardedObject.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* GuardedObject.java -- An object protected by a Guard
-   Copyright (C) 1998, 2002 Free Software Foundation, Inc.
+   Copyright (C) 1998, 2002, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,11 +35,12 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.security;
 
-import java.io.Serializable;
 import java.io.IOException;
 import java.io.ObjectOutputStream;
+import java.io.Serializable;
 
 /**
  * This class is an object that is guarded by a <code>Guard</code> object.
Index: kaffe/libraries/javalib/java/security/KeyFactorySpi.java
diff -u kaffe/libraries/javalib/java/security/KeyFactorySpi.java:1.3 kaffe/libraries/javalib/java/security/KeyFactorySpi.java:1.4
--- kaffe/libraries/javalib/java/security/KeyFactorySpi.java:1.3	Fri Sep 24 01:23:39 2004
+++ kaffe/libraries/javalib/java/security/KeyFactorySpi.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* KeyFactorySpi.java --- Key Factory Service Provider Interface
-   Copyright (C) 1999 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,96 +35,98 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.security;
-import java.security.spec.KeySpec;
+
 import java.security.spec.InvalidKeySpecException;
+import java.security.spec.KeySpec;
 
 /**
-   KeyFactorySpi is the Service Provider Interface (SPI) for the 
-   KeyFactory class. This is the interface for providers to 
-   supply to implement a key factory for an algorithm.
-
-   Key factories are used to convert keys (opaque cryptographic 
-   keys of type Key) into key specifications (transparent 
-   representations of the underlying key material).
-
-   Key factories are bi-directional. They allow a key class 
-   to be converted into a key specification (key material) and
-   back again.
-
-   For example DSA public keys can be specified as 
-   DSAPublicKeySpec or X509EncodedKeySpec. The key factory
-   translate these key specifications. 
-
-   @since JDK 1.2
-   @author Mark Benvenuto
+ * KeyFactorySpi is the Service Provider Interface (SPI) for the 
+ * KeyFactory class. This is the interface for providers to 
+ * supply to implement a key factory for an algorithm.
+ *
+ * Key factories are used to convert keys (opaque cryptographic 
+ * keys of type Key) into key specifications (transparent 
+ * representations of the underlying key material).
+ *
+ * Key factories are bi-directional. They allow a key class 
+ * to be converted into a key specification (key material) and
+ * back again.
+ *
+ * For example DSA public keys can be specified as 
+ * DSAPublicKeySpec or X509EncodedKeySpec. The key factory
+ * translate these key specifications. 
+ *
+ * @since JDK 1.2
+ * @author Mark Benvenuto
  */
 public abstract class KeyFactorySpi
 {
   /**
-     Constucts a new KeyFactorySpi.
+   * Constucts a new KeyFactorySpi.
    */
   public KeyFactorySpi()
   {
   }
 
   /**
-     Generates a public key from the provided key specification.
-
-     @param keySpec key specification
-
-     @return the public key
-
-     @throws InvalidKeySpecException invalid key specification for
-     this key factory to produce a public key
+   * Generates a public key from the provided key specification.
+   *
+   * @param keySpec key specification
+   *
+   * @return the public key
+   *
+   * @throws InvalidKeySpecException invalid key specification for
+   * this key factory to produce a public key
    */
   protected abstract PublicKey engineGeneratePublic(KeySpec keySpec)
     throws InvalidKeySpecException;
 
 
   /**
-     Generates a private key from the provided key specification.
-
-     @param keySpec key specification
-
-     @return the private key
-
-     @throws InvalidKeySpecException invalid key specification for
-     this key factory to produce a private key
+   * Generates a private key from the provided key specification.
+   *
+   * @param keySpec key specification
+   *
+   * @return the private key
+   *
+   * @throws InvalidKeySpecException invalid key specification for
+   * this key factory to produce a private key
    */
   protected abstract PrivateKey engineGeneratePrivate(KeySpec keySpec)
     throws InvalidKeySpecException;
 
   /**
-     Returns a key specification for the given key. keySpec 
-     identifies the specification class to return the key 
-     material in.
-
-     @param key the key
-     @param keySpec the specification class to return the 
-     key material in.
-
-     @return the key specification in an instance of the requested
-     specification class
-
-     @throws InvalidKeySpecException the requested key specification
-     is inappropriate for this key or the key is 
-     unrecognized.
+   * Returns a key specification for the given key. keySpec 
+   * identifies the specification class to return the key 
+   * material in.
+   *
+   * @param key the key
+   * @param keySpec the specification class to return the 
+   * key material in.
+   *
+   * @return the key specification in an instance of the requested
+   * specification class
+   *
+   * @throws InvalidKeySpecException the requested key specification
+   * is inappropriate for this key or the key is 
+   * unrecognized.
    */
   protected abstract KeySpec engineGetKeySpec(Key key, Class keySpec)
     throws InvalidKeySpecException;
 
 
   /**
-     Translates the key from an unknown or untrusted provider
-     into a key for this key factory.
-
-     @param the key from an unknown or untrusted provider
-
-     @return the translated key
-
-     @throws InvalidKeySpecException if the key cannot be 
-     processed by this key factory
+   * Translates the key from an unknown or untrusted provider
+   * into a key for this key factory.
+   *
+   * @param the key from an unknown or untrusted provider
+   *
+   * @return the translated key
+   *
+   * @throws InvalidKeySpecException if the key cannot be 
+   * processed by this key factory
    */
   protected abstract Key engineTranslateKey(Key key)
     throws InvalidKeyException;
Index: kaffe/libraries/javalib/java/security/KeyStoreSpi.java
diff -u kaffe/libraries/javalib/java/security/KeyStoreSpi.java:1.3 kaffe/libraries/javalib/java/security/KeyStoreSpi.java:1.4
--- kaffe/libraries/javalib/java/security/KeyStoreSpi.java:1.3	Fri Sep 24 17:54:45 2004
+++ kaffe/libraries/javalib/java/security/KeyStoreSpi.java	Sat Oct 23 18:18:13 2004
@@ -1,5 +1,5 @@
 /* KeyStoreSpi.java --- Key Store Service Provider Interface
-   Copyright (C) 1999 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,101 +35,103 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.security;
-import java.io.InputStream;
+
 import java.io.IOException;
+import java.io.InputStream;
 import java.io.OutputStream;
 import java.security.cert.CertificateException;
 import java.util.Date;
 import java.util.Enumeration;
 
 /**
-   KeyStoreSpi is the Service Provider Interface (SPI) for the 
-   KeyStore class. This is the interface for providers to 
-   supply to implement a keystore for a particular keystore 
-   type.
-
-   @since JDK 1.2
-   @author Mark Benvenuto
+ * KeyStoreSpi is the Service Provider Interface (SPI) for the 
+ * KeyStore class. This is the interface for providers to 
+ * supply to implement a keystore for a particular keystore 
+ * type.
+ *
+ * @since 1.2
+ * @author Mark Benvenuto
  */
 public abstract class KeyStoreSpi
 {
   /**
-     Constructs a new KeyStoreSpi
+   * Constructs a new KeyStoreSpi
    */
   public KeyStoreSpi()
   {
   }
 
   /**
-     Returns the key associated with given alias using the 
-     supplied password.
-
-     @param alias an alias for the key to get
-     @param password password to access key with
-
-     @return the requested key, or null otherwise
-
-     @throws NoSuchAlgorithmException if there is no algorithm
-     for recovering the key
-     @throws UnrecoverableKeyException key cannot be reocovered
-     (wrong password).
+   * Returns the key associated with given alias using the 
+   * supplied password.
+   *
+   * @param alias an alias for the key to get
+   * @param password password to access key with
+   *
+   * @return the requested key, or null otherwise
+   *
+   * @throws NoSuchAlgorithmException if there is no algorithm
+   * for recovering the key
+   * @throws UnrecoverableKeyException key cannot be reocovered
+   * (wrong password).
    */
   public abstract Key engineGetKey(String alias, char[]password)
     throws NoSuchAlgorithmException, UnrecoverableKeyException;
 
   /**
-     Gets a Certificate chain for the specified alias.
-
-     @param alias the alias name
-
-     @return a chain of Certificates ( ordered from the user's 
-     certificate to the Certificate Authority's ) or 
-     null if the alias does not exist or there is no
-     certificate chain for the alias ( the alias refers
-     to a trusted certificate entry or there is no entry).
+   * Gets a Certificate chain for the specified alias.
+   *
+   * @param alias the alias name
+   *
+   * @return a chain of Certificates ( ordered from the user's 
+   * certificate to the Certificate Authority's ) or 
+   * null if the alias does not exist or there is no
+   * certificate chain for the alias ( the alias refers
+   * to a trusted certificate entry or there is no entry).
    */
   public abstract java.security.cert.
     Certificate[] engineGetCertificateChain(String alias);
 
 
   /**
-     Gets a Certificate for the specified alias.
-
-     If there is a trusted certificate entry then that is returned.
-     it there is a key entry with a certificate chain then the
-     first certificate is return or else null.
-
-     @param alias the alias name
-
-     @return a Certificate or null if the alias does not exist 
-     or there is no certificate for the alias
+   * Gets a Certificate for the specified alias.
+   *
+   * If there is a trusted certificate entry then that is returned.
+   * it there is a key entry with a certificate chain then the
+   * first certificate is return or else null.
+   *
+   * @param alias the alias name
+   *
+   * @return a Certificate or null if the alias does not exist 
+   * or there is no certificate for the alias
    */
   public abstract java.security.cert.
     Certificate engineGetCertificate(String alias);
 
   /**
-     Gets entry creation date for the specified alias.
-
-     @param alias the alias name
-
-     @returns the entry creation date or null
+   * Gets entry creation date for the specified alias.
+   *
+   * @param alias the alias name
+   *
+   * @returns the entry creation date or null
    */
   public abstract Date engineGetCreationDate(String alias);
 
   /**
-     Assign the key to the alias in the keystore, protecting it
-     with the given password. It will overwrite an existing 
-     entry and if the key is a PrivateKey, also add the 
-     certificate chain representing the corresponding public key.
-
-     @param alias the alias name
-     @param key the key to add
-     @password the password to protect with
-     @param chain the certificate chain for the corresponding
-     public key
-
-     @throws KeyStoreException if it fails
+   * Assign the key to the alias in the keystore, protecting it
+   * with the given password. It will overwrite an existing 
+   * entry and if the key is a PrivateKey, also add the 
+   * certificate chain representing the corresponding public key.
+   *
+   * @param alias the alias name
+   * @param key the key to add
+   * @password the password to protect with
+   * @param chain the certificate chain for the corresponding
+   * public key
+   *
+   * @throws KeyStoreException if it fails
    */
   public abstract void engineSetKeyEntry(String alias, Key key,
 					 char[]password,
@@ -138,17 +140,17 @@
     KeyStoreException;
 
   /**
-     Assign the key to the alias in the keystore. It will overwrite
-     an existing entry and if the key is a PrivateKey, also 
-     add the certificate chain representing the corresponding 
-     public key.
-
-     @param alias the alias name
-     @param key the key to add
-     @param chain the certificate chain for the corresponding
-     public key
-
-     @throws KeyStoreException if it fails
+   * Assign the key to the alias in the keystore. It will overwrite
+   * an existing entry and if the key is a PrivateKey, also 
+   * add the certificate chain representing the corresponding 
+   * public key.
+   *
+   * @param alias the alias name
+   * @param key the key to add
+   * @param chain the certificate chain for the corresponding
+   * public key

*** Patch too long, truncated ***




More information about the kaffe mailing list