Skip to content
Permalink
Browse files

8241761: Typos: empty lines in javadoc, inconsistent indents, etc. (s…

…ecurity-libs only)

Reviewed-by: weijun
  • Loading branch information
Ivan Gerasimov committed Apr 2, 2020
1 parent cc25927 commit 3790e58090be25421e3e323eb29deea100b7608c
Showing with 606 additions and 620 deletions.
  1. +23 −23 src/java.base/macosx/classes/apple/security/KeychainStore.java
  2. +5 −5 src/java.base/share/classes/com/sun/crypto/provider/ChaCha20Poly1305Parameters.java
  3. +2 −2 src/java.base/share/classes/com/sun/crypto/provider/FeedbackCipher.java
  4. +2 −2 src/java.base/share/classes/com/sun/crypto/provider/PBES1Core.java
  5. +2 −2 src/java.base/share/classes/com/sun/crypto/provider/PBEWithMD5AndDESCipher.java
  6. +2 −2 src/java.base/share/classes/com/sun/crypto/provider/PBEWithMD5AndTripleDESCipher.java
  7. +5 −5 src/java.base/share/classes/java/security/BasicPermission.java
  8. +2 −2 src/java.base/share/classes/java/security/KeyFactorySpi.java
  9. +3 −3 src/java.base/share/classes/java/security/KeyManagementException.java
  10. +3 −3 src/java.base/share/classes/java/security/KeyPair.java
  11. +2 −2 src/java.base/share/classes/java/security/PrivateKey.java
  12. +1 −1 src/java.base/share/classes/java/security/Provider.java
  13. +5 −5 src/java.base/share/classes/java/security/Security.java
  14. +5 −8 src/java.base/share/classes/java/security/SecurityPermission.java
  15. +2 −2 src/java.base/share/classes/java/security/Signer.java
  16. +2 −2 src/java.base/share/classes/java/security/cert/CRLException.java
  17. +2 −2 src/java.base/share/classes/java/security/cert/PKIXParameters.java
  18. +4 −4 src/java.base/share/classes/java/security/interfaces/RSAMultiPrimePrivateCrtKey.java
  19. +2 −2 src/java.base/share/classes/java/security/interfaces/RSAPrivateCrtKey.java
  20. +2 −2 src/java.base/share/classes/java/security/spec/RSAPrivateCrtKeySpec.java
  21. +2 −2 src/java.base/share/classes/javax/crypto/ExemptionMechanism.java
  22. +2 −2 src/java.base/share/classes/javax/crypto/spec/RC2ParameterSpec.java
  23. +2 −2 src/java.base/share/classes/javax/crypto/spec/RC5ParameterSpec.java
  24. +2 −2 src/java.base/share/classes/javax/crypto/spec/SecretKeySpec.java
  25. +2 −2 src/java.base/share/classes/javax/net/ssl/KeyManagerFactory.java
  26. +1 −2 src/java.base/share/classes/javax/security/auth/x500/X500PrivateCredential.java
  27. +2 −2 src/java.base/share/classes/sun/security/provider/SunEntries.java
  28. +2 −2 src/java.base/share/classes/sun/security/provider/certpath/CertId.java
  29. +2 −2 src/java.base/share/classes/sun/security/ssl/CertificateVerify.java
  30. +1 −1 src/java.base/share/classes/sun/security/ssl/SSLSessionImpl.java
  31. +2 −2 src/java.base/share/classes/sun/security/x509/AlgorithmId.java
  32. +1 −1 src/java.base/share/classes/sun/security/x509/DNSName.java
  33. +3 −3 src/java.base/share/classes/sun/security/x509/DeltaCRLIndicatorExtension.java
  34. +1 −1 src/java.base/share/classes/sun/security/x509/ExtendedKeyUsageExtension.java
  35. +3 −3 src/java.base/share/classes/sun/security/x509/FreshestCRLExtension.java
  36. +3 −3 src/java.base/share/classes/sun/security/x509/IssuingDistributionPointExtension.java
  37. +10 −10 src/java.security.jgss/share/classes/javax/security/auth/kerberos/KerberosKey.java
  38. +7 −7 src/java.security.jgss/share/classes/sun/security/jgss/krb5/Krb5Context.java
  39. +7 −13 src/java.security.jgss/share/classes/sun/security/krb5/internal/HostAddress.java
  40. +8 −9 src/java.security.jgss/share/classes/sun/security/krb5/internal/HostAddresses.java
  41. +10 −10 src/java.security.sasl/share/classes/com/sun/security/sasl/ClientFactoryImpl.java
  42. +14 −14 src/java.security.sasl/share/classes/com/sun/security/sasl/CramMD5Base.java
  43. +11 −11 src/java.security.sasl/share/classes/com/sun/security/sasl/CramMD5Client.java
  44. +16 −16 src/java.security.sasl/share/classes/com/sun/security/sasl/CramMD5Server.java
  45. +16 −16 src/java.security.sasl/share/classes/com/sun/security/sasl/ExternalClient.java
  46. +15 −15 src/java.security.sasl/share/classes/com/sun/security/sasl/PlainClient.java
  47. +9 −9 src/java.security.sasl/share/classes/com/sun/security/sasl/ServerFactoryImpl.java
  48. +62 −62 src/java.security.sasl/share/classes/com/sun/security/sasl/digest/DigestMD5Client.java
  49. +42 −42 src/java.security.sasl/share/classes/com/sun/security/sasl/digest/DigestMD5Server.java
  50. +14 −14 src/java.security.sasl/share/classes/com/sun/security/sasl/digest/FactoryImpl.java
  51. +9 −9 src/java.security.sasl/share/classes/com/sun/security/sasl/digest/SecurityCtx.java
  52. +13 −13 src/java.security.sasl/share/classes/com/sun/security/sasl/ntlm/FactoryImpl.java
  53. +43 −43 src/java.security.sasl/share/classes/com/sun/security/sasl/ntlm/NTLMClient.java
  54. +42 −42 src/java.security.sasl/share/classes/com/sun/security/sasl/ntlm/NTLMServer.java
  55. +11 −11 src/java.security.sasl/share/classes/javax/security/sasl/AuthorizeCallback.java
  56. +9 −9 src/java.security.sasl/share/classes/javax/security/sasl/RealmCallback.java
  57. +9 −9 src/java.security.sasl/share/classes/javax/security/sasl/RealmChoiceCallback.java
  58. +17 −18 src/java.security.sasl/share/classes/javax/security/sasl/SaslClient.java
  59. +27 −27 src/java.security.sasl/share/classes/javax/security/sasl/SaslServer.java
  60. +1 −1 src/jdk.crypto.cryptoki/share/classes/sun/security/pkcs11/wrapper/CK_X9_42_DH1_DERIVE_PARAMS.java
  61. +3 −3 src/jdk.crypto.cryptoki/share/classes/sun/security/pkcs11/wrapper/PKCS11.java
  62. +2 −4 src/jdk.security.auth/share/classes/com/sun/security/auth/callback/TextCallbackHandler.java
  63. +6 −6 src/jdk.security.jgss/share/classes/com/sun/security/sasl/gsskerb/FactoryImpl.java
  64. +40 −40 src/jdk.security.jgss/share/classes/com/sun/security/sasl/gsskerb/GssKrb5Client.java
  65. +26 −26 src/jdk.security.jgss/share/classes/com/sun/security/sasl/gsskerb/GssKrb5Server.java
@@ -127,7 +127,7 @@ private static void permissionCheck() {
public KeychainStore() { }

/**
* Returns the key associated with the given alias, using the given
* Returns the key associated with the given alias, using the given
* password to recover it.
*
* @param alias the alias name
@@ -240,10 +240,10 @@ public Key engineGetKey(String alias, char[] password)
* @param alias the alias name
*
* @return the certificate chain (ordered with the user's certificate first
* and the root certificate authority last), or null if the given alias
* and the root certificate authority last), or null if the given alias
* does not exist or does not contain a certificate chain (i.e., the given
* alias identifies either a <i>trusted certificate entry</i> or a
* <i>key entry</i> without a certificate chain).
* alias identifies either a <i>trusted certificate entry</i> or a
* <i>key entry</i> without a certificate chain).
*/
public Certificate[] engineGetCertificateChain(String alias) {
permissionCheck();
@@ -297,7 +297,7 @@ public Certificate engineGetCertificate(String alias) {
}

/**
* Returns the creation date of the entry identified by the given alias.
* Returns the creation date of the entry identified by the given alias.
*
* @param alias the alias name
*
@@ -321,7 +321,7 @@ public Date engineGetCreationDate(String alias) {
}

/**
* Assigns the given key to the given alias, protecting it with the given
* Assigns the given key to the given alias, protecting it with the given
* password.
*
* <p>If the given key is of type <code>java.security.PrivateKey</code>,
@@ -330,14 +330,14 @@ public Date engineGetCreationDate(String alias) {
*
* <p>If the given alias already exists, the keystore information
* associated with it is overridden by the given key (and possibly
* certificate chain).
* certificate chain).
*
* @param alias the alias name
* @param key the key to be associated with the alias
* @param password the password to protect the key
* @param chain the certificate chain for the corresponding public
* key (only required if the given key is of type
* <code>java.security.PrivateKey</code>).
* <code>java.security.PrivateKey</code>).
*
* @exception KeyStoreException if the given key cannot be protected, or
* this operation fails for some other reason
@@ -391,7 +391,7 @@ public void engineSetKeyEntry(String alias, Key key, char[] password,
}

/**
* Assigns the given key (that has already been protected) to the given
* Assigns the given key (that has already been protected) to the given
* alias.
*
* <p>If the protected key is of type
@@ -403,13 +403,13 @@ public void engineSetKeyEntry(String alias, Key key, char[] password,
*
* <p>If the given alias already exists, the keystore information
* associated with it is overridden by the given key (and possibly
* certificate chain).
* certificate chain).
*
* @param alias the alias name
* @param key the key (in protected format) to be associated with the alias
* @param chain the certificate chain for the corresponding public
* key (only useful if the protected key is of type
* <code>java.security.PrivateKey</code>).
* <code>java.security.PrivateKey</code>).
*
* @exception KeyStoreException if this operation fails.
*/
@@ -449,7 +449,7 @@ public void engineSetKeyEntry(String alias, byte[] key,
}

/**
* Assigns the given certificate to the given alias.
* Assigns the given certificate to the given alias.
*
* <p>If the given alias already exists in this keystore and identifies a
* <i>trusted certificate entry</i>, the certificate associated with it is
@@ -501,7 +501,7 @@ public void engineSetCertificateEntry(String alias, Certificate cert)
}

/**
* Deletes the entry identified by the given alias from this keystore.
* Deletes the entry identified by the given alias from this keystore.
*
* @param alias the alias name
*
@@ -519,7 +519,7 @@ public void engineDeleteEntry(String alias)
}

/**
* Lists all the alias names of this keystore.
* Lists all the alias names of this keystore.
*
* @return enumeration of the alias names
*/
@@ -529,7 +529,7 @@ public void engineDeleteEntry(String alias)
}

/**
* Checks if the given alias exists in this keystore.
* Checks if the given alias exists in this keystore.
*
* @param alias the alias name
*
@@ -541,7 +541,7 @@ public boolean engineContainsAlias(String alias) {
}

/**
* Retrieves the number of entries in this keystore.
* Retrieves the number of entries in this keystore.
*
* @return the number of entries in this keystore
*/
@@ -551,7 +551,7 @@ public int engineSize() {
}

/**
* Returns true if the entry identified by the given alias is a
* Returns true if the entry identified by the given alias is a
* <i>key entry</i>, and false otherwise.
*
* @return true if the entry identified by the given alias is a
@@ -568,7 +568,7 @@ public boolean engineIsKeyEntry(String alias) {
}

/**
* Returns true if the entry identified by the given alias is a
* Returns true if the entry identified by the given alias is a
* <i>trusted certificate entry</i>, and false otherwise.
*
* @return true if the entry identified by the given alias is a
@@ -585,7 +585,7 @@ public boolean engineIsCertificateEntry(String alias) {
}

/**
* Returns the (alias) name of the first keystore entry whose certificate
* Returns the (alias) name of the first keystore entry whose certificate
* matches the given certificate.
*
* <p>This method attempts to match the given certificate with each
@@ -624,7 +624,7 @@ public String engineGetCertificateAlias(Certificate cert) {
}

/**
* Stores this keystore to the given output stream, and protects its
* Stores this keystore to the given output stream, and protects its
* integrity with the given password.
*
* @param stream Ignored. the output stream to which this keystore is written.
@@ -718,7 +718,7 @@ private long addCertificateToKeychain(String alias, Certificate cert) {
private native void _releaseKeychainItemRef(long keychainItemRef);

/**
* Loads the keystore from the Keychain.
* Loads the keystore from the Keychain.
*
* @param stream Ignored - here for API compatibility.
* @param password Ignored - if user needs to unlock keychain Security
@@ -918,7 +918,7 @@ private boolean validateChain(Certificate[] certChain)
}

/*
* Read the authSafe.
* Read the authSafe.
*/
byte[] authSafeData;
ContentInfo authSafe = new ContentInfo(s);
@@ -1003,7 +1003,7 @@ private boolean validateChain(Certificate[] certChain)
}

/*
* Generate PBE Algorithm Parameters
* Generate PBE Algorithm Parameters
*/
private AlgorithmParameters getAlgorithmParameters(String algorithm)
throws IOException
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2018, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -40,9 +40,9 @@
*
* <pre>
* id-alg-AEADChaCha20Poly1305 OBJECT IDENTIFIER ::=
{ iso(1) member-body(2) us(840) rsadsi(113549) pkcs(1)
pkcs9(9) smime(16) alg(3) 18 }
* { iso(1) member-body(2) us(840) rsadsi(113549) pkcs(1)
* pkcs9(9) smime(16) alg(3) 18 }
*
* AEADChaCha20Poly1305Nonce ::= OCTET STRING (SIZE(12))
* </pre>
*
@@ -86,7 +86,7 @@ protected void engineInit(AlgorithmParameterSpec paramSpec)
/**
* Initialize the ChaCha20Poly1305Parameters from a DER encoded
* parameter block.
*
* @param encoded the DER encoding of the nonce as an OCTET STRING.
*
* @throws IOException if the encoded nonce is not 12 bytes long or a DER
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -103,7 +103,7 @@ abstract void init(boolean decrypting, String algorithm, byte[] key,
byte[] iv) throws InvalidKeyException,
InvalidAlgorithmParameterException;

/**
/**
* Gets the initialization vector.
*
* @return the initialization vector
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2002, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2002, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -88,7 +88,7 @@ void setMode(String mode) throws NoSuchAlgorithmException {
cipher.setMode(mode);
}

/**
/**
* Sets the padding mechanism of this cipher. This algorithm only uses
* PKCS #5 padding.
*
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -75,7 +75,7 @@ protected void engineSetMode(String mode) throws NoSuchAlgorithmException {
}
}

/**
/**
* Sets the padding mechanism of this cipher. This algorithm only uses
* PKCS #5 padding.
*
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1998, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1998, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -87,7 +87,7 @@ protected void engineSetMode(String mode) throws NoSuchAlgorithmException {
}
}

/**
/**
* Sets the padding mechanism of this cipher. This algorithm only uses
* PKCS #5 padding.
*
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -311,10 +311,10 @@ final String getCanonicalName() {
private static final long serialVersionUID = 739301742472979399L;

/**
* Key is name, value is permission. All permission objects in
* collection must be of the same type.
* Not serialized; see serialization section at end of class.
*/
* Key is name, value is permission. All permission objects in
* collection must be of the same type.
* Not serialized; see serialization section at end of class.
*/
private transient ConcurrentHashMap<String, Permission> perms;

/**
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -115,7 +115,7 @@ protected abstract PrivateKey engineGeneratePrivate(KeySpec keySpec)
*
* @return the underlying key specification (key material) in an instance
* of the requested specification class.
*
* @throws InvalidKeySpecException if the requested key specification is
* inappropriate for the given key, or the given key cannot be dealt with
* (e.g., the given key has an unrecognized format).
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1996, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1996, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -58,14 +58,14 @@ public KeyManagementException() {
super();
}

/**
/**
* Constructs a KeyManagementException with the specified detail
* message. A detail message is a String that describes this
* particular exception.
*
* @param msg the detail message.
*/
public KeyManagementException(String msg) {
public KeyManagementException(String msg) {
super(msg);
}

@@ -1,5 +1,5 @@
/*
* Copyright (c) 1996, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1996, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -72,12 +72,12 @@ public PublicKey getPublic() {
return publicKey;
}

/**
/**
* Returns a reference to the private key component of this key pair.
*
* @return a reference to the private key.
*/
public PrivateKey getPrivate() {
public PrivateKey getPrivate() {
return privateKey;
}
}
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1996, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1996, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -66,7 +66,7 @@
*
* @deprecated A {@code serialVersionUID} field in an interface is
* ineffectual. Do not use; no replacement.
*/
*/
@Deprecated
@SuppressWarnings("serial")
@java.io.Serial
@@ -287,7 +287,7 @@ protected Provider(String name, String versionStr, String info) {
* @throws UnsupportedOperationException if a configuration argument is
* not supported.
* @throws NullPointerException if the supplied configuration argument is
null.
* null.
* @throws InvalidParameterException if the supplied configuration argument
* is invalid.
* @return a provider configured with the supplied configuration argument.

0 comments on commit 3790e58

Please sign in to comment.