diff options
Diffstat (limited to 'libjava/classpath/gnu/java/security')
122 files changed, 456 insertions, 458 deletions
diff --git a/libjava/classpath/gnu/java/security/Engine.java b/libjava/classpath/gnu/java/security/Engine.java index 6c39d46acc6..969fcef6ce5 100644 --- a/libjava/classpath/gnu/java/security/Engine.java +++ b/libjava/classpath/gnu/java/security/Engine.java @@ -58,7 +58,7 @@ import java.util.Enumeration; * represents. * * @see Provider - * @author Casey Marshall + * @author Casey Marshall */ public final class Engine { @@ -85,7 +85,7 @@ public final class Engine * Return the implementation for <i>algorithm</i> for service <i>service</i> * from <i>provider</i>. The service is e.g. "Signature", and the algorithm * "DSA". - * + * * @param service The service name. * @param algorithm The name of the algorithm to get. * @param provider The provider to get the implementation from. @@ -111,7 +111,7 @@ public final class Engine * constructor (which cannot be null; pass a zero-length array if the SPI * takes no arguments). The service is e.g. "Signature", and the algorithm * "DSA". - * + * * @param service The service name. * @param algorithm The name of the algorithm to get. * @param provider The provider to get the implementation from. @@ -159,7 +159,7 @@ public final class Engine if (key.equalsIgnoreCase(service + "." + algorithm)) { // remove the service portion from the key - algorithm = key.substring(service.length() + 1); + algorithm = key.substring(service.length() + 1); algorithmFound = true; break; } diff --git a/libjava/classpath/gnu/java/security/OID.java b/libjava/classpath/gnu/java/security/OID.java index a3d70e22019..c7efe6557ca 100644 --- a/libjava/classpath/gnu/java/security/OID.java +++ b/libjava/classpath/gnu/java/security/OID.java @@ -75,7 +75,7 @@ public class OID implements Cloneable, Comparable, java.io.Serializable /* Serial version id for serialization. */ static final long serialVersionUID = 5722492029044597779L; - + /** * The numeric ID structure. */ diff --git a/libjava/classpath/gnu/java/security/PolicyFile.java b/libjava/classpath/gnu/java/security/PolicyFile.java index e9c811644df..0560bce0732 100644 --- a/libjava/classpath/gnu/java/security/PolicyFile.java +++ b/libjava/classpath/gnu/java/security/PolicyFile.java @@ -154,7 +154,7 @@ public final class PolicyFile extends Policy // Added to cut redundant AccessController.doPrivileged calls private static GetPropertyAction prop = new GetPropertyAction("file.separator"); private static final String fs = (String) AccessController.doPrivileged(prop); - + private static final String DEFAULT_POLICY = (String) AccessController.doPrivileged(prop.setParameters("java.home")) + fs + "lib" + fs + "security" + fs + "java.policy"; @@ -536,7 +536,7 @@ public final class PolicyFile extends Policy if (clazz == null) { currentPerms.add(new UnresolvedPermission(className, - null, null, (Certificate[]) currentCerts.toArray(new Certificate[currentCerts.size()]))); + null, null, (Certificate[]) currentCerts.toArray(new Certificate[currentCerts.size()]))); continue; } try @@ -558,7 +558,7 @@ public final class PolicyFile extends Policy if (clazz == null) { currentPerms.add(new UnresolvedPermission(className, - target, null, (Certificate[]) currentCerts.toArray(new Certificate[currentCerts.size()]))); + target, null, (Certificate[]) currentCerts.toArray(new Certificate[currentCerts.size()]))); continue; } try @@ -601,7 +601,7 @@ public final class PolicyFile extends Policy if (clazz == null) { currentPerms.add(new UnresolvedPermission(className, - target, action, (Certificate[]) currentCerts.toArray(new Certificate[currentCerts.size()]))); + target, action, (Certificate[]) currentCerts.toArray(new Certificate[currentCerts.size()]))); continue; } else diff --git a/libjava/classpath/gnu/java/security/Properties.java b/libjava/classpath/gnu/java/security/Properties.java index a515a54280a..2213bde0607 100644 --- a/libjava/classpath/gnu/java/security/Properties.java +++ b/libjava/classpath/gnu/java/security/Properties.java @@ -90,7 +90,7 @@ public final class Properties /** * Returns the string representation of the library global configuration * property with the designated <code>key</code>. - * + * * @param key the case-insensitive, non-null and non-empty name of a * configuration property. * @return the string representation of the designated property, or @@ -113,7 +113,7 @@ public final class Properties /** * Sets the value of a designated library global configuration property, to a * string representation of what should be a legal value. - * + * * @param key the case-insensitive, non-null and non-empty name of a * configuration property. * @param value the non-null, non-empty string representation of a legal value @@ -151,7 +151,7 @@ public final class Properties * A convenience method that returns, as a boolean, the library global * configuration property indicating if the default Pseudo Random Number * Generator produces, or not, the same bit stream when instantiated. - * + * * @return <code>true</code> if the default PRNG produces the same bit * stream with every VM instance. Returns <code>false</code> if the * default PRNG is seeded with the time of day of its first @@ -171,7 +171,7 @@ public final class Properties * block ciphers check, or not, for possible/potential weak and semi-weak keys * that may be produced in the course of generating round encryption and/or * decryption keys. - * + * * @return <code>true</code> if the cipher implementations check for weak * and semi-weak keys. Returns <code>false</code> if the cipher * implementations do not check for weak or semi-weak keys. @@ -188,7 +188,7 @@ public final class Properties * A convenience method that returns, as a boolean, the library global * configuration property indicating if RSA decryption (RSADP primitive), * does, or not, blinding against timing attacks. - * + * * @return <code>true</code> if the RSA decryption primitive includes a * blinding operation. Returns <code>false</code> if the RSA * decryption primitive does not include the additional blinding @@ -205,7 +205,7 @@ public final class Properties /** * A convenience method to set the global property for reproducibility of the * default PRNG bit stream output. - * + * * @param value if <code>true</code> then the default PRNG bit stream output * is the same with every invocation of the VM. */ @@ -221,7 +221,7 @@ public final class Properties /** * A convenience method to set the global property for checking for weak and * semi-weak cipher keys. - * + * * @param value if <code>true</code> then the cipher implementations will * invoke additional checks for weak and semi-weak key values that * may get generated. @@ -238,7 +238,7 @@ public final class Properties /** * A convenience method to set the global property fo adding a blinding * operation when executing the RSA decryption primitive. - * + * * @param value if <code>true</code> then the code for performing the RSA * decryption primitive will include a blinding operation. */ diff --git a/libjava/classpath/gnu/java/security/Registry.java b/libjava/classpath/gnu/java/security/Registry.java index 053d7177833..4ce5044ab6d 100644 --- a/libjava/classpath/gnu/java/security/Registry.java +++ b/libjava/classpath/gnu/java/security/Registry.java @@ -1,4 +1,4 @@ -/* Registry.java -- +/* Registry.java -- Copyright (C) 2001, 2002, 2003, 2004, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/Requires.java b/libjava/classpath/gnu/java/security/Requires.java index c820336c01e..6b52bd16836 100644 --- a/libjava/classpath/gnu/java/security/Requires.java +++ b/libjava/classpath/gnu/java/security/Requires.java @@ -46,8 +46,8 @@ import static java.lang.annotation.RetentionPolicy.CLASS; import java.security.Permission; /** - * - * + * + * * @author Casey Marshall (csm@gnu.org) */ @Documented @Retention(CLASS) @Target(METHOD) diff --git a/libjava/classpath/gnu/java/security/action/GetPropertyAction.java b/libjava/classpath/gnu/java/security/action/GetPropertyAction.java index 0c8141a4d9b..7295d8d5ab1 100644 --- a/libjava/classpath/gnu/java/security/action/GetPropertyAction.java +++ b/libjava/classpath/gnu/java/security/action/GetPropertyAction.java @@ -57,7 +57,7 @@ public class GetPropertyAction implements PrivilegedAction<String> public GetPropertyAction() { } - + public GetPropertyAction(String propName) { setParameters(propName); @@ -67,12 +67,12 @@ public class GetPropertyAction implements PrivilegedAction<String> { setParameters(propName, defaultValue); } - + public String run() { return System.getProperty(name, value); } - + public GetPropertyAction setParameters(String propName) { this.name = propName; diff --git a/libjava/classpath/gnu/java/security/action/SetAccessibleAction.java b/libjava/classpath/gnu/java/security/action/SetAccessibleAction.java index 77e5fc988b8..d3e3c0f9085 100644 --- a/libjava/classpath/gnu/java/security/action/SetAccessibleAction.java +++ b/libjava/classpath/gnu/java/security/action/SetAccessibleAction.java @@ -41,7 +41,7 @@ import java.lang.reflect.AccessibleObject; import java.security.PrivilegedAction; /** - * PrivilegedAction implementation that calls setAccessible(true) on the + * PrivilegedAction implementation that calls setAccessible(true) on the * AccessibleObject passed to its constructor. * * Example of use: @@ -53,22 +53,22 @@ import java.security.PrivilegedAction; public class SetAccessibleAction implements PrivilegedAction { AccessibleObject member; - + public SetAccessibleAction() { } - + public SetAccessibleAction(AccessibleObject member) { this.member = member; } - + public Object run() { member.setAccessible(true); return null; } - + public SetAccessibleAction setMember(AccessibleObject member) { this.member = member; diff --git a/libjava/classpath/gnu/java/security/der/DERValue.java b/libjava/classpath/gnu/java/security/der/DERValue.java index d98ce78ec55..2cbe3457333 100644 --- a/libjava/classpath/gnu/java/security/der/DERValue.java +++ b/libjava/classpath/gnu/java/security/der/DERValue.java @@ -173,11 +173,11 @@ public class DERValue implements DER public String toString() { String start = "DERValue ( ["; - if (tagClass == DER.UNIVERSAL) + if (tagClass == DER.UNIVERSAL) start = start + "UNIVERSAL "; - else if (tagClass == DER.PRIVATE) + else if (tagClass == DER.PRIVATE) start = start + "PRIVATE "; - else if (tagClass == DER.APPLICATION) + else if (tagClass == DER.APPLICATION) start = start + "APPLICATION "; start = start + tag + "] constructed=" + constructed + ", value="; if (constructed) diff --git a/libjava/classpath/gnu/java/security/hash/BaseHash.java b/libjava/classpath/gnu/java/security/hash/BaseHash.java index ff1750aeae0..bab930f28e1 100644 --- a/libjava/classpath/gnu/java/security/hash/BaseHash.java +++ b/libjava/classpath/gnu/java/security/hash/BaseHash.java @@ -1,4 +1,4 @@ -/* BaseHash.java -- +/* BaseHash.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -61,7 +61,7 @@ public abstract class BaseHash /** * Trivial constructor for use by concrete subclasses. - * + * * @param name the canonical name prefix of this instance. * @param hashSize the block size of the output in bytes. * @param blockSize the block size of the internal transform. @@ -156,7 +156,7 @@ public abstract class BaseHash /** * Returns the byte array to use as padding before completing a hash * operation. - * + * * @return the bytes to pad the remaining bytes in the buffer before * completing a hash operation. */ @@ -164,7 +164,7 @@ public abstract class BaseHash /** * Constructs the result from the contents of the current context. - * + * * @return the output of the completed hash operation. */ protected abstract byte[] getResult(); @@ -174,7 +174,7 @@ public abstract class BaseHash /** * The block digest transformation per se. - * + * * @param in the <i>blockSize</i> long block, as an array of bytes to digest. * @param offset the index where the data to digest is located within the * input buffer. diff --git a/libjava/classpath/gnu/java/security/hash/HashFactory.java b/libjava/classpath/gnu/java/security/hash/HashFactory.java index 2a4e487858c..1210ff4db2f 100644 --- a/libjava/classpath/gnu/java/security/hash/HashFactory.java +++ b/libjava/classpath/gnu/java/security/hash/HashFactory.java @@ -1,4 +1,4 @@ -/* HashFactory.java -- +/* HashFactory.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -57,7 +57,7 @@ public class HashFactory /** * Return an instance of a hash algorithm given its name. - * + * * @param name the name of the hash algorithm. * @return an instance of the hash algorithm, or null if none found. * @exception InternalError if the implementation does not pass its self- @@ -111,7 +111,7 @@ public class HashFactory /** * Returns a {@link Set} of names of hash algorithms supported by this * <i>Factory</i>. - * + * * @return a {@link Set} of hash names (Strings). */ public static final Set getNames() diff --git a/libjava/classpath/gnu/java/security/hash/Haval.java b/libjava/classpath/gnu/java/security/hash/Haval.java index 662934f34ea..15c30393450 100644 --- a/libjava/classpath/gnu/java/security/hash/Haval.java +++ b/libjava/classpath/gnu/java/security/hash/Haval.java @@ -1,4 +1,4 @@ -/* Haval.java -- +/* Haval.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -105,7 +105,7 @@ public class Haval /** * Calls the constructor with two arguments using the designated output size, * and {@link #HAVAL_3_ROUND} for the value of number of rounds. - * + * * @param size the output size in bytes of this instance. * @throws IllegalArgumentException if the designated output size is invalid. * @see #HAVAL_128_BIT @@ -125,7 +125,7 @@ public class Haval * <code>20</code>, <code>24</code>, <code>28</code> and * <code>32</code>. Valid values for <code>rounds</code> are in the range * <code>3..5</code> inclusive. - * + * * @param size the output size in bytes of this instance. * @param rounds the number of rounds to apply when transforming data. * @throws IllegalArgumentException if the designated output size is invalid, @@ -160,7 +160,7 @@ public class Haval /** * Private constructor for cloning purposes. - * + * * @param md the instance to clone. */ private Haval(Haval md) diff --git a/libjava/classpath/gnu/java/security/hash/IMessageDigest.java b/libjava/classpath/gnu/java/security/hash/IMessageDigest.java index 2c5bdd41a57..9b716e5965f 100644 --- a/libjava/classpath/gnu/java/security/hash/IMessageDigest.java +++ b/libjava/classpath/gnu/java/security/hash/IMessageDigest.java @@ -1,4 +1,4 @@ -/* IMessageDigest.java -- +/* IMessageDigest.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -49,28 +49,28 @@ public interface IMessageDigest { /** * Returns the canonical name of this algorithm. - * + * * @return the canonical name of this instance. */ String name(); /** * Returns the output length in bytes of this message digest algorithm. - * + * * @return the output length in bytes of this message digest algorithm. */ int hashSize(); /** * Returns the algorithm's (inner) block size in bytes. - * + * * @return the algorithm's inner block size in bytes. */ int blockSize(); /** * Continues a message digest operation using the input byte. - * + * * @param b the input byte to digest. */ void update(byte b); @@ -79,7 +79,7 @@ public interface IMessageDigest * Continues a message digest operation, by filling the buffer, processing * data in the algorithm's HASH_SIZE-bit block(s), updating the context and * count, and buffering the remaining bytes in buffer for the next operation. - * + * * @param in the input block. */ void update(byte[] in); @@ -88,7 +88,7 @@ public interface IMessageDigest * Continues a message digest operation, by filling the buffer, processing * data in the algorithm's HASH_SIZE-bit block(s), updating the context and * count, and buffering the remaining bytes in buffer for the next operation. - * + * * @param in the input block. * @param offset start of meaningful bytes in input block. * @param length number of bytes, in input block, to consider. @@ -98,7 +98,7 @@ public interface IMessageDigest /** * Completes the message digest by performing final operations such as padding * and resetting the instance. - * + * * @return the array of bytes representing the hash value. */ byte[] digest(); @@ -112,7 +112,7 @@ public interface IMessageDigest /** * A basic test. Ensures that the digest of a pre-determined message is equal * to a known pre-computed value. - * + * * @return <code>true</code> if the implementation passes a basic self-test. * Returns <code>false</code> otherwise. */ @@ -120,7 +120,7 @@ public interface IMessageDigest /** * Returns a clone copy of this instance. - * + * * @return a clone copy of this instance. */ Object clone(); diff --git a/libjava/classpath/gnu/java/security/hash/MD2.java b/libjava/classpath/gnu/java/security/hash/MD2.java index 8f6b265b037..d78af93fabd 100644 --- a/libjava/classpath/gnu/java/security/hash/MD2.java +++ b/libjava/classpath/gnu/java/security/hash/MD2.java @@ -1,4 +1,4 @@ -/* MD2.java -- +/* MD2.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/MD4.java b/libjava/classpath/gnu/java/security/hash/MD4.java index dfc1c6bd69f..e6ac11bc8a7 100644 --- a/libjava/classpath/gnu/java/security/hash/MD4.java +++ b/libjava/classpath/gnu/java/security/hash/MD4.java @@ -1,4 +1,4 @@ -/* MD4.java -- +/* MD4.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/MD5.java b/libjava/classpath/gnu/java/security/hash/MD5.java index 653078512d5..dfffd3c8073 100644 --- a/libjava/classpath/gnu/java/security/hash/MD5.java +++ b/libjava/classpath/gnu/java/security/hash/MD5.java @@ -1,4 +1,4 @@ -/* MD5.java -- +/* MD5.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/RipeMD128.java b/libjava/classpath/gnu/java/security/hash/RipeMD128.java index 62f5a05e5bf..bd0adc5e094 100644 --- a/libjava/classpath/gnu/java/security/hash/RipeMD128.java +++ b/libjava/classpath/gnu/java/security/hash/RipeMD128.java @@ -1,4 +1,4 @@ -/* RipeMD128.java -- +/* RipeMD128.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/RipeMD160.java b/libjava/classpath/gnu/java/security/hash/RipeMD160.java index 7949bc2547c..795f5a4b0cf 100644 --- a/libjava/classpath/gnu/java/security/hash/RipeMD160.java +++ b/libjava/classpath/gnu/java/security/hash/RipeMD160.java @@ -1,4 +1,4 @@ -/* RipeMD160.java -- +/* RipeMD160.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/Sha160.java b/libjava/classpath/gnu/java/security/hash/Sha160.java index 6adeba07079..88bf0e40542 100644 --- a/libjava/classpath/gnu/java/security/hash/Sha160.java +++ b/libjava/classpath/gnu/java/security/hash/Sha160.java @@ -1,4 +1,4 @@ -/* Sha160.java -- +/* Sha160.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/Sha256.java b/libjava/classpath/gnu/java/security/hash/Sha256.java index 536b1c8bab3..76e28d4e02e 100644 --- a/libjava/classpath/gnu/java/security/hash/Sha256.java +++ b/libjava/classpath/gnu/java/security/hash/Sha256.java @@ -1,4 +1,4 @@ -/* Sha256.java -- +/* Sha256.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/Sha384.java b/libjava/classpath/gnu/java/security/hash/Sha384.java index a47eb67db95..5fea4f3b1e6 100644 --- a/libjava/classpath/gnu/java/security/hash/Sha384.java +++ b/libjava/classpath/gnu/java/security/hash/Sha384.java @@ -1,4 +1,4 @@ -/* Sha384.java -- +/* Sha384.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/Sha512.java b/libjava/classpath/gnu/java/security/hash/Sha512.java index e6f553ed40a..17c4323fad5 100644 --- a/libjava/classpath/gnu/java/security/hash/Sha512.java +++ b/libjava/classpath/gnu/java/security/hash/Sha512.java @@ -1,4 +1,4 @@ -/* Sha512.java -- +/* Sha512.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/Tiger.java b/libjava/classpath/gnu/java/security/hash/Tiger.java index 101df39efe9..d2993db9faf 100644 --- a/libjava/classpath/gnu/java/security/hash/Tiger.java +++ b/libjava/classpath/gnu/java/security/hash/Tiger.java @@ -1,4 +1,4 @@ -/* Tiger.java -- +/* Tiger.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/hash/Whirlpool.java b/libjava/classpath/gnu/java/security/hash/Whirlpool.java index aebe1acb699..574104074bb 100644 --- a/libjava/classpath/gnu/java/security/hash/Whirlpool.java +++ b/libjava/classpath/gnu/java/security/hash/Whirlpool.java @@ -1,4 +1,4 @@ -/* Whirlpool.java -- +/* Whirlpool.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -548,7 +548,7 @@ public final class Whirlpool // so far. hence the minimal number of bytes added to the message proper // are 33 (1 for the 1-bit followed by the 0-bits and the encoding of // the count framed in a 256-bit block). our formula is then: - // count + 33 + padding = 0 (mod BLOCK_SIZE) + // count + 33 + padding = 0 (mod BLOCK_SIZE) int n = (int)((count + 33) % BLOCK_SIZE); int padding = n == 0 ? 33 : BLOCK_SIZE - n + 33; byte[] result = new byte[padding]; diff --git a/libjava/classpath/gnu/java/security/jce/hash/HavalSpi.java b/libjava/classpath/gnu/java/security/jce/hash/HavalSpi.java index 159ba3dd8ff..7c0a6027b4e 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/HavalSpi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/HavalSpi.java @@ -1,4 +1,4 @@ -/* HavalSpi.java -- +/* HavalSpi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/MD2Spi.java b/libjava/classpath/gnu/java/security/jce/hash/MD2Spi.java index 268f2fa6941..76def7acb8b 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/MD2Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/MD2Spi.java @@ -1,4 +1,4 @@ -/* MD2Spi.java -- +/* MD2Spi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/MD4Spi.java b/libjava/classpath/gnu/java/security/jce/hash/MD4Spi.java index c050ef2df7f..125943d3088 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/MD4Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/MD4Spi.java @@ -1,4 +1,4 @@ -/* MD4Spi.java -- +/* MD4Spi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/MD5Spi.java b/libjava/classpath/gnu/java/security/jce/hash/MD5Spi.java index 6297416940e..25d9240b42e 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/MD5Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/MD5Spi.java @@ -1,4 +1,4 @@ -/* MD5Spi.java -- +/* MD5Spi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/MessageDigestAdapter.java b/libjava/classpath/gnu/java/security/jce/hash/MessageDigestAdapter.java index 7342ee55123..2651ecf92cb 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/MessageDigestAdapter.java +++ b/libjava/classpath/gnu/java/security/jce/hash/MessageDigestAdapter.java @@ -1,4 +1,4 @@ -/* MessageDigestAdapter.java -- +/* MessageDigestAdapter.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -69,7 +69,7 @@ class MessageDigestAdapter /** * Trivial protected constructor. - * + * * @param mdName the canonical name of the hash algorithm. */ protected MessageDigestAdapter(String mdName) @@ -79,7 +79,7 @@ class MessageDigestAdapter /** * Private constructor for cloning purposes. - * + * * @param adaptee a clone of the underlying hash algorithm instance. */ private MessageDigestAdapter(IMessageDigest adaptee) diff --git a/libjava/classpath/gnu/java/security/jce/hash/RipeMD128Spi.java b/libjava/classpath/gnu/java/security/jce/hash/RipeMD128Spi.java index 159a1173c15..499996c02fa 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/RipeMD128Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/RipeMD128Spi.java @@ -1,4 +1,4 @@ -/* RipeMD128Spi.java -- +/* RipeMD128Spi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/RipeMD160Spi.java b/libjava/classpath/gnu/java/security/jce/hash/RipeMD160Spi.java index 579ccb26f14..a62bea6c0f5 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/RipeMD160Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/RipeMD160Spi.java @@ -1,4 +1,4 @@ -/* RipeMD160Spi.java -- +/* RipeMD160Spi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/Sha160Spi.java b/libjava/classpath/gnu/java/security/jce/hash/Sha160Spi.java index 901cac19158..ea2dfe24c01 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/Sha160Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/Sha160Spi.java @@ -1,4 +1,4 @@ -/* Sha160Spi.java -- +/* Sha160Spi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/Sha256Spi.java b/libjava/classpath/gnu/java/security/jce/hash/Sha256Spi.java index 9d471e65a66..39d31d07b82 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/Sha256Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/Sha256Spi.java @@ -1,4 +1,4 @@ -/* Sha256Spi.java -- +/* Sha256Spi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/Sha384Spi.java b/libjava/classpath/gnu/java/security/jce/hash/Sha384Spi.java index 30d5fce09bc..fa1e3f94834 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/Sha384Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/Sha384Spi.java @@ -1,4 +1,4 @@ -/* Sha384Spi.java -- +/* Sha384Spi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/Sha512Spi.java b/libjava/classpath/gnu/java/security/jce/hash/Sha512Spi.java index a2d44ab2461..4bd39daedc2 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/Sha512Spi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/Sha512Spi.java @@ -1,4 +1,4 @@ -/* Sha512Spi.java -- +/* Sha512Spi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/TigerSpi.java b/libjava/classpath/gnu/java/security/jce/hash/TigerSpi.java index a21e5fe1081..3d38c847f63 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/TigerSpi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/TigerSpi.java @@ -1,4 +1,4 @@ -/* TigerSpi.java -- +/* TigerSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/hash/WhirlpoolSpi.java b/libjava/classpath/gnu/java/security/jce/hash/WhirlpoolSpi.java index d7a7a4504d4..68a3a705987 100644 --- a/libjava/classpath/gnu/java/security/jce/hash/WhirlpoolSpi.java +++ b/libjava/classpath/gnu/java/security/jce/hash/WhirlpoolSpi.java @@ -1,4 +1,4 @@ -/* WhirlpoolSpi.java -- +/* WhirlpoolSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/HavalRandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/HavalRandomSpi.java index c3d4b941261..ebf80f2d702 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/HavalRandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/HavalRandomSpi.java @@ -1,4 +1,4 @@ -/* HavalRandomSpi.java -- +/* HavalRandomSpi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/MD2RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/MD2RandomSpi.java index 8ba286804e6..8b9abe4e96f 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/MD2RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/MD2RandomSpi.java @@ -1,4 +1,4 @@ -/* MD2RandomSpi.java -- +/* MD2RandomSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/MD4RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/MD4RandomSpi.java index d4d182970c7..2a71d6a0d27 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/MD4RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/MD4RandomSpi.java @@ -1,4 +1,4 @@ -/* MD4RandomSpi.java -- +/* MD4RandomSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/MD5RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/MD5RandomSpi.java index be38add0a0d..8fb50e16fe5 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/MD5RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/MD5RandomSpi.java @@ -1,4 +1,4 @@ -/* MD5RandomSpi.java -- +/* MD5RandomSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/RipeMD128RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/RipeMD128RandomSpi.java index 530c3ec2141..6f8dde0e062 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/RipeMD128RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/RipeMD128RandomSpi.java @@ -1,4 +1,4 @@ -/* RipeMD128RandomSpi.java -- +/* RipeMD128RandomSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/RipeMD160RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/RipeMD160RandomSpi.java index 6875cdfa91a..6bb4e2b50c4 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/RipeMD160RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/RipeMD160RandomSpi.java @@ -1,4 +1,4 @@ -/* RipeMD160RandomSpi.java -- +/* RipeMD160RandomSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/SecureRandomAdapter.java b/libjava/classpath/gnu/java/security/jce/prng/SecureRandomAdapter.java index 5877e3edb6c..9307cfa7fb4 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/SecureRandomAdapter.java +++ b/libjava/classpath/gnu/java/security/jce/prng/SecureRandomAdapter.java @@ -1,4 +1,4 @@ -/* SecureRandomAdapter.java -- +/* SecureRandomAdapter.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -68,7 +68,7 @@ import java.net.URL; * <p>All the abstract methods in the {@link SecureRandomSpi} class are * implemented by this class and all its sub-classes.</p> */ -public abstract class SecureRandomAdapter +public abstract class SecureRandomAdapter extends SecureRandomSpi { @@ -100,7 +100,7 @@ public abstract class SecureRandomAdapter } public static final byte[] getSeed(int numBytes) - { + { URL sourceUrl = null; String urlStr = null; @@ -117,7 +117,7 @@ public abstract class SecureRandomAdapter catch (MalformedURLException ignored) { logger.log(Level.WARNING, - SECURERANDOM_SOURCE + " property is malformed: {0}", + SECURERANDOM_SOURCE + " property is malformed: {0}", urlStr); } @@ -132,7 +132,7 @@ public abstract class SecureRandomAdapter catch (MalformedURLException mue) { logger.log(Level.WARNING, - JAVA_SECURITY_EGD + " property is malformed: {0}", + JAVA_SECURITY_EGD + " property is malformed: {0}", urlStr); } } diff --git a/libjava/classpath/gnu/java/security/jce/prng/Sha160RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/Sha160RandomSpi.java index 9fded67e0ce..ba4d222658d 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/Sha160RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/Sha160RandomSpi.java @@ -1,4 +1,4 @@ -/* Sha160RandomSpi.java -- +/* Sha160RandomSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/Sha256RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/Sha256RandomSpi.java index e3999ffe6e9..a6ddb70afc0 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/Sha256RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/Sha256RandomSpi.java @@ -1,4 +1,4 @@ -/* Sha256RandomSpi.java -- +/* Sha256RandomSpi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/Sha384RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/Sha384RandomSpi.java index 978c8fe38b2..4954b1be7e2 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/Sha384RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/Sha384RandomSpi.java @@ -1,4 +1,4 @@ -/* Sha384RandomSpi.java -- +/* Sha384RandomSpi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/Sha512RandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/Sha512RandomSpi.java index a89e26f004e..27de7f31991 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/Sha512RandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/Sha512RandomSpi.java @@ -1,4 +1,4 @@ -/* Sha512RandomSpi.java -- +/* Sha512RandomSpi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/TigerRandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/TigerRandomSpi.java index ba4b22fb892..722ab327921 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/TigerRandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/TigerRandomSpi.java @@ -1,4 +1,4 @@ -/* TigerRandomSpi.java -- +/* TigerRandomSpi.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/prng/WhirlpoolRandomSpi.java b/libjava/classpath/gnu/java/security/jce/prng/WhirlpoolRandomSpi.java index 9d937e65f3e..5da43d77ef1 100644 --- a/libjava/classpath/gnu/java/security/jce/prng/WhirlpoolRandomSpi.java +++ b/libjava/classpath/gnu/java/security/jce/prng/WhirlpoolRandomSpi.java @@ -1,4 +1,4 @@ -/* WhirlpoolRandomSpi.java -- +/* WhirlpoolRandomSpi.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/sig/DSSKeyFactory.java b/libjava/classpath/gnu/java/security/jce/sig/DSSKeyFactory.java index 7b57dba70a5..ec993432ce0 100644 --- a/libjava/classpath/gnu/java/security/jce/sig/DSSKeyFactory.java +++ b/libjava/classpath/gnu/java/security/jce/sig/DSSKeyFactory.java @@ -61,7 +61,7 @@ import java.security.spec.X509EncodedKeySpec; /** * DSA key factory. - * + * * @author Casey Marshall (rsdio@metastatic.org) */ public class DSSKeyFactory diff --git a/libjava/classpath/gnu/java/security/jce/sig/DSSKeyPairGeneratorSpi.java b/libjava/classpath/gnu/java/security/jce/sig/DSSKeyPairGeneratorSpi.java index c4453810653..2d33e16217c 100644 --- a/libjava/classpath/gnu/java/security/jce/sig/DSSKeyPairGeneratorSpi.java +++ b/libjava/classpath/gnu/java/security/jce/sig/DSSKeyPairGeneratorSpi.java @@ -1,4 +1,4 @@ -/* DSSKeyPairGeneratorSpi.java -- +/* DSSKeyPairGeneratorSpi.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/sig/DSSParameters.java b/libjava/classpath/gnu/java/security/jce/sig/DSSParameters.java index 8a1cb4ca502..fbf778dae89 100644 --- a/libjava/classpath/gnu/java/security/jce/sig/DSSParameters.java +++ b/libjava/classpath/gnu/java/security/jce/sig/DSSParameters.java @@ -99,8 +99,8 @@ public class DSSParameters /** * Decodes the set of DSS parameters as per RFC-2459; i.e. the DER-encoded - * form of the following ASN.1 construct: - * + * form of the following ASN.1 construct: + * * <pre> * DssParams ::= SEQUENCE { * p INTEGER, @@ -152,8 +152,8 @@ public class DSSParameters /** * Encodes the set of DSS parameters as per RFC-2459; i.e. as the DER-encoded - * form of the following ASN.1 construct: - * + * form of the following ASN.1 construct: + * * <pre> * DssParams ::= SEQUENCE { * p INTEGER, diff --git a/libjava/classpath/gnu/java/security/jce/sig/DSSRawSignatureSpi.java b/libjava/classpath/gnu/java/security/jce/sig/DSSRawSignatureSpi.java index 9b20c03b110..edee4e577e6 100644 --- a/libjava/classpath/gnu/java/security/jce/sig/DSSRawSignatureSpi.java +++ b/libjava/classpath/gnu/java/security/jce/sig/DSSRawSignatureSpi.java @@ -1,4 +1,4 @@ -/* DSSRawSignatureSpi.java -- +/* DSSRawSignatureSpi.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/sig/KeyPairGeneratorAdapter.java b/libjava/classpath/gnu/java/security/jce/sig/KeyPairGeneratorAdapter.java index bcbbe477d1e..9d3e5efdd02 100644 --- a/libjava/classpath/gnu/java/security/jce/sig/KeyPairGeneratorAdapter.java +++ b/libjava/classpath/gnu/java/security/jce/sig/KeyPairGeneratorAdapter.java @@ -1,4 +1,4 @@ -/* KeyPairGeneratorAdapter.java -- +/* KeyPairGeneratorAdapter.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -72,7 +72,7 @@ public abstract class KeyPairGeneratorAdapter /** * Trivial protected constructor. - * + * * @param kpgName the canonical name of the keypair generator algorithm. */ protected KeyPairGeneratorAdapter(String kpgName) diff --git a/libjava/classpath/gnu/java/security/jce/sig/RSAPSSRawSignatureSpi.java b/libjava/classpath/gnu/java/security/jce/sig/RSAPSSRawSignatureSpi.java index f1ccbde4dc2..496c9caa6f4 100644 --- a/libjava/classpath/gnu/java/security/jce/sig/RSAPSSRawSignatureSpi.java +++ b/libjava/classpath/gnu/java/security/jce/sig/RSAPSSRawSignatureSpi.java @@ -1,4 +1,4 @@ -/* RSAPSSRawSignatureSpi.java -- +/* RSAPSSRawSignatureSpi.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/jce/sig/SignatureAdapter.java b/libjava/classpath/gnu/java/security/jce/sig/SignatureAdapter.java index a65d727eed3..0ed1e2f41fd 100644 --- a/libjava/classpath/gnu/java/security/jce/sig/SignatureAdapter.java +++ b/libjava/classpath/gnu/java/security/jce/sig/SignatureAdapter.java @@ -1,4 +1,4 @@ -/* SignatureAdapter.java -- +/* SignatureAdapter.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -85,7 +85,7 @@ class SignatureAdapter /** * Trivial protected constructor. - * + * * @param sigName the canonical name of the signature scheme. * @param codec the signature codec engine to use with this scheme. */ @@ -96,7 +96,7 @@ class SignatureAdapter /** * Private constructor for cloning purposes. - * + * * @param adaptee a clone of the underlying signature scheme instance. * @param codec the signature codec engine to use with this scheme. */ diff --git a/libjava/classpath/gnu/java/security/key/IKeyPairCodec.java b/libjava/classpath/gnu/java/security/key/IKeyPairCodec.java index f09743d2b60..5c88c86ca1f 100644 --- a/libjava/classpath/gnu/java/security/key/IKeyPairCodec.java +++ b/libjava/classpath/gnu/java/security/key/IKeyPairCodec.java @@ -1,4 +1,4 @@ -/* IKeyPairCodec.java -- +/* IKeyPairCodec.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -69,14 +69,14 @@ public interface IKeyPairCodec /** * Returns the unique identifier (within this library) of the format used to * externalise public and private keys. - * + * * @return the identifier of the format, the object supports. */ int getFormatID(); /** * Encodes an instance of a public key for storage or transmission purposes. - * + * * @param key the non-null key to encode. * @return a byte sequence representing the encoding of the designated key * according to the format supported by this codec. @@ -87,7 +87,7 @@ public interface IKeyPairCodec /** * Encodes an instance of a private key for storage or transmission purposes. - * + * * @param key the non-null key to encode. * @return a byte sequence representing the encoding of the designated key * according to the format supported by this codec. @@ -99,7 +99,7 @@ public interface IKeyPairCodec /** * Decodes an instance of an external public key into its native Java * representation. - * + * * @param input the source of the externalised key to decode. * @return a concrete instance of a public key, reconstructed from the * designated input. @@ -112,7 +112,7 @@ public interface IKeyPairCodec /** * Decodes an instance of an external private key into its native Java * representation. - * + * * @param input the source of the externalised key to decode. * @return a concrete instance of a private key, reconstructed from the * designated input. diff --git a/libjava/classpath/gnu/java/security/key/IKeyPairGenerator.java b/libjava/classpath/gnu/java/security/key/IKeyPairGenerator.java index 8d7842e935f..72aac2463aa 100644 --- a/libjava/classpath/gnu/java/security/key/IKeyPairGenerator.java +++ b/libjava/classpath/gnu/java/security/key/IKeyPairGenerator.java @@ -1,4 +1,4 @@ -/* IKeyPairGenerator.java -- +/* IKeyPairGenerator.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -48,14 +48,14 @@ public interface IKeyPairGenerator { /** * Returns the canonical name of this keypair generator. - * + * * @return the canonical name of this instance. */ String name(); /** * [Re]-initialises this instance for use with a given set of attributes. - * + * * @param attributes a map of name/value pairs to use for setting up the * instance. * @exception IllegalArgumentException if at least one of the mandatory @@ -66,7 +66,7 @@ public interface IKeyPairGenerator /** * Generates a new keypair based on the attributes used to configure the * instance. - * + * * @return a new keypair. */ KeyPair generate(); diff --git a/libjava/classpath/gnu/java/security/key/KeyPairCodecFactory.java b/libjava/classpath/gnu/java/security/key/KeyPairCodecFactory.java index e68a7d65c3a..d428664235f 100644 --- a/libjava/classpath/gnu/java/security/key/KeyPairCodecFactory.java +++ b/libjava/classpath/gnu/java/security/key/KeyPairCodecFactory.java @@ -1,4 +1,4 @@ -/* KeyPairCodecFactory.java -- +/* KeyPairCodecFactory.java -- Copyright 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -79,7 +79,7 @@ public class KeyPairCodecFactory * <b>IMPORTANT</b>: For backward compatibility, when the encoding format * name is missing, the Raw encoding format is assumed. When this is the case * the trailing forward slash is discarded from the name. - * + * * @param name the case-insensitive key codec name. * @return an instance of the keypair codec, or <code>null</code> if none * found. @@ -113,7 +113,7 @@ public class KeyPairCodecFactory * Returns an instance of a keypair codec given the canonical name of the * key-pair algorithm, and the name of the encoding format to use when * externalizing the keys. - * + * * @param name the case-insensitive key-pair algorithm name. * @param format the name of the encoding format to use when externalizing the * keys generated by the key-pair algorithm. @@ -133,7 +133,7 @@ public class KeyPairCodecFactory * Returns an instance of a keypair codec given the canonical name of the * key-pair algorithm, and the identifier of the format to use when * externalizing the keys. - * + * * @param name the case-insensitive key-pair algorithm name. * @param formatID the identifier of the format to use when externalizing the * keys generated by the key-pair algorithm. @@ -161,7 +161,7 @@ public class KeyPairCodecFactory /** * Returns an instance of a keypair codec given a key. - * + * * @param key the key to encode. * @return an instance of the keypair codec, or <code>null</code> if none * found. diff --git a/libjava/classpath/gnu/java/security/key/KeyPairGeneratorFactory.java b/libjava/classpath/gnu/java/security/key/KeyPairGeneratorFactory.java index 4872fc3d1a1..151cace3912 100644 --- a/libjava/classpath/gnu/java/security/key/KeyPairGeneratorFactory.java +++ b/libjava/classpath/gnu/java/security/key/KeyPairGeneratorFactory.java @@ -1,4 +1,4 @@ -/* KeyPairGeneratorFactory.java -- +/* KeyPairGeneratorFactory.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -60,7 +60,7 @@ public class KeyPairGeneratorFactory /** * Returns an instance of a keypair generator given its name. - * + * * @param name the case-insensitive key generator name. * @return an instance of the keypair generator, or <code>null</code> if * none found. @@ -89,7 +89,7 @@ public class KeyPairGeneratorFactory * Returns a {@link Set} of keypair generator names supported by this * <i>Factory</i>. Those keypair generators may be used in conjunction with * the digital signature schemes with appendix supported by this library. - * + * * @return a {@link Set} of keypair generator names (Strings). */ public static final Set getNames() diff --git a/libjava/classpath/gnu/java/security/key/dss/DSSKey.java b/libjava/classpath/gnu/java/security/key/dss/DSSKey.java index d4cf36513eb..49f229f7b2b 100644 --- a/libjava/classpath/gnu/java/security/key/dss/DSSKey.java +++ b/libjava/classpath/gnu/java/security/key/dss/DSSKey.java @@ -1,4 +1,4 @@ -/* DSSKey.java -- +/* DSSKey.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -66,7 +66,7 @@ import java.security.spec.DSAParameterSpec; * <b>IMPORTANT</b>: Under certain circumstances (e.g. in an X.509 certificate * with inherited AlgorithmIdentifier's parameters of a SubjectPublicKeyInfo * element) these three MPIs may be <code>null</code>. - * + * * @see DSSPrivateKey#getEncoded * @see DSSPublicKey#getEncoded */ @@ -108,7 +108,7 @@ public abstract class DSSKey /** * Trivial protected constructor. - * + * * @param defaultFormat the identifier of the encoding format to use by * default when externalizing the key. * @param p the DSS parameter <code>p</code>. @@ -156,7 +156,7 @@ public abstract class DSSKey * <i>inherited</i>. This may be the case when the key is re-constructed from * an X.509 certificate with absent or NULL AlgorithmIdentifier's parameters * field. - * + * * @param obj the other non-null DSS key to compare to. * @return <code>true</code> if the designated object is of the same type * and value as this one. diff --git a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairGenerator.java b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairGenerator.java index 1bad0b62ed6..6bda4e88e34 100644 --- a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairGenerator.java +++ b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairGenerator.java @@ -1,4 +1,4 @@ -/* DSSKeyPairGenerator.java -- +/* DSSKeyPairGenerator.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -217,7 +217,7 @@ public class DSSKeyPairGenerator /** * Configures this instance. - * + * * @param attributes the map of name/value pairs to use. * @exception IllegalArgumentException if the designated MODULUS_LENGTH value * is not greater than 512, less than 1024 and not of the form @@ -361,7 +361,7 @@ public class DSSKeyPairGenerator /** * Fills the designated byte array with random data. - * + * * @param buffer the byte array to fill with random data. */ private void nextRandomBytes(byte[] buffer) diff --git a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairPKCS8Codec.java b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairPKCS8Codec.java index 06b8e849a50..a59ca3cee7a 100644 --- a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairPKCS8Codec.java +++ b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairPKCS8Codec.java @@ -88,7 +88,7 @@ public class DSSKeyPairPKCS8Codec /** * Returns the PKCS#8 ASN.1 <i>PrivateKeyInfo</i> representation of a DSA * private key. The ASN.1 specification is as follows: - * + * * <pre> * PrivateKeyInfo ::= SEQUENCE { * version INTEGER, -- MUST be 0 @@ -107,7 +107,7 @@ public class DSSKeyPairPKCS8Codec * g INTEGER * } * </pre> - * + * * @return the DER encoded form of the ASN.1 representation of the * <i>PrivateKeyInfo</i> field in an X.509 certificate. * @throw InvalidParameterException if an error occurs during the marshalling diff --git a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairRawCodec.java b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairRawCodec.java index b1135b75f1f..5b93c6b1e93 100644 --- a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairRawCodec.java +++ b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairRawCodec.java @@ -1,4 +1,4 @@ -/* DSSKeyPairRawCodec.java -- +/* DSSKeyPairRawCodec.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -92,7 +92,7 @@ public class DSSKeyPairRawCodec * the <code>toByteArray()</code> method on the DSA parameter <code>y</code>, * </li> * </ol> - * + * * @param key the key to encode. * @return the <i>Raw</i> format encoding of the designated key. * @throws IllegalArgumentException if the designated key is not a DSS @@ -235,7 +235,7 @@ public class DSSKeyPairRawCodec * the <code>toByteArray()</code> method on the DSA parameter <code>x</code>, * </li> * </ol> - * + * * @param key the key to encode. * @return the <i>Raw</i> format encoding of the designated key. * @throws IllegalArgumentException if the designated key is not a DSS diff --git a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairX509Codec.java b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairX509Codec.java index a5e8e9d47eb..8c26910f129 100644 --- a/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairX509Codec.java +++ b/libjava/classpath/gnu/java/security/key/dss/DSSKeyPairX509Codec.java @@ -103,11 +103,11 @@ public class DSSKeyPairX509Codec * <p> * The <i>subjectPublicKey</i> field, which is a BIT STRING, contains the * DER-encoded form of the DSA public key as an INTEGER. - * + * * <pre> * DSAPublicKey ::= INTEGER -- public key, Y * </pre> - * + * * @param key the {@link PublicKey} instance to encode. MUST be an instance of * {@link DSSPublicKey}. * @return the ASN.1 representation of the <i>SubjectPublicKeyInfo</i> in an diff --git a/libjava/classpath/gnu/java/security/key/dss/DSSPrivateKey.java b/libjava/classpath/gnu/java/security/key/dss/DSSPrivateKey.java index 633fcf7ce08..de3668c0131 100644 --- a/libjava/classpath/gnu/java/security/key/dss/DSSPrivateKey.java +++ b/libjava/classpath/gnu/java/security/key/dss/DSSPrivateKey.java @@ -1,4 +1,4 @@ -/* DSSPrivateKey.java -- +/* DSSPrivateKey.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -52,7 +52,7 @@ import java.security.interfaces.DSAPrivateKey; /** * An object that embodies a DSS (Digital Signature Standard) private key. - * + * * @see #getEncoded */ public class DSSPrivateKey @@ -72,7 +72,7 @@ public class DSSPrivateKey * Convenience constructor. Calls the constructor with 5 arguments passing * {@link Registry#RAW_ENCODING_ID} as the identifier of the preferred * encoding format. - * + * * @param p the public modulus. * @param q the public prime divisor of <code>p-1</code>. * @param g a generator of the unique cyclic group <code>Z<sup>*</sup> @@ -87,7 +87,7 @@ public class DSSPrivateKey /** * Constructs a new instance of a <code>DSSPrivateKey</code> given the * designated arguments. - * + * * @param preferredFormat the indetifier of the preferred encoding format to * use when externalizing this key. * @param p the public modulus. @@ -110,7 +110,7 @@ public class DSSPrivateKey * method of a DSS keypair codec object (an instance implementing * {@link gnu.java.security.key.IKeyPairCodec} for DSS keys, and re-constructs * an instance of this object. - * + * * @param k the contents of a previously encoded instance of this object. * @exception ArrayIndexOutOfBoundsException if there is not enough bytes, in * <code>k</code>, to represent a valid encoding of an @@ -141,7 +141,7 @@ public class DSSPrivateKey /** * Returns the encoded form of this private key according to the designated * format. - * + * * @param format the desired format identifier of the resulting encoding. * @return the byte sequence encoding this key according to the designated * format. @@ -170,7 +170,7 @@ public class DSSPrivateKey * Returns <code>true</code> if the designated object is an instance of * {@link DSAPrivateKey} and has the same DSS (Digital Signature Standard) * parameter values as this one. - * + * * @param obj the other non-null DSS key to compare to. * @return <code>true</code> if the designated object is of the same type * and value as this one. diff --git a/libjava/classpath/gnu/java/security/key/dss/DSSPublicKey.java b/libjava/classpath/gnu/java/security/key/dss/DSSPublicKey.java index e5c53467176..d7c1afe1517 100644 --- a/libjava/classpath/gnu/java/security/key/dss/DSSPublicKey.java +++ b/libjava/classpath/gnu/java/security/key/dss/DSSPublicKey.java @@ -1,4 +1,4 @@ -/* DSSPublicKey.java -- +/* DSSPublicKey.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -51,7 +51,7 @@ import java.security.interfaces.DSAPublicKey; /** * An object that embodies a DSS (Digital Signature Standard) public key. - * + * * @see #getEncoded */ public class DSSPublicKey @@ -71,7 +71,7 @@ public class DSSPublicKey * Conveience constructor. Calls the constructor with 5 arguments passing * {@link Registry#RAW_ENCODING_ID} as the identifier of the preferred * encoding format. - * + * * @param p the public modulus. * @param q the public prime divisor of <code>p-1</code>. * @param g a generator of the unique cyclic group <code>Z<sup>*</sup> @@ -86,7 +86,7 @@ public class DSSPublicKey /** * Constructs a new instance of <code>DSSPublicKey</code> given the * designated arguments. - * + * * @param preferredFormat the identifier of the preferred encoding format to * use when externalizing this key. * @param p the public modulus. @@ -109,7 +109,7 @@ public class DSSPublicKey * method of a DSS keypair codec object (an instance implementing * {@link gnu.java.security.key.IKeyPairCodec} for DSS keys, and re-constructs * an instance of this object. - * + * * @param k the contents of a previously encoded instance of this object. * @exception ArrayIndexOutOfBoundsException if there is not enough bytes, in * <code>k</code>, to represent a valid encoding of an @@ -140,7 +140,7 @@ public class DSSPublicKey /** * Returns the encoded form of this public key according to the designated * format. - * + * * @param format the desired format identifier of the resulting encoding. * @return the byte sequence encoding this key according to the designated * format. @@ -169,7 +169,7 @@ public class DSSPublicKey * Returns <code>true</code> if the designated object is an instance of * {@link DSAPublicKey} and has the same DSS (Digital Signature Standard) * parameter values as this one. - * + * * @param obj the other non-null DSS key to compare to. * @return <code>true</code> if the designated object is of the same type * and value as this one. diff --git a/libjava/classpath/gnu/java/security/key/dss/FIPS186.java b/libjava/classpath/gnu/java/security/key/dss/FIPS186.java index 65dc5800c77..5d371e10cfd 100644 --- a/libjava/classpath/gnu/java/security/key/dss/FIPS186.java +++ b/libjava/classpath/gnu/java/security/key/dss/FIPS186.java @@ -1,4 +1,4 @@ -/* FIPS186.java -- +/* FIPS186.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -241,7 +241,7 @@ public class FIPS186 /** * Fills the designated byte array with random data. - * + * * @param buffer the byte array to fill with random data. */ private void nextRandomBytes(byte[] buffer) diff --git a/libjava/classpath/gnu/java/security/key/rsa/GnuRSAKey.java b/libjava/classpath/gnu/java/security/key/rsa/GnuRSAKey.java index 0419ac96ee4..38530ee4c85 100644 --- a/libjava/classpath/gnu/java/security/key/rsa/GnuRSAKey.java +++ b/libjava/classpath/gnu/java/security/key/rsa/GnuRSAKey.java @@ -1,4 +1,4 @@ -/* GnuRSAKey.java -- +/* GnuRSAKey.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -72,7 +72,7 @@ public abstract class GnuRSAKey /** * Trivial protected constructor. - * + * * @param defaultFormat the identifier of the encoding format to use by * default when externalizing the key. * @param n the public modulus <code>n</code>. @@ -111,7 +111,7 @@ public abstract class GnuRSAKey /** * Returns the modulus <code>n</code>. - * + * * @return the modulus <code>n</code>. */ public BigInteger getN() @@ -121,7 +121,7 @@ public abstract class GnuRSAKey /** * Returns the public exponent <code>e</code>. - * + * * @return the public exponent <code>e</code>. */ public BigInteger getPublicExponent() @@ -131,7 +131,7 @@ public abstract class GnuRSAKey /** * Same as {@link #getPublicExponent()}. - * + * * @return the public exponent <code>e</code>. */ public BigInteger getE() @@ -142,7 +142,7 @@ public abstract class GnuRSAKey /** * Returns <code>true</code> if the designated object is an instance of * {@link RSAKey} and has the same RSA parameter values as this one. - * + * * @param obj the other non-null RSA key to compare to. * @return <code>true</code> if the designated object is of the same type * and value as this one. diff --git a/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPrivateKey.java b/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPrivateKey.java index e554f2f3f02..39f91cbe463 100644 --- a/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPrivateKey.java +++ b/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPrivateKey.java @@ -1,4 +1,4 @@ -/* GnuRSAPrivateKey.java -- +/* GnuRSAPrivateKey.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -92,7 +92,7 @@ public class GnuRSAPrivateKey * Convenience constructor. Calls the constructor with 5 arguments passing * {@link Registry#RAW_ENCODING_ID} as the identifier of the preferred * encoding format. - * + * * @param p the modulus first prime divisor. * @param q the modulus second prime divisor. * @param e the public exponent. @@ -106,7 +106,7 @@ public class GnuRSAPrivateKey /** * Constructs a new instance of a <code>GnuRSAPrivateKey</code> given the * designated arguments. - * + * * @param preferredFormat the indetifier of the preferred encoding format to * use when externalizing this key. * @param p the modulus first prime divisor. @@ -128,7 +128,7 @@ public class GnuRSAPrivateKey /** * Constructs a new instance of a <code>GnuRSAPrivateKey</code> given the * designated arguments. - * + * * @param preferredFormat the indetifier of the preferred encoding format to * use when externalizing this key. * @param n the public modulus, which is also the product of <code>p</code> @@ -173,7 +173,7 @@ public class GnuRSAPrivateKey * method of an RSA keypair codec object (an instance implementing * {@link IKeyPairCodec} for RSA keys, and re-constructs an instance of this * object. - * + * * @param k the contents of a previously encoded instance of this object. * @throws ArrayIndexOutOfBoundsException if there is not enough bytes, in * <code>k</code>, to represent a valid encoding of an instance @@ -229,7 +229,7 @@ public class GnuRSAPrivateKey /** * Returns the encoded form of this private key according to the designated * format. - * + * * @param format the desired format identifier of the resulting encoding. * @return the byte sequence encoding this key according to the designated * format. @@ -258,7 +258,7 @@ public class GnuRSAPrivateKey /** * Returns <code>true</code> if the designated object is an instance of this * class and has the same RSA parameter values as this one. - * + * * @param obj the other non-null RSA key to compare to. * @return <code>true</code> if the designated object is of the same type * and value as this one. diff --git a/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPublicKey.java b/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPublicKey.java index 3217130c258..0bad92881a3 100644 --- a/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPublicKey.java +++ b/libjava/classpath/gnu/java/security/key/rsa/GnuRSAPublicKey.java @@ -1,4 +1,4 @@ -/* GnuRSAPublicKey.java -- +/* GnuRSAPublicKey.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -72,7 +72,7 @@ public class GnuRSAPublicKey * Conveience constructor. Calls the constructor with 3 arguments passing * {@link Registry#RAW_ENCODING_ID} as the identifier of the preferred * encoding format. - * + * * @param n the modulus. * @param e the public exponent. */ @@ -84,7 +84,7 @@ public class GnuRSAPublicKey /** * Constructs a new instance of <code>GnuRSAPublicKey</code> given the * designated arguments. - * + * * @param preferredFormat the identifier of the preferred encoding format to * use when externalizing this key. * @param n the modulus. @@ -102,7 +102,7 @@ public class GnuRSAPublicKey * method of an RSA keypair codec object (an instance implementing * {@link IKeyPairCodec} for RSA keys, and re-constructs an instance of this * object. - * + * * @param k the contents of a previously encoded instance of this object. * @throws ArrayIndexOutOfBoundsException if there is not enough bytes, in * <code>k</code>, to represent a valid encoding of an instance @@ -128,7 +128,7 @@ public class GnuRSAPublicKey /** * Returns the encoded form of this public key according to the designated * format. - * + * * @param format the desired format identifier of the resulting encoding. * @return the byte sequence encoding this key according to the designated * format. @@ -156,7 +156,7 @@ public class GnuRSAPublicKey /** * Returns <code>true</code> if the designated object is an instance of this * class and has the same RSA parameter values as this one. - * + * * @param obj the other non-null RSA key to compare to. * @return <code>true</code> if the designated object is of the same type * and value as this one. diff --git a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairGenerator.java b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairGenerator.java index c31cc4cc1e0..bec60d350ca 100644 --- a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairGenerator.java +++ b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairGenerator.java @@ -1,4 +1,4 @@ -/* RSAKeyPairGenerator.java -- +/* RSAKeyPairGenerator.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -135,7 +135,7 @@ public class RSAKeyPairGenerator /** * Configures this instance. - * + * * @param attributes the map of name/value pairs to use. * @exception IllegalArgumentException if the designated MODULUS_LENGTH value * is less than 1024. @@ -175,7 +175,7 @@ public class RSAKeyPairGenerator * The algorithm used here is described in <i>nessie-pss-B.pdf</i> document * which is part of the RSA-PSS submission to NESSIE. * </p> - * + * * @return an RSA keypair. */ public KeyPair generate() @@ -225,7 +225,7 @@ public class RSAKeyPairGenerator /** * Fills the designated byte array with random data. - * + * * @param buffer the byte array to fill with random data. */ private void nextRandomBytes(byte[] buffer) diff --git a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairPKCS8Codec.java b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairPKCS8Codec.java index 7a51d0a0dd0..2785f02c8ae 100644 --- a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairPKCS8Codec.java +++ b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairPKCS8Codec.java @@ -116,7 +116,7 @@ public class RSAKeyPairPKCS8Codec * coefficient INTEGER, -- (inverse of q) mod p * } * </pre> - * + * * @return the DER encoded form of the ASN.1 representation of the * <i>PrivateKeyInfo</i> field for an RSA {@link PrivateKey}.. * @throw InvalidParameterException if an error occurs during the marshalling @@ -251,7 +251,7 @@ public class RSAKeyPairPKCS8Codec der = new DERReader(pkBytes); DERValue derRSAPrivateKey = der.read(); DerUtil.checkIsConstructed(derRSAPrivateKey, "Wrong RSAPrivateKey field"); - + val = der.read(); DerUtil.checkIsBigInteger(val, "Wrong RSAPrivateKey Version field"); version = (BigInteger) val.getValue(); diff --git a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairRawCodec.java b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairRawCodec.java index 95220236617..f088e794e68 100644 --- a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairRawCodec.java +++ b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairRawCodec.java @@ -1,4 +1,4 @@ -/* RSAKeyPairRawCodec.java -- +/* RSAKeyPairRawCodec.java -- Copyright 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -190,7 +190,7 @@ public class RSAKeyPairRawCodec * the <code>toByteArray()</code> method on the RSA parameter <code>d</code>, * </li> * </ol> - * + * * @param key the key to encode. * @return the <i>Raw</i> format encoding of the designated key. */ diff --git a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairX509Codec.java b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairX509Codec.java index b11e1c01371..9ad6ae02978 100644 --- a/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairX509Codec.java +++ b/libjava/classpath/gnu/java/security/key/rsa/RSAKeyPairX509Codec.java @@ -97,14 +97,14 @@ public class RSAKeyPairX509Codec * <p> * The <i>subjectPublicKey</i> field, which is a BIT STRING, contains the * DER-encoded form of the RSA public key defined as: - * + * * <pre> * RSAPublicKey ::= SEQUENCE { * modulus INTEGER, -- n * publicExponent INTEGER -- e * } * </pre> - * + * * @param key the {@link PublicKey} instance to encode. MUST be an instance of * {@link GnuRSAPublicKey}. * @return the ASN.1 representation of the <i>SubjectPublicKeyInfo</i> in an diff --git a/libjava/classpath/gnu/java/security/pkcs/PKCS7Data.java b/libjava/classpath/gnu/java/security/pkcs/PKCS7Data.java index 3d3052b965b..c6474f08190 100644 --- a/libjava/classpath/gnu/java/security/pkcs/PKCS7Data.java +++ b/libjava/classpath/gnu/java/security/pkcs/PKCS7Data.java @@ -52,7 +52,7 @@ public class PKCS7Data /** * Constructs a new instance of <code>PKCS7Data</code> with the possibly * null (implicetly referenced) content data. - * + * * @param data the raw bytes of the data to use in a PKCS#7 framework. */ public PKCS7Data(byte[] data) diff --git a/libjava/classpath/gnu/java/security/pkcs/PKCS7SignedData.java b/libjava/classpath/gnu/java/security/pkcs/PKCS7SignedData.java index d59dba3cd0f..adb00a3bea0 100644 --- a/libjava/classpath/gnu/java/security/pkcs/PKCS7SignedData.java +++ b/libjava/classpath/gnu/java/security/pkcs/PKCS7SignedData.java @@ -333,7 +333,7 @@ public class PKCS7SignedData /** * Constructs a new instance of <code>PKCS7SignedData</code> given a * designated set of fields. - * + * * @param digestAlgorithms the collection of DigestAlgorithm elements. Each * DigestAlgorithm is a {@link List} of two elements, the first is an * OID while the second is dependent on the value of the OID element. @@ -401,7 +401,7 @@ public class PKCS7SignedData /** * Writes to the designated output stream the DER encoding of the current * contents of this instance. - * + * * @param out the destination output stream. * @throws IOException if an I/O related exception occurs during the process. * @throws CRLException if an exception occurs while encoding the certificate diff --git a/libjava/classpath/gnu/java/security/pkcs/SignerInfo.java b/libjava/classpath/gnu/java/security/pkcs/SignerInfo.java index 3066401ac4b..645ed67bb14 100644 --- a/libjava/classpath/gnu/java/security/pkcs/SignerInfo.java +++ b/libjava/classpath/gnu/java/security/pkcs/SignerInfo.java @@ -90,9 +90,9 @@ public class SignerInfo * issuer Name, * serialNumber CertificateSerialNumber * } - * + * * DigestAlgorithmIdentifier ::= AlgorithmIdentifier - * + * * DigestEncryptionAlgorithmIdentifier ::= AlgorithmIdentifier * * EncryptedDigest ::= OCTET STRING @@ -269,7 +269,7 @@ public class SignerInfo /** * Constructs a new instance of <code>SignerInfo</code> given a designated * set of fields. - * + * * @param issuer the X.500 Principal name of the signer referenced by this * instance. * @param serialNumber the serial number of the certificate being used. Both @@ -369,7 +369,7 @@ public class SignerInfo /** * Writes to the designated output stream the DER encoding of the current * contents of this instance. - * + * * @param out the destination output stream. * @throws IOException if an I/O related exception occurs during the process. */ diff --git a/libjava/classpath/gnu/java/security/prng/BasePRNG.java b/libjava/classpath/gnu/java/security/prng/BasePRNG.java index 3b7c8cf071f..eb5ada71cb4 100644 --- a/libjava/classpath/gnu/java/security/prng/BasePRNG.java +++ b/libjava/classpath/gnu/java/security/prng/BasePRNG.java @@ -1,4 +1,4 @@ -/* BasePRNG.java -- +/* BasePRNG.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -60,7 +60,7 @@ public abstract class BasePRNG /** * Trivial constructor for use by concrete subclasses. - * + * * @param name the canonical name of this instance. */ protected BasePRNG(String name) diff --git a/libjava/classpath/gnu/java/security/prng/EntropySource.java b/libjava/classpath/gnu/java/security/prng/EntropySource.java index 95f68f04872..a7173d3b19a 100644 --- a/libjava/classpath/gnu/java/security/prng/EntropySource.java +++ b/libjava/classpath/gnu/java/security/prng/EntropySource.java @@ -1,4 +1,4 @@ -/* EntropySource.java -- +/* EntropySource.java -- Copyright (C) 2004, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -58,4 +58,4 @@ public interface EntropySource * @return The next random bytes. */ byte[] nextBytes(); -}
\ No newline at end of file +} diff --git a/libjava/classpath/gnu/java/security/prng/IRandom.java b/libjava/classpath/gnu/java/security/prng/IRandom.java index 66ad6d2241b..eb1495dd8cb 100644 --- a/libjava/classpath/gnu/java/security/prng/IRandom.java +++ b/libjava/classpath/gnu/java/security/prng/IRandom.java @@ -1,4 +1,4 @@ -/* IRandom.java -- +/* IRandom.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -79,7 +79,7 @@ public interface IRandom { /** * Returns the canonical name of this instance. - * + * * @return the canonical name of this instance. */ String name(); @@ -87,7 +87,7 @@ public interface IRandom /** * Initialises the pseudo-random number generator scheme with the appropriate * attributes. - * + * * @param attributes a set of name-value pairs that describe the desired * future instance behaviour. * @exception IllegalArgumentException if at least one of the defined name/ @@ -97,7 +97,7 @@ public interface IRandom /** * Returns the next 8 bits of random data generated from this instance. - * + * * @return the next 8 bits of random data generated from this instance. * @exception IllegalStateException if the instance is not yet initialised. * @exception LimitReachedException if this instance has reached its @@ -110,7 +110,7 @@ public interface IRandom * Fills the designated byte array, starting from byte at index * <code>offset</code>, for a maximum of <code>length</code> bytes with * the output of this generator instance. - * + * * @param out the placeholder to contain the generated random bytes. * @param offset the starting index in <i>out</i> to consider. This method * does nothing if this parameter is not within <code>0</code> and @@ -132,7 +132,7 @@ public interface IRandom * Implementations are not required to implement this method in any meaningful * way; this may be a no-operation, and implementations may throw an * {@link UnsupportedOperationException}. - * + * * @param b The byte to add. */ void addRandomByte(byte b); @@ -144,7 +144,7 @@ public interface IRandom * Implementations are not required to implement this method in any meaningful * way; this may be a no-operation, and implementations may throw an * {@link UnsupportedOperationException}. - * + * * @param in The buffer of new random bytes to add. */ void addRandomBytes(byte[] in); @@ -156,7 +156,7 @@ public interface IRandom * Implementations are not required to implement this method in any meaningful * way; this may be a no-operation, and implementations may throw an * {@link UnsupportedOperationException}. - * + * * @param in The buffer of new random bytes to add. * @param offset The offset from whence to begin reading random bytes. * @param length The number of random bytes to add. @@ -167,7 +167,7 @@ public interface IRandom /** * Returns a clone copy of this instance. - * + * * @return a clone copy of this instance. */ Object clone() throws CloneNotSupportedException; diff --git a/libjava/classpath/gnu/java/security/prng/LimitReachedException.java b/libjava/classpath/gnu/java/security/prng/LimitReachedException.java index 8d5b30baf90..028c7455342 100644 --- a/libjava/classpath/gnu/java/security/prng/LimitReachedException.java +++ b/libjava/classpath/gnu/java/security/prng/LimitReachedException.java @@ -1,4 +1,4 @@ -/* LimitReachedException.java -- +/* LimitReachedException.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/prng/MDGenerator.java b/libjava/classpath/gnu/java/security/prng/MDGenerator.java index 574a2f9d64b..b110486f408 100644 --- a/libjava/classpath/gnu/java/security/prng/MDGenerator.java +++ b/libjava/classpath/gnu/java/security/prng/MDGenerator.java @@ -1,4 +1,4 @@ -/* MDGenerator.java -- +/* MDGenerator.java -- Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/prng/PRNGFactory.java b/libjava/classpath/gnu/java/security/prng/PRNGFactory.java index ae15d053b82..b57d7c7bb2c 100644 --- a/libjava/classpath/gnu/java/security/prng/PRNGFactory.java +++ b/libjava/classpath/gnu/java/security/prng/PRNGFactory.java @@ -1,4 +1,4 @@ -/* PRNGFactory.java -- +/* PRNGFactory.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -57,7 +57,7 @@ public class PRNGFactory /** * Returns an instance of a padding algorithm given its name. - * + * * @param prng the case-insensitive name of the PRNG. * @return an instance of the pseudo-random number generator. * @exception InternalError if the implementation does not pass its self- @@ -79,7 +79,7 @@ public class PRNGFactory /** * Returns a {@link Set} of names of padding algorithms supported by this * <i>Factory</i>. - * + * * @return a {@link Set} of pseudo-random number generator algorithm names * (Strings). */ diff --git a/libjava/classpath/gnu/java/security/prng/RandomEventListener.java b/libjava/classpath/gnu/java/security/prng/RandomEventListener.java index beb9087f418..720f2afe431 100644 --- a/libjava/classpath/gnu/java/security/prng/RandomEventListener.java +++ b/libjava/classpath/gnu/java/security/prng/RandomEventListener.java @@ -1,4 +1,4 @@ -/* RandomEventListener.java -- +/* RandomEventListener.java -- Copyright (C) 2004, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/provider/DefaultPolicy.java b/libjava/classpath/gnu/java/security/provider/DefaultPolicy.java index d42be6c908f..566c949dadd 100644 --- a/libjava/classpath/gnu/java/security/provider/DefaultPolicy.java +++ b/libjava/classpath/gnu/java/security/provider/DefaultPolicy.java @@ -7,7 +7,7 @@ GNU Classpath is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. - + GNU Classpath is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU @@ -44,7 +44,7 @@ import java.security.PermissionCollection; import java.security.Permissions; import java.security.Policy; -/** +/** * This is just a stub policy implementation which grants all permissions * to any code source. FIXME: This should be replaced with a real * implementation that reads the policy configuration from a file, like @@ -60,7 +60,7 @@ public class DefaultPolicy extends Policy perms.add(allPermission); return perms; } - + public void refresh() { // Nothing. diff --git a/libjava/classpath/gnu/java/security/provider/PKIXCertPathValidatorImpl.java b/libjava/classpath/gnu/java/security/provider/PKIXCertPathValidatorImpl.java index cdfad3f61c2..d4ce4aeb4fa 100644 --- a/libjava/classpath/gnu/java/security/provider/PKIXCertPathValidatorImpl.java +++ b/libjava/classpath/gnu/java/security/provider/PKIXCertPathValidatorImpl.java @@ -91,7 +91,7 @@ import java.util.logging.Logger; * See <a href="http://www.ietf.org/rfc/rfc3280.txt">RFC 3280: Internet X.509 * Public Key Infrastructure Certificate and Certificate Revocation List (CRL) * Profile</a>. - * + * * @author Casey Marshall (rsdio@metastatic.org) */ public class PKIXCertPathValidatorImpl @@ -403,7 +403,7 @@ public class PKIXCertPathValidatorImpl * <li>The CRL is signed by a certificate in the given cert stores, and that * cert is signed by one of the certificates in the path.</li> * </ol> - * + * * @param crl The CRL being checked. * @param path The path this CRL is being checked against. * @param now The value to use as 'now'. diff --git a/libjava/classpath/gnu/java/security/sig/BaseSignature.java b/libjava/classpath/gnu/java/security/sig/BaseSignature.java index 9c76cacba0f..ef4d87f261f 100644 --- a/libjava/classpath/gnu/java/security/sig/BaseSignature.java +++ b/libjava/classpath/gnu/java/security/sig/BaseSignature.java @@ -1,4 +1,4 @@ -/* BaseSignature.java -- +/* BaseSignature.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -77,7 +77,7 @@ public abstract class BaseSignature /** * Trivial constructor. - * + * * @param schemeName the name of this signature scheme. * @param md the underlying instance of the message digest algorithm. * @throws IllegalArgumentException if the designated hash instance is @@ -174,7 +174,7 @@ public abstract class BaseSignature /** * Fills the designated byte array with random data. - * + * * @param buffer the byte array to fill with random data. */ protected void nextRandomBytes(byte[] buffer) diff --git a/libjava/classpath/gnu/java/security/sig/ISignature.java b/libjava/classpath/gnu/java/security/sig/ISignature.java index ff25f29d9fa..be98f9a9b00 100644 --- a/libjava/classpath/gnu/java/security/sig/ISignature.java +++ b/libjava/classpath/gnu/java/security/sig/ISignature.java @@ -1,4 +1,4 @@ -/* ISignature.java -- +/* ISignature.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -75,14 +75,14 @@ public interface ISignature /** * Returns the canonical name of this signature scheme. - * + * * @return the canonical name of this instance. */ String name(); /** * Initialises this instance for signature verification. - * + * * @param attributes the attributes to use for setting up this instance. * @throws IllegalArgumentException if the designated public key is not * appropriate for this signature scheme. @@ -93,7 +93,7 @@ public interface ISignature /** * Initialises this instance for signature generation. - * + * * @param attributes the attributes to use for setting up this instance. * @throws IllegalArgumentException if the designated private key is not * appropriate for this signature scheme. @@ -104,7 +104,7 @@ public interface ISignature /** * Digests one byte of a message for signing or verification purposes. - * + * * @param b the message byte to digest. * @throws IllegalStateException if this instance was not setup for signature * generation/verification. @@ -114,7 +114,7 @@ public interface ISignature /** * Digests a sequence of bytes from a message for signing or verification * purposes. - * + * * @param buffer the byte sequence to consider. * @param offset the byte poisition in <code>buffer</code> of the first byte * to consider. @@ -129,7 +129,7 @@ public interface ISignature /** * Terminates a signature generation phase by digesting and processing the * context of the underlying message digest algorithm instance. - * + * * @return a {@link Object} representing the native output of the signature * scheme implementation. * @throws IllegalStateException if this instance was not setup for signature @@ -140,7 +140,7 @@ public interface ISignature /** * Terminates a signature verification phase by digesting and processing the * context of the underlying message digest algorithm instance. - * + * * @param signature a native signature object previously generated by an * invocation of the <code>sign()</code> method. * @return <code>true</code> iff the outpout of the verification phase @@ -153,7 +153,7 @@ public interface ISignature /** * Returns a clone copy of this instance. - * + * * @return a clone copy of this instance. */ Object clone(); diff --git a/libjava/classpath/gnu/java/security/sig/ISignatureCodec.java b/libjava/classpath/gnu/java/security/sig/ISignatureCodec.java index aaae6ccb034..f8b14736114 100644 --- a/libjava/classpath/gnu/java/security/sig/ISignatureCodec.java +++ b/libjava/classpath/gnu/java/security/sig/ISignatureCodec.java @@ -1,4 +1,4 @@ -/* ISignatureCodec.java -- +/* ISignatureCodec.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/sig/SignatureCodecFactory.java b/libjava/classpath/gnu/java/security/sig/SignatureCodecFactory.java index c5b2ccd4bc8..0026ad1646a 100644 --- a/libjava/classpath/gnu/java/security/sig/SignatureCodecFactory.java +++ b/libjava/classpath/gnu/java/security/sig/SignatureCodecFactory.java @@ -74,7 +74,7 @@ public class SignatureCodecFactory * When the encoding format name is missing, the Raw encoding format is * assumed. When this is the case the trailing forward slash is discarded from * the name. - * + * * @param name the case-insensitive, possibly composed, signature codec name. * @return an instance of the signaturecodec, or <code>null</code> if none * found. @@ -107,7 +107,7 @@ public class SignatureCodecFactory /** * Returns an instance of a signature codec given the canonical name of the * signature algorithm, and that of the encoding format. - * + * * @param name the case-insensitive signature algorithm name. * @param format the name of the format to use when encodigng/decoding * signatures generated by the named algorithm. @@ -127,7 +127,7 @@ public class SignatureCodecFactory * Returns an instance of a signature codec given the canonical name of the * signature algorithm, and the identifier of the format to use when * encoding/decoding signatures generated by that algorithm. - * + * * @param name the case-insensitive signature algorithm name. * @param formatID the identifier of the format to use when encoding / * decoding signatures generated by the designated algorithm. diff --git a/libjava/classpath/gnu/java/security/sig/SignatureFactory.java b/libjava/classpath/gnu/java/security/sig/SignatureFactory.java index 28b68925b21..6cdaf6544ef 100644 --- a/libjava/classpath/gnu/java/security/sig/SignatureFactory.java +++ b/libjava/classpath/gnu/java/security/sig/SignatureFactory.java @@ -1,4 +1,4 @@ -/* SignatureFactory.java -- +/* SignatureFactory.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -61,7 +61,7 @@ public class SignatureFactory /** * Returns an instance of a signature-with-appendix scheme given its name. - * + * * @param ssa the case-insensitive signature-with-appendix scheme name. * @return an instance of the scheme, or <code>null</code> if none found. */ @@ -84,7 +84,7 @@ public class SignatureFactory /** * Returns a {@link Set} of signature-with-appendix scheme names supported by * this <i>Factory</i>. - * + * * @return a {@link Set} of signature-with-appendix scheme names (Strings). */ public static synchronized final Set getNames() diff --git a/libjava/classpath/gnu/java/security/sig/dss/DSSSignature.java b/libjava/classpath/gnu/java/security/sig/dss/DSSSignature.java index 1ef1bea1a7f..024521ba421 100644 --- a/libjava/classpath/gnu/java/security/sig/dss/DSSSignature.java +++ b/libjava/classpath/gnu/java/security/sig/dss/DSSSignature.java @@ -1,4 +1,4 @@ -/* DSSSignature.java -- +/* DSSSignature.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -211,7 +211,7 @@ public class DSSSignature /** * Returns the output of a signature generation phase. - * + * * @return an object encapsulating the DSS signature pair <code>r</code> and * <code>s</code>. */ @@ -223,7 +223,7 @@ public class DSSSignature /** * Returns the output of a previously generated signature object as a pair of * {@link java.math.BigInteger}. - * + * * @return the DSS signature pair <code>r</code> and <code>s</code>. */ private BigInteger[] decodeSignature(Object signature) diff --git a/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureRawCodec.java b/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureRawCodec.java index 903d7aad6c9..169f84bd1c6 100644 --- a/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureRawCodec.java +++ b/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureRawCodec.java @@ -1,4 +1,4 @@ -/* DSSSignatureRawCodec.java -- +/* DSSSignatureRawCodec.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -78,7 +78,7 @@ public class DSSSignatureRawCodec * the <code>toByteArray()</code> method on the DSS parameter <code>s</code>. * </li> * </ol> - * + * * @param signature the signature to encode, consisting of the two DSS * parameters <code>r</code> and <code>s</code> as a * {@link BigInteger} array. diff --git a/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureX509Codec.java b/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureX509Codec.java index 0fdb754a982..d0a0188fba3 100644 --- a/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureX509Codec.java +++ b/libjava/classpath/gnu/java/security/sig/dss/DSSSignatureX509Codec.java @@ -60,7 +60,7 @@ import java.util.ArrayList; * <p> * Digital signatures when transmitted in an X.509 certificates are encoded * in DER (Distinguished Encoding Rules) as a BIT STRING; i.e. - * + * * <pre> * Certificate ::= SEQUENCE { * tbsCertificate TBSCertificate, @@ -77,7 +77,7 @@ import java.util.ArrayList; * generates two MPIs, commonly called <code>r</code> and <code>s</code>, as the * result of digitally signing a message, these two numbers will be transferred * as the following ASN.1 structure: - * + * * <pre> * Dss-Sig-Value ::= SEQUENCE { * r INTEGER, @@ -112,7 +112,7 @@ public class DSSSignatureX509Codec * Encodes a DSS Signature output as the <i>signature</i> raw bytes which can * be used to construct an ASN.1 DER-encoded BIT STRING as defined in the * documentation of this class. - * + * * @param signature the output of the DSS signature algorithm; i.e. the value * returned by the invocation of * {@link gnu.java.security.sig.ISignature#sign()} method. In the @@ -154,7 +154,7 @@ public class DSSSignatureX509Codec /** * Decodes a <i>signature</i> as defined in the documentation of this class. - * + * * @param input the byte array to unmarshall into a valid DSS signature * instance; i.e. an array of two MPIs. MUST NOT be null. * @return an array of two MPIs, <code>r</code> and <code>s</code> in this diff --git a/libjava/classpath/gnu/java/security/sig/rsa/EME_PKCS1_V1_5.java b/libjava/classpath/gnu/java/security/sig/rsa/EME_PKCS1_V1_5.java index 39de01f0213..329ca8ed692 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/EME_PKCS1_V1_5.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/EME_PKCS1_V1_5.java @@ -1,4 +1,4 @@ -/* EME_PKCS1_V1_5.java -- +/* EME_PKCS1_V1_5.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -104,7 +104,7 @@ public class EME_PKCS1_V1_5 * </pre> * <p> * This method uses a default PRNG to obtain the padding bytes. - * + * * @param M the message to encode. * @return the encoded message <code>EM</code>. */ @@ -133,7 +133,7 @@ public class EME_PKCS1_V1_5 * Similar to {@link #encode(byte[])} method, except that the source of * randomness to use for obtaining the padding bytes (an instance of * {@link IRandom}) is given as a parameter. - * + * * @param M the message to encode. * @param irnd the {@link IRandom} instance to use as a source of randomness. * @return the encoded message <code>EM</code>. @@ -173,7 +173,7 @@ public class EME_PKCS1_V1_5 /** * Similar to the {@link #encode(byte[], IRandom)} method, except that the * source of randmoness is an instance of {@link Random}. - * + * * @param M the message to encode. * @param rnd the {@link Random} instance to use as a source of randomness. * @return the encoded message <code>EM</code>. @@ -213,7 +213,7 @@ public class EME_PKCS1_V1_5 * hexadecimal value <code>0x00</code> to separate <code>PS</code> from * <code>M</code>, or if the length of <code>PS</code> is less than * <code>8</code> octets, output "decryption error" and stop. - * + * * @param EM the designated encoded message. * @return the decoded message <code>M</code> framed in the designated * <code>EM</code> value. diff --git a/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PKCS1_V1_5.java b/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PKCS1_V1_5.java index a0c4de17fab..3cddab4aa4d 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PKCS1_V1_5.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PKCS1_V1_5.java @@ -1,4 +1,4 @@ -/* EMSA_PKCS1_V1_5.java -- +/* EMSA_PKCS1_V1_5.java -- Copyright (C) 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. diff --git a/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PSS.java b/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PSS.java index 97b3afcf8c1..917d9632334 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PSS.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/EMSA_PSS.java @@ -1,4 +1,4 @@ -/* EMSA_PSS.java -- +/* EMSA_PSS.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -83,7 +83,7 @@ public class EMSA_PSS /** * Trivial private constructor to enforce use through Factory method. - * + * * @param hash the message digest instance to use with this scheme instance. */ private EMSA_PSS(IMessageDigest hash) @@ -97,7 +97,7 @@ public class EMSA_PSS /** * Returns an instance of this object given a designated name of a hash * function. - * + * * @param mdName the canonical name of a hash function. * @return an instance of this object configured for use with the designated * options. @@ -118,7 +118,7 @@ public class EMSA_PSS * <code>M</code> using a hash function and maps the result to an encoded * message <code>EM</code> of a specified length using a mask generation * function. - * + * * @param mHash the byte sequence resulting from applying the message digest * algorithm Hash to the message <i>M</i>. * @param emBits the maximal bit length of the integer OS2IP(EM), at least @@ -192,7 +192,7 @@ public class EMSA_PSS * The decoding operation EMSA-PSS-Decode recovers the message hash from an * encoded message <code>EM</code> and compares it to the hash of * <code>M</code>. - * + * * @param mHash the byte sequence resulting from applying the message digest * algorithm Hash to the message <i>M</i>. * @param EM the <i>encoded message</i>, an octet string of length @@ -324,7 +324,7 @@ public class EMSA_PSS * the output. The provable security of RSA-PSS relies on the random nature of * the output of the mask generation function, which in turn relies on the * random nature of the underlying hash function. - * + * * @param Z a seed. * @param l the desired output length in octets. * @return the mask. diff --git a/libjava/classpath/gnu/java/security/sig/rsa/RSA.java b/libjava/classpath/gnu/java/security/sig/rsa/RSA.java index cdd9eaa5b8a..343b2cf65fe 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/RSA.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/RSA.java @@ -1,4 +1,4 @@ -/* RSA.java -- +/* RSA.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -87,7 +87,7 @@ public class RSA * RSA private key is a valid one, this method computes a <i>signature * representative</i> for a designated <i>message representative</i> signed * by the holder of the designated RSA private key. - * + * * @param K the RSA private key. * @param m the <i>message representative</i>: an integer between * <code>0</code> and <code>n - 1</code>, where <code>n</code> @@ -117,7 +117,7 @@ public class RSA * representative</i> for the designated <i>signature representative</i> * generated by an RSA private key, for a message intended for the holder of * the designated RSA public key. - * + * * @param K the RSA public key. * @param s the <i>signature representative</i>, an integer between * <code>0</code> and <code>n - 1</code>, where <code>n</code> @@ -143,7 +143,7 @@ public class RSA /** * An implementation of the <code>RSAEP</code> algorithm. - * + * * @param K the recipient's RSA public key. * @param m the message representative as an MPI. * @return the resulting MPI --an MPI between <code>0</code> and @@ -170,7 +170,7 @@ public class RSA /** * An implementation of the <code>RSADP</code> algorithm. - * + * * @param K the recipient's RSA private key. * @param c the ciphertext representative as an MPI. * @return the message representative, an MPI between <code>0</code> and @@ -197,7 +197,7 @@ public class RSA /** * Converts a <i>multi-precision integer</i> (MPI) <code>s</code> into an * octet sequence of length <code>k</code>. - * + * * @param s the multi-precision integer to convert. * @param k the length of the output. * @return the result of the transform. @@ -302,7 +302,7 @@ public class RSA /** * Returns a random MPI with a random bit-length of the form <code>8b</code>, * where <code>b</code> is in the range <code>[32..64]</code>. - * + * * @return a random MPI whose length in bytes is between 32 and 64 inclusive. */ private static final BigInteger newR(final BigInteger N) diff --git a/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5Signature.java b/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5Signature.java index 76460c0cafa..1420331ded6 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5Signature.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5Signature.java @@ -1,4 +1,4 @@ -/* RSAPKCS1V1_5Signature.java -- +/* RSAPKCS1V1_5Signature.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -85,7 +85,7 @@ public class RSAPKCS1V1_5Signature /** * Constructs an instance of this object using the designated message digest * algorithm as its underlying hash function. - * + * * @param mdName the canonical name of the underlying hash function. */ public RSAPKCS1V1_5Signature(final String mdName) diff --git a/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureRawCodec.java b/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureRawCodec.java index 68c1edaa6b1..548dc3debff 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureRawCodec.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureRawCodec.java @@ -71,7 +71,7 @@ public class RSAPKCS1V1_5SignatureRawCodec * signature bytes in internet order,</li> * <li>the RSA-PKCS#1 (v1.5) signature bytes in internet order.</li> * </ol> - * + * * @param signature the signature to encode, consisting of the output of the * <code>sign()</code> method of a {@link RSAPKCS1V1_5Signature} * instance --a byte array. @@ -116,7 +116,7 @@ public class RSAPKCS1V1_5SignatureRawCodec /** * Returns the decoded object from a designated input assumed to have been * generated by the {@link #encodeSignature(Object)} method. - * + * * @param input the input bytes of a previously Raw-encoded RSA PKCS1 (v1.5) * signature. * @return the signature object. diff --git a/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureX509Codec.java b/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureX509Codec.java index 3cb375602a0..ee8586f7d82 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureX509Codec.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/RSAPKCS1V1_5SignatureX509Codec.java @@ -51,7 +51,7 @@ import java.security.InvalidParameterException; * <p> * Digital signatures when transmitted in an X.509 certificates are encoded * in DER (Distinguished Encoding Rules) as a BIT STRING; i.e. - * + * * <pre> * Certificate ::= SEQUENCE { * tbsCertificate TBSCertificate, @@ -95,7 +95,7 @@ public class RSAPKCS1V1_5SignatureX509Codec /** * Encodes an RSA Signature output as a <i>signature</i> BIT STRING as * defined in the documentation of this class. - * + * * @param signature the output of the RSA PKCS1 (v1.5) signature algorithm; * i.e. the value returned by the invocation of * {@link gnu.java.security.sig.ISignature#sign()} method. In the @@ -111,7 +111,7 @@ public class RSAPKCS1V1_5SignatureX509Codec /** * Decodes a <i>signature</i> as defined in the documentation of this class. - * + * * @param input the byte array to unmarshall into a valid RSA PKCS1 (v1.5) * signature instance; i.e. a byte array. MUST NOT be null. * @return an array of raw bytes decoded from the designated input. In the diff --git a/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignature.java b/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignature.java index 27c7fe620fd..d8f8327f1cf 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignature.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignature.java @@ -1,4 +1,4 @@ -/* RSAPSSSignature.java -- +/* RSAPSSSignature.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -95,7 +95,7 @@ public class RSAPSSSignature /** * Constructs an instance of this object using the designated message digest * algorithm as its underlying hash function, and having 0-octet <i>salt</i>. - * + * * @param mdName the canonical name of the underlying hash function. */ public RSAPSSSignature(String mdName) @@ -106,7 +106,7 @@ public class RSAPSSSignature /** * Constructs an instance of this object using the designated message digest * algorithm as its underlying hash function. - * + * * @param mdName the canonical name of the underlying hash function. * @param sLen the desired length in octets of the salt to use for encoding / * decoding signatures. diff --git a/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignatureRawCodec.java b/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignatureRawCodec.java index b5e059c20e0..b147ea3ea21 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignatureRawCodec.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/RSAPSSSignatureRawCodec.java @@ -1,4 +1,4 @@ -/* RSAPSSSignatureRawCodec.java -- +/* RSAPSSSignatureRawCodec.java -- Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -72,7 +72,7 @@ public class RSAPSSSignatureRawCodec * bytes in internet order,</li> * <li>the RSA-PSS signature bytes in internet order.</li> * </ol> - * + * * @param signature the signature to encode, consisting of the output of the * <code>sign()</code> method of a {@link RSAPSSSignature} instance * --a byte array. diff --git a/libjava/classpath/gnu/java/security/sig/rsa/RSASignatureFactory.java b/libjava/classpath/gnu/java/security/sig/rsa/RSASignatureFactory.java index b8e12caf769..ba5121b4651 100644 --- a/libjava/classpath/gnu/java/security/sig/rsa/RSASignatureFactory.java +++ b/libjava/classpath/gnu/java/security/sig/rsa/RSASignatureFactory.java @@ -71,7 +71,7 @@ public class RSASignatureFactory * hyphen chanaracter <code>-</code> followed by the canonical message digest * algorithm name. When no message digest algorithm name is given, SHA-160 is * used. - * + * * @param name the composite RSA signature name. * @return a new instance of an RSA Signature algorithm implementation. * Returns <code>null</code> if the given name does not correspond to any @@ -102,7 +102,7 @@ public class RSASignatureFactory /** * Returns a {@link Set} of names of <i>RSA</i> signatures supported by this * <i>Factory</i>. - * + * * @return a {@link Set} of RSA Signature algorithm names (Strings). */ public static synchronized final Set getNames() diff --git a/libjava/classpath/gnu/java/security/util/ByteArray.java b/libjava/classpath/gnu/java/security/util/ByteArray.java index 51449204397..a9b9e5d0066 100644 --- a/libjava/classpath/gnu/java/security/util/ByteArray.java +++ b/libjava/classpath/gnu/java/security/util/ByteArray.java @@ -65,23 +65,23 @@ public final class ByteArray int len = value.length; while (i < len) { - out.print (formatInt (i, 16, 8)); - out.print (" "); - int l = Math.min (16, len - i); - String s = toHexString (value, i, l, ' '); - out.print (s); - for (int j = 56 - (56 - s.length ()); j < 56; j++) - out.print (" "); - for (int j = 0; j < l; j++) - { - byte b = value[i+j]; - if ((b & 0xFF) < 0x20 || (b & 0xFF) > 0x7E) - out.print ("."); - else - out.print ((char) (b & 0xFF)); - } - out.println (); - i += 16; + out.print (formatInt (i, 16, 8)); + out.print (" "); + int l = Math.min (16, len - i); + String s = toHexString (value, i, l, ' '); + out.print (s); + for (int j = 56 - (56 - s.length ()); j < 56; j++) + out.print (" "); + for (int j = 0; j < l; j++) + { + byte b = value[i+j]; + if ((b & 0xFF) < 0x20 || (b & 0xFF) > 0x7E) + out.print ("."); + else + out.print ((char) (b & 0xFF)); + } + out.println (); + i += 16; } return str.toString (); } @@ -91,8 +91,8 @@ public final class ByteArray CPStringBuilder str = new CPStringBuilder(); for (int i = 0; i < len; i++) { - str.append (Character.forDigit (buf[i+off] >>> 4 & 0x0F, 16)); - str.append (Character.forDigit (buf[i+off] & 0x0F, 16)); + str.append (Character.forDigit (buf[i+off] >>> 4 & 0x0F, 16)); + str.append (Character.forDigit (buf[i+off] & 0x0F, 16)); if (i < len - 1) str.append(sep); } diff --git a/libjava/classpath/gnu/java/security/util/ByteBufferOutputStream.java b/libjava/classpath/gnu/java/security/util/ByteBufferOutputStream.java index be4d0a98d67..642ccdf68f8 100644 --- a/libjava/classpath/gnu/java/security/util/ByteBufferOutputStream.java +++ b/libjava/classpath/gnu/java/security/util/ByteBufferOutputStream.java @@ -47,18 +47,18 @@ import java.nio.ByteBuffer; /** * An output stream that writes bytes to a ByteBuffer, which will be resized * if more space is needed. - * + * * @author Casey Marshall (csm@gnu.org) */ public class ByteBufferOutputStream extends OutputStream { private ByteBuffer buffer; - + public ByteBufferOutputStream() { this(256); } - + public ByteBufferOutputStream(int initialCapacity) { buffer = ByteBuffer.allocate(initialCapacity); @@ -71,16 +71,16 @@ public class ByteBufferOutputStream extends OutputStream { if (!buffer.hasRemaining()) growBuffer(); - buffer.put((byte) b); + buffer.put((byte) b); } - + public @Override synchronized void write(byte[] b, int offset, int length) { if (buffer.remaining() < length) growBuffer(); buffer.put(b, offset, length); } - + public @Override void write(byte[] b) { write(b, 0, b.length); @@ -90,19 +90,19 @@ public class ByteBufferOutputStream extends OutputStream * Get the current state of the buffer. The returned buffer will have * its position set to zero, its capacity set to the current limit, * and its limit set to its capacity. - * + * * @return The buffer. */ public ByteBuffer buffer() { return ((ByteBuffer) buffer.duplicate().flip()).slice(); } - + public String toString() { return super.toString() + " [ buffer: " + buffer + " ]"; } - + private void growBuffer() { int newCapacity = buffer.capacity(); diff --git a/libjava/classpath/gnu/java/security/util/ExpirableObject.java b/libjava/classpath/gnu/java/security/util/ExpirableObject.java index e0c4e6b5984..e24af249aa5 100644 --- a/libjava/classpath/gnu/java/security/util/ExpirableObject.java +++ b/libjava/classpath/gnu/java/security/util/ExpirableObject.java @@ -57,7 +57,7 @@ import javax.security.auth.Destroyable; * <p> * Note that if a {@link DestroyFailedException} occurs when the timeout * expires, it will not be reported. - * + * * @see Destroyable */ public abstract class ExpirableObject @@ -89,7 +89,7 @@ public abstract class ExpirableObject /** * Create a new expirable object that will expire after the specified timeout. - * + * * @param delay The delay before expiration. * @throws IllegalArgumentException If <i>delay</i> is negative, or if * <code>delay + System.currentTimeMillis()</code> is negative. @@ -104,7 +104,7 @@ public abstract class ExpirableObject * Destroys this object. This method calls {@link #doDestroy}, then, if no * exception is thrown, cancels the task that would destroy this object when * the timeout is reached. - * + * * @throws DestroyFailedException If this operation fails. */ public final void destroy() throws DestroyFailedException @@ -116,7 +116,7 @@ public abstract class ExpirableObject /** * Subclasses must implement this method instead of the {@link * Destroyable#destroy()} method. - * + * * @throws DestroyFailedException If this operation fails. */ protected abstract void doDestroy() throws DestroyFailedException; diff --git a/libjava/classpath/gnu/java/security/util/FormatUtil.java b/libjava/classpath/gnu/java/security/util/FormatUtil.java index eed669cc3a4..35da322b813 100644 --- a/libjava/classpath/gnu/java/security/util/FormatUtil.java +++ b/libjava/classpath/gnu/java/security/util/FormatUtil.java @@ -53,7 +53,7 @@ public class FormatUtil /** * Returns the fully qualified name of the designated encoding ID. - * + * * @param formatID the unique identifier of the encoding format. * @return the fully qualified name of the designated format. Returns * <code>null</code> if no such encoding format is known. @@ -83,7 +83,7 @@ public class FormatUtil /** * Returns the short name of the designated encoding ID. This is used by the * JCE Adapters. - * + * * @param formatID the unique identifier of the encoding format. * @return the short name of the designated format. Returns <code>null</code> * if no such encoding format is known. @@ -112,7 +112,7 @@ public class FormatUtil /** * Returns the identifier of the encoding format given its short name. - * + * * @param name the case-insensitive canonical short name of an encoding * format. * @return the identifier of the designated encoding format, or <code>0</code> @@ -134,7 +134,7 @@ public class FormatUtil result = Registry.X509_ENCODING_ID; else if (name.equalsIgnoreCase(Registry.PKCS8_ENCODING_SHORT_NAME)) result = Registry.PKCS8_ENCODING_ID; - + return result; } } diff --git a/libjava/classpath/gnu/java/security/util/IntegerUtil.java b/libjava/classpath/gnu/java/security/util/IntegerUtil.java index f071308084c..106dc4d6653 100644 --- a/libjava/classpath/gnu/java/security/util/IntegerUtil.java +++ b/libjava/classpath/gnu/java/security/util/IntegerUtil.java @@ -71,7 +71,7 @@ public abstract class IntegerUtil * This method MUST be used in the gnu.java.security and gnu.javax.crypto * packages to ensure they would work with a version 1.4 only of the Java * class library API. - * + * * @param aString a string representation of an integer. * @return the {@link Integer} object representing the designated string. */ @@ -98,7 +98,7 @@ public abstract class IntegerUtil * This method MUST be used in the gnu.java.security and gnu.javax.crypto * packages to ensure they would work with a version 1.4 only of the Java * class library API. - * + * * @param anInt a decimal integer. * @return the {@link Integer} object representing the designated primitive. */ diff --git a/libjava/classpath/gnu/java/security/util/PRNG.java b/libjava/classpath/gnu/java/security/util/PRNG.java index 7bb27cbf452..1bed04dcd0f 100644 --- a/libjava/classpath/gnu/java/security/util/PRNG.java +++ b/libjava/classpath/gnu/java/security/util/PRNG.java @@ -47,7 +47,7 @@ import gnu.java.security.prng.MDGenerator; /** * A useful hash-based (SHA) pseudo-random number generator used throughout this * library. - * + * * @see MDGenerator */ public class PRNG @@ -57,7 +57,7 @@ public class PRNG /** * Private constructor to enforce using the Factory method. - * + * * @param delegate the undelying {@link IRandom} object used. */ private PRNG(IRandom delegate) @@ -93,7 +93,7 @@ public class PRNG /** * Completely fills the designated <code>buffer</code> with random data * generated by the underlying delegate. - * + * * @param buffer the place holder of random bytes generated by the underlying * delegate. On output, the contents of <code>buffer</code> are * replaced with pseudo-random data, iff the <code>buffer</code> @@ -108,7 +108,7 @@ public class PRNG * Fills the designated <code>buffer</code>, starting from byte at position * <code>offset</code> with, at most, <code>length</code> bytes of random * data generated by the underlying delegate. - * + * * @see IRandom#nextBytes */ public void nextBytes(byte[] buffer, int offset, int length) diff --git a/libjava/classpath/gnu/java/security/util/Prime.java b/libjava/classpath/gnu/java/security/util/Prime.java index e493ce67503..82c584ff42a 100644 --- a/libjava/classpath/gnu/java/security/util/Prime.java +++ b/libjava/classpath/gnu/java/security/util/Prime.java @@ -7,7 +7,7 @@ GNU Classpath is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. - + GNU Classpath is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU @@ -55,49 +55,49 @@ public final class Prime BigInteger p = new BigInteger( (pmax + pmin)/2, new Random() ); if( p.compareTo( BigInteger.valueOf( 1 ).shiftLeft( pmin ) ) <= 0 ) { - p = p.add( BigInteger.valueOf( 1 ).shiftLeft( pmin ).subtract( p ) ); + p = p.add( BigInteger.valueOf( 1 ).shiftLeft( pmin ).subtract( p ) ); } - + //Step 2 - test for even if( p.mod( BigInteger.valueOf(2) ).compareTo( BigInteger.valueOf( 0 )) == 0) p = p.add( BigInteger.valueOf( 1 ) ); for(;;) { - //Step 3 - if( p.compareTo( BigInteger.valueOf( 1 ).shiftLeft( pmax)) > 0) - { - //Step 3.1 - p = p.subtract( BigInteger.valueOf( 1 ).shiftLeft( pmax) ); - p = p.add( BigInteger.valueOf( 1 ).shiftLeft( pmin) ); - p = p.subtract( BigInteger.valueOf( 1 ) ); - - //Step 3.2 - // put step 2 code here so looping code is cleaner - //Step 2 - test for even - if( p.mod( BigInteger.valueOf(2) ).compareTo( BigInteger.valueOf( 0 )) == 0) - p = p.add( BigInteger.valueOf( 1 ) ); - continue; - } - - //Step 4 - compute GCD - d = p.subtract( BigInteger.valueOf(1) ); - d = d.gcd( f ); - - //Step 5 - test d - if( d.compareTo( BigInteger.valueOf( 1 ) ) == 0) - { - //Step 5.1 - test primality - if( p.isProbablePrime( 1 ) == true ) - { - //Step 5.2; - return p; - } - } - //Step 6 - p = p.add( BigInteger.valueOf( 2 ) ); - - //Step 7 + //Step 3 + if( p.compareTo( BigInteger.valueOf( 1 ).shiftLeft( pmax)) > 0) + { + //Step 3.1 + p = p.subtract( BigInteger.valueOf( 1 ).shiftLeft( pmax) ); + p = p.add( BigInteger.valueOf( 1 ).shiftLeft( pmin) ); + p = p.subtract( BigInteger.valueOf( 1 ) ); + + //Step 3.2 + // put step 2 code here so looping code is cleaner + //Step 2 - test for even + if( p.mod( BigInteger.valueOf(2) ).compareTo( BigInteger.valueOf( 0 )) == 0) + p = p.add( BigInteger.valueOf( 1 ) ); + continue; + } + + //Step 4 - compute GCD + d = p.subtract( BigInteger.valueOf(1) ); + d = d.gcd( f ); + + //Step 5 - test d + if( d.compareTo( BigInteger.valueOf( 1 ) ) == 0) + { + //Step 5.1 - test primality + if( p.isProbablePrime( 1 ) == true ) + { + //Step 5.2; + return p; + } + } + //Step 6 + p = p.add( BigInteger.valueOf( 2 ) ); + + //Step 7 } } @@ -122,43 +122,43 @@ public final class Prime //Step 4 - test for even if( p.mod( BigInteger.valueOf(2) ).compareTo( BigInteger.valueOf( 0 )) == 0) - p = p.add( r ); + p = p.add( r ); for(;;) - { - //Step 5 - if( p.compareTo( BigInteger.valueOf( 1 ).shiftLeft( pmax)) > 0) - { - //Step 5.1 - p = p.subtract( BigInteger.valueOf( 1 ).shiftLeft( pmax) ); - p = p.add( BigInteger.valueOf( 1 ).shiftLeft( pmin) ); - p = p.subtract( BigInteger.valueOf( 1 ) ); - - //Step 5.2 - goto to Step 2 - break steptwo; - } - - //Step 6 - d = p.subtract( BigInteger.valueOf(1) ); - d = d.gcd( f ); - - //Step 7 - test d - if( d.compareTo( BigInteger.valueOf( 1 ) ) == 0) - { - //Step 7.1 - test primality - if( p.isProbablePrime( 1 ) == true ) - { - //Step 7.2; - return p; - } - } - //Step 8 - p = p.add( r.multiply( BigInteger.valueOf(2) ) ); - - //Step 9 - } + { + //Step 5 + if( p.compareTo( BigInteger.valueOf( 1 ).shiftLeft( pmax)) > 0) + { + //Step 5.1 + p = p.subtract( BigInteger.valueOf( 1 ).shiftLeft( pmax) ); + p = p.add( BigInteger.valueOf( 1 ).shiftLeft( pmin) ); + p = p.subtract( BigInteger.valueOf( 1 ) ); + + //Step 5.2 - goto to Step 2 + break steptwo; + } + + //Step 6 + d = p.subtract( BigInteger.valueOf(1) ); + d = d.gcd( f ); + + //Step 7 - test d + if( d.compareTo( BigInteger.valueOf( 1 ) ) == 0) + { + //Step 7.1 - test primality + if( p.isProbablePrime( 1 ) == true ) + { + //Step 7.2; + return p; + } + } + //Step 8 + p = p.add( r.multiply( BigInteger.valueOf(2) ) ); + + //Step 9 + } } //Should never reach here but makes the compiler happy - return BigInteger.valueOf(0); + return BigInteger.valueOf(0); } } diff --git a/libjava/classpath/gnu/java/security/util/Sequence.java b/libjava/classpath/gnu/java/security/util/Sequence.java index 5e3a64eaf3e..63086d2bd0f 100644 --- a/libjava/classpath/gnu/java/security/util/Sequence.java +++ b/libjava/classpath/gnu/java/security/util/Sequence.java @@ -55,7 +55,7 @@ public final class Sequence * through all positive integers then negative integers until the end value is * reached. Naturally, this will result in an enormous object, so don't do * this. - * + * * @param end The ending value. */ public Sequence(int end) @@ -68,7 +68,7 @@ public final class Sequence * increment of 1. If <i>end</i> is less than <i>start</i>, then the * sequence will wrap around until the end value is reached. Naturally, this * will result in an enormous object, so don't do this. - * + * * @param start The starting value. * @param end The ending value. */ @@ -88,7 +88,7 @@ public final class Sequence * If <i>span</i> is 0, then the sequence will contain {<i>start</i>, * <i>end</i>} if <i>start</i> != <i>end</i>, or just the singleton * <i>start</i> if <i>start</i> == <i>end</i>. - * + * * @param start The starting value. * @param end The ending value. * @param span The increment value. diff --git a/libjava/classpath/gnu/java/security/util/SimpleList.java b/libjava/classpath/gnu/java/security/util/SimpleList.java index 74f3bafcead..15d54c988ab 100644 --- a/libjava/classpath/gnu/java/security/util/SimpleList.java +++ b/libjava/classpath/gnu/java/security/util/SimpleList.java @@ -54,7 +54,7 @@ public final class SimpleList /** * Create a singleton list. - * + * * @param element The first element. */ public SimpleList(final Object element) @@ -65,7 +65,7 @@ public final class SimpleList /** * Create an ordered pair (2-tuple). - * + * * @param e1 The first element. * @param e2 The second element. */ @@ -78,7 +78,7 @@ public final class SimpleList /** * Create a 3-tuple. - * + * * @param e1 The first element. * @param e2 The second element. * @param e3 The third element. @@ -93,7 +93,7 @@ public final class SimpleList /** * Create a 4-tuple. - * + * * @param e1 The first element. * @param e2 The second element. * @param e3 The third element. @@ -121,7 +121,7 @@ public final class SimpleList * Create an n-tuple of arbitrary size. Even if the supplied collection has no * natural order, the created n-tuple will have the order that the elements * are returned by the collection's iterator. - * + * * @param c The collection. */ public SimpleList(Collection c) diff --git a/libjava/classpath/gnu/java/security/util/Util.java b/libjava/classpath/gnu/java/security/util/Util.java index 50d4466d539..ef3d480a0b6 100644 --- a/libjava/classpath/gnu/java/security/util/Util.java +++ b/libjava/classpath/gnu/java/security/util/Util.java @@ -70,7 +70,7 @@ public class Util * <pre> * toString(ba, 0, ba.length); * </pre> - * + * * @param ba the byte array to convert. * @return a string of hexadecimal characters (two for each byte) representing * the designated input byte array. @@ -84,7 +84,7 @@ public class Util * Returns a string of hexadecimal digits from a byte array, starting at * <code>offset</code> and consisting of <code>length</code> bytes. Each * byte is converted to 2 hex symbols; zero(es) included. - * + * * @param ba the byte array to convert. * @param offset the index from which to start considering the bytes to * convert. @@ -114,7 +114,7 @@ public class Util * <pre> * toReversedString(ba, 0, ba.length); * </pre> - * + * * @param ba the byte array to convert. * @return a string of hexadecimal characters (two for each byte) representing * the designated input byte array. @@ -131,7 +131,7 @@ public class Util * <p> * The byte array is treated as a large little-endian integer, and is returned * as a large big-endian integer. - * + * * @param ba the byte array to convert. * @param offset the index from which to start considering the bytes to * convert. @@ -156,7 +156,7 @@ public class Util * <p> * Returns a byte array from a string of hexadecimal digits. * </p> - * + * * @param s a string of hexadecimal ASCII characters * @return the decoded byte array from the input hexadecimal string. */ @@ -179,7 +179,7 @@ public class Util * Returns a byte array from a string of hexadecimal digits, interpreting them * as a large big-endian integer and returning it as a large little-endian * integer. - * + * * @param s a string of hexadecimal ASCII characters * @return the decoded byte array from the input hexadecimal string. */ @@ -201,7 +201,7 @@ public class Util /** * Returns a number from <code>0</code> to <code>15</code> corresponding * to the designated hexadecimal digit. - * + * * @param c a hexadecimal ASCII symbol. */ public static int fromDigit(char c) @@ -219,7 +219,7 @@ public class Util /** * Returns a string of 8 hexadecimal digits (most significant digit first) * corresponding to the unsigned integer <code>n</code>. - * + * * @param n the unsigned integer to convert. * @return a hexadecimal string 8-character long. */ @@ -260,7 +260,7 @@ public class Util /** * Returns a string of 16 hexadecimal digits (most significant digit first) * corresponding to the unsigned long <code>n</code>. - * + * * @param n the unsigned long to convert. * @return a hexadecimal string 16-character long. */ @@ -280,7 +280,7 @@ public class Util * escape character is inserted before every pair of bytes. Useful to * externalise byte arrays that will be constructed later from such strings; * eg. s-box values. - * + * * @throws ArrayIndexOutOfBoundsException if the length is odd. */ public static String toUnicodeString(byte[] ba) @@ -293,7 +293,7 @@ public class Util * escape character is inserted before every pair of bytes. Useful to * externalise byte arrays that will be constructed later from such strings; * eg. s-box values. - * + * * @throws ArrayIndexOutOfBoundsException if the length is odd. */ public static final String toUnicodeString(byte[] ba, int offset, int length) @@ -324,7 +324,7 @@ public class Util * escape character is inserted before every pair of bytes. Useful to * externalise integer arrays that will be constructed later from such * strings; eg. s-box values. - * + * * @throws ArrayIndexOutOfBoundsException if the length is not a multiple of * 4. */ @@ -376,7 +376,7 @@ public class Util * If <code>offset</code> and <code>length</code> are omitted, the whole * array is used. If <code>m</code> is omitted, nothing is prepended to each * line. - * + * * @param data the byte array to be dumped. * @param offset the offset within <i>data</i> to start from. * @param length the number of bytes to dump. @@ -433,7 +433,7 @@ public class Util /** * Returns a string of 2 hexadecimal digits (most significant digit first) * corresponding to the lowest 8 bits of <code>n</code>. - * + * * @param n the byte value to convert. * @return a string of 2 hex characters representing the input. */ @@ -449,7 +449,7 @@ public class Util * '.' (dot) shall be used instead of "+' (plus). * <p> * Used by SASL password file manipulation primitives. - * + * * @param buffer an arbitrary sequence of bytes to represent in Base-64. * @return unpadded (without the '=' character(s)) Base-64 representation of * the input. @@ -525,7 +525,7 @@ public class Util * <p> * Converts a string representing the encoding of some bytes in Base-64 to * their original form. - * + * * @param str the Base-64 encoded representation of some byte(s). * @return the bytes represented by the <code>str</code>. * @throws NumberFormatException if <code>str</code> is <code>null</code>, @@ -597,7 +597,7 @@ public class Util * Treats the input as the MSB representation of a number, and discards * leading zero elements. For efficiency, the input is simply returned if no * leading zeroes are found. - * + * * @param n the {@link BigInteger} to trim. * @return the byte array representation of the designated {@link BigInteger} * with no leading 0-bytes. @@ -618,7 +618,7 @@ public class Util /** * Returns a hexadecimal dump of the trimmed bytes of a {@link BigInteger}. - * + * * @param x the {@link BigInteger} to display. * @return the string representation of the designated {@link BigInteger}. */ diff --git a/libjava/classpath/gnu/java/security/x509/X509CRLSelectorImpl.java b/libjava/classpath/gnu/java/security/x509/X509CRLSelectorImpl.java index 0ada5501689..582d18583f7 100644 --- a/libjava/classpath/gnu/java/security/x509/X509CRLSelectorImpl.java +++ b/libjava/classpath/gnu/java/security/x509/X509CRLSelectorImpl.java @@ -135,4 +135,3 @@ public class X509CRLSelectorImpl implements CRLSelector return false; } } - diff --git a/libjava/classpath/gnu/java/security/x509/X509CertSelectorImpl.java b/libjava/classpath/gnu/java/security/x509/X509CertSelectorImpl.java index 36187ad8e64..5201a76b9ef 100644 --- a/libjava/classpath/gnu/java/security/x509/X509CertSelectorImpl.java +++ b/libjava/classpath/gnu/java/security/x509/X509CertSelectorImpl.java @@ -194,4 +194,3 @@ public class X509CertSelectorImpl implements CertSelector return matchIssuer && matchSubject; } } - diff --git a/libjava/classpath/gnu/java/security/x509/ext/CertificatePolicies.java b/libjava/classpath/gnu/java/security/x509/ext/CertificatePolicies.java index c451762f8e0..874b8eeeb51 100644 --- a/libjava/classpath/gnu/java/security/x509/ext/CertificatePolicies.java +++ b/libjava/classpath/gnu/java/security/x509/ext/CertificatePolicies.java @@ -142,7 +142,7 @@ public class CertificatePolicies extends Extension.Value { return policies; } - + /** * Returns the list of policy OIDs, formatted as dotted-decimal strings. * diff --git a/libjava/classpath/gnu/java/security/x509/ext/GeneralName.java b/libjava/classpath/gnu/java/security/x509/ext/GeneralName.java index fbc05339f6d..f399de1b7e0 100644 --- a/libjava/classpath/gnu/java/security/x509/ext/GeneralName.java +++ b/libjava/classpath/gnu/java/security/x509/ext/GeneralName.java @@ -48,7 +48,7 @@ import java.util.Arrays; /** * The GeneralName structure from X.509. - * + * * <pre> GeneralName ::= CHOICE { otherName [0] OtherName, @@ -87,12 +87,12 @@ public class GeneralName registeredId (8); private int tag; - + private Kind(int tag) { this.tag = tag; } - + public static Kind forTag(final int tag) { switch (tag) @@ -107,10 +107,10 @@ public class GeneralName case 7: return iPAddress; case 8: return registeredId; } - + throw new IllegalArgumentException("invalid tag: " + tag); } - + public int tag() { return tag; @@ -120,17 +120,17 @@ public class GeneralName private final Kind kind; private final byte[] name; private final byte[] encoded; - + public GeneralName(byte[] encoded) throws IOException { DERReader reader = new DERReader(encoded); DERValue value = reader.read(); - + if (value.getTagClass() != DER.CONTEXT) throw new IOException("malformed GeneralName"); - + this.encoded = value.getEncoded(); - + kind = Kind.forTag(value.getTag()); switch (kind) { @@ -176,29 +176,29 @@ public class GeneralName name = value.getEncoded(); name[0] = DER.OBJECT_IDENTIFIER; break; - + default: name = null; // Not reached. } } - + public GeneralName(Kind kind, byte[] name) { this.kind = kind; this.name = (byte[]) name.clone(); this.encoded = null; } - + public Kind kind() { return kind; } - + public byte[] name() { return (byte[]) name.clone(); } - + public byte[] encoded() { try @@ -210,7 +210,7 @@ public class GeneralName return null; } } - + public boolean equals(Object o) { try @@ -223,7 +223,7 @@ public class GeneralName return false; } } - + public String toString() { return (super.toString() + " [ kind=" + kind + "; name=" + diff --git a/libjava/classpath/gnu/java/security/x509/ext/GeneralSubtree.java b/libjava/classpath/gnu/java/security/x509/ext/GeneralSubtree.java index 5f6ffd98701..5d688deaab2 100644 --- a/libjava/classpath/gnu/java/security/x509/ext/GeneralSubtree.java +++ b/libjava/classpath/gnu/java/security/x509/ext/GeneralSubtree.java @@ -1,4 +1,4 @@ -/* GeneralSubtree.java -- +/* GeneralSubtree.java -- Copyright (C) 2006 Free Software Foundation, Inc. This file is a part of GNU Classpath. @@ -63,20 +63,20 @@ public class GeneralSubtree private final GeneralName base; private final int minimum; private final int maximum; - + public GeneralSubtree(byte[] encoded) throws IOException { DERReader reader = new DERReader(encoded); DERValue generalSubtree = reader.read(); - + if (!generalSubtree.isConstructed()) throw new IOException("malformed GeneralSubtree"); - + DERValue generalName = reader.read(); base = new GeneralName(generalName.getEncoded()); if (generalName.isConstructed()) reader.skip(generalName.getLength()); - + int len = generalName.getEncodedLength(); if (len < generalSubtree.getLength()) { @@ -116,7 +116,7 @@ public class GeneralSubtree maximum = -1; } } - + /** * Returns the base name. * @@ -126,7 +126,7 @@ public class GeneralSubtree { return base; } - + /** * Returns the minimum base distance, possibly zero. * @@ -136,7 +136,7 @@ public class GeneralSubtree { return minimum; } - + /** * Returns the maximum base distance, or -1 if this value was not specified. * @@ -146,7 +146,7 @@ public class GeneralSubtree { return maximum; } - + public String toString() { return (GeneralSubtree.class.getName() + " [ base=" + base diff --git a/libjava/classpath/gnu/java/security/x509/ext/NameConstraints.java b/libjava/classpath/gnu/java/security/x509/ext/NameConstraints.java index 607c4296642..8f374d560ff 100644 --- a/libjava/classpath/gnu/java/security/x509/ext/NameConstraints.java +++ b/libjava/classpath/gnu/java/security/x509/ext/NameConstraints.java @@ -51,7 +51,7 @@ import java.util.List; /** * The NameConstraints extension. From RFC 3280, section 4.2.1.11, this * extension is defined as: - * + * * <pre> id-ce-nameConstraints OBJECT IDENTIFIER ::= { id-ce 30 } @@ -68,29 +68,29 @@ import java.util.List; BaseDistance ::= INTEGER (0..MAX) </pre> - * + * * See also the classes {@link GeneralNames} and {@link GeneralSubtree}. - * + * * @author csm */ public class NameConstraints extends Value { public static final OID ID = new OID("2.5.29.30"); - + private List<GeneralSubtree> permittedSubtrees; private List<GeneralSubtree> excludedSubtrees; - + public NameConstraints(byte[] encoded) throws IOException { super(encoded); - + DERReader der = new DERReader(encoded); DERValue value = der.read(); if (!value.isConstructed()) { throw new IOException("malformed NameConstraints"); } - + permittedSubtrees = new LinkedList<GeneralSubtree>(); excludedSubtrees = new LinkedList<GeneralSubtree>(); int len = 0; @@ -108,7 +108,7 @@ public class NameConstraints extends Value len2 += subtree.getEncodedLength(); } len += subtrees.getEncodedLength(); - + if (len < value.getLength()) { subtrees = der.read(); @@ -134,24 +134,24 @@ public class NameConstraints extends Value excludedSubtrees.add(new GeneralSubtree(subtree.getEncoded())); der.skip(subtree.getLength()); len2 += subtree.getEncodedLength(); - } + } } else throw new IOException("unexpected tag " + subtrees.getTag() + " (expecting 0 or 1)"); } } - + public List<GeneralSubtree> permittedSubtrees() { return Collections.unmodifiableList(permittedSubtrees); } - + public List<GeneralSubtree> excludedSubtrees() { return Collections.unmodifiableList(excludedSubtrees); } - + public String toString() { return NameConstraints.class.getName() + " [ permittedSubtrees=" |