RFR: 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect comment information

2024-01-31 Thread SendaoYan
8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect comment information - Commit messages: - 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect comment information Changes: https://git.openjdk.org/jdk/pull/17646/files Webrev: h

Re: RFR: 8324585: JVM native memory leak in PCKS11-NSS security provider [v2]

2024-01-31 Thread Daniel Jeliński
> Please review this patch that fixes a memory leak in P11TlsPrfGenerator, > which is triggered during TLS1.2 Finished message generation and verification. > > The patch changes C_SignInit JNI method to free the mechanism data > immediately after use. This matches the behavior of other Init meth

Re: RFR: 8324585: JVM native memory leak in PCKS11-NSS security provider

2024-01-31 Thread Daniel Jeliński
On Fri, 26 Jan 2024 10:04:11 GMT, Daniel Jeliński wrote: > Please review this patch that fixes a memory leak in P11TlsPrfGenerator, > which is triggered during TLS1.2 Finished message generation and verification. > > The patch changes C_SignInit JNI method to free the mechanism data > immediat

Re: RFR: 8320362: Load anchor certificates from Keychain keystore [v4]

2024-01-31 Thread Weijun Wang
On Thu, 25 Jan 2024 22:01:48 GMT, Alexey Bakhtin wrote: >> Please review the proposed fix. >> >> The patch loads system root certificates from the MacOS Keychain with >> TrustSettings. >> It allows to build a trusted certificate path using the MacOS Keychain store >> only. > > Alexey Bakhtin h

Re: RFR: 8320362: Load anchor certificates from Keychain keystore [v4]

2024-01-31 Thread Weijun Wang
On Thu, 25 Jan 2024 22:01:48 GMT, Alexey Bakhtin wrote: >> Please review the proposed fix. >> >> The patch loads system root certificates from the MacOS Keychain with >> TrustSettings. >> It allows to build a trusted certificate path using the MacOS Keychain store >> only. > > Alexey Bakhtin h

Re: RFR: 8325022: Incorrect error message on TLS 1.2 client authentication

2024-01-31 Thread Jamil Nimeh
On Wed, 31 Jan 2024 07:42:32 GMT, John Jiang wrote: > If the server doesn't receive the client certificate for required client > authentication, it should raise error `Empty client certificate chain`. Looks good. - Marked as reviewed by jnimeh (Reviewer). PR Review: https://git.o

Re: RFR: 8325022: Incorrect error message on TLS 1.2 client authentication

2024-01-31 Thread Hai-May Chao
On Wed, 31 Jan 2024 07:42:32 GMT, John Jiang wrote: > If the server doesn't receive the client certificate for required client > authentication, it should raise error `Empty client certificate chain`. Marked as reviewed by hchao (Committer). LGTM - PR Review: https://git.openjdk.

Re: RFR: 8324648: Avoid NoSuchMethodError when instantiating NativePRNG

2024-01-31 Thread Weijun Wang
On Wed, 24 Jan 2024 15:42:05 GMT, Oli Gillespie wrote: > A typical call to `new SecureRandom()` is slowed down by looking for a > constructor in NativePRNG which takes `java.security.SecureRandomParameters`. > NativePRNG does not have such a constructor, so the search fails > [here](https://gi

Re: RFR: 8324646: Avoid Class.forName in SecureRandom constructor [v2]

2024-01-31 Thread Weijun Wang
On Wed, 24 Jan 2024 18:05:50 GMT, Oli Gillespie wrote: >> Avoid expensive `Class.forName` call when constructing Providers such as >> `SecureRandom` which take constructor parameters. This can easily be cached >> in EngineDescription (this cache already existed before, it was removed in >> [JD

Re: RFR: 8325022: Incorrect error message on TLS 1.2 client authentication

2024-01-31 Thread Daniel Jeliński
On Wed, 31 Jan 2024 07:42:32 GMT, John Jiang wrote: > If the server doesn't receive the client certificate for required client > authentication, it should raise error `Empty client certificate chain`. Looks good, but could you also fix the messages on line 406 and 1227? - Marked a

Re: RFR: 8324646: Avoid Class.forName in SecureRandom constructor [v2]

2024-01-31 Thread Oli Gillespie
On Wed, 31 Jan 2024 17:23:42 GMT, Weijun Wang wrote: > How about just using class literals? There is no need to call > `Class.forName`, at least not now since they are all inside `java.base`. Thanks :). That seems sensible if writing from scratch, but that part I'm just reviving from [JDK-8280

Re: RFR: 8324646: Avoid Class.forName in SecureRandom constructor [v2]

2024-01-31 Thread Valerie Peng
On Wed, 24 Jan 2024 18:05:50 GMT, Oli Gillespie wrote: >> Avoid expensive `Class.forName` call when constructing Providers such as >> `SecureRandom` which take constructor parameters. This can easily be cached >> in EngineDescription (this cache already existed before, it was removed in >> [JD

Re: RFR: 8324648: Avoid NoSuchMethodError when instantiating NativePRNG

2024-01-31 Thread Oli Gillespie
On Wed, 24 Jan 2024 15:42:05 GMT, Oli Gillespie wrote: > A typical call to `new SecureRandom()` is slowed down by looking for a > constructor in NativePRNG which takes `java.security.SecureRandomParameters`. > NativePRNG does not have such a constructor, so the search fails > [here](https://gi

Re: RFR: 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect comment information

2024-01-31 Thread Jamil Nimeh
On Wed, 31 Jan 2024 08:19:55 GMT, SendaoYan wrote: > 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect > comment information Looks good, but please label the JBS bug with noreg-trivial. - Marked as reviewed by jnimeh (Reviewer). PR Review: https://git.

Re: RFR: 8324646: Avoid Class.forName in SecureRandom constructor [v2]

2024-01-31 Thread Oli Gillespie
On Wed, 24 Jan 2024 18:05:50 GMT, Oli Gillespie wrote: >> Avoid expensive `Class.forName` call when constructing Providers such as >> `SecureRandom` which take constructor parameters. This can easily be cached >> in EngineDescription (this cache already existed before, it was removed in >> [JD

Re: RFR: 8324646: Avoid Class.forName in SecureRandom constructor [v2]

2024-01-31 Thread Weijun Wang
On Wed, 24 Jan 2024 18:05:50 GMT, Oli Gillespie wrote: >> Avoid expensive `Class.forName` call when constructing Providers such as >> `SecureRandom` which take constructor parameters. This can easily be cached >> in EngineDescription (this cache already existed before, it was removed in >> [JD

Re: RFR: 8265372: Simplify PKCS9Attribute [v6]

2024-01-31 Thread Ben Perez
> Refactored PKCS9Attribute to use a hash map instead of multiple arrays. The > key for the hash map is an `ObjectIdentifier` and the values are a record > `AttributeInfo` that stores the information previously contained in the > arrays `PKCS9_VALUE_TAGS`, `VALUE_CLASSES`, and `SINGLE_VALUED`.

Re: RFR: 8265372: Simplify PKCS9Attribute [v7]

2024-01-31 Thread Ben Perez
> Refactored PKCS9Attribute to use a hash map instead of multiple arrays. The > key for the hash map is an `ObjectIdentifier` and the values are a record > `AttributeInfo` that stores the information previously contained in the > arrays `PKCS9_VALUE_TAGS`, `VALUE_CLASSES`, and `SINGLE_VALUED`.

Re: RFR: 8265372: Simplify PKCS9Attribute [v7]

2024-01-31 Thread Weijun Wang
On Wed, 31 Jan 2024 18:18:30 GMT, Ben Perez wrote: >> Refactored PKCS9Attribute to use a hash map instead of multiple arrays. The >> key for the hash map is an `ObjectIdentifier` and the values are a record >> `AttributeInfo` that stores the information previously contained in the >> arrays `P

Re: RFR: 8324646: Avoid Class.forName in SecureRandom constructor [v2]

2024-01-31 Thread Valerie Peng
On Wed, 24 Jan 2024 18:05:50 GMT, Oli Gillespie wrote: >> Avoid expensive `Class.forName` call when constructing Providers such as >> `SecureRandom` which take constructor parameters. This can easily be cached >> in EngineDescription (this cache already existed before, it was removed in >> [JD

Re: RFR: 8325022: Incorrect error message on client authentication [v2]

2024-01-31 Thread John Jiang
> If the server doesn't receive the client certificate for required client > authentication, it should raise error `Empty client certificate chain`. John Jiang has updated the pull request incrementally with one additional commit since the last revision: fix more error messages -

Re: RFR: 8325022: Incorrect error message on client authentication [v2]

2024-01-31 Thread Daniel Jeliński
On Wed, 31 Jan 2024 20:07:28 GMT, John Jiang wrote: >> If the server doesn't receive the client certificate for required client >> authentication, it should raise error `Empty client certificate chain`. > > John Jiang has updated the pull request incrementally with one additional > commit since

Re: RFR: 8325022: Incorrect error message on client authentication [v2]

2024-01-31 Thread Bernd
On Wed, 31 Jan 2024 20:07:28 GMT, John Jiang wrote: >> If the server doesn't receive the client certificate for required client >> authentication, it should raise error `Empty client certificate chain`. > > John Jiang has updated the pull request incrementally with one additional > commit since

Re: RFR: 8265372: Simplify PKCS9Attribute [v8]

2024-01-31 Thread Ben Perez
> Refactored PKCS9Attribute to use a hash map instead of multiple arrays. The > key for the hash map is an `ObjectIdentifier` and the values are a record > `AttributeInfo` that stores the information previously contained in the > arrays `PKCS9_VALUE_TAGS`, `VALUE_CLASSES`, and `SINGLE_VALUED`.

Re: RFR: 8320362: Load anchor certificates from Keychain keystore [v5]

2024-01-31 Thread Alexey Bakhtin
> Please review the proposed fix. > > The patch loads system root certificates from the MacOS Keychain with > TrustSettings. > It allows to build a trusted certificate path using the MacOS Keychain store > only. Alexey Bakhtin has updated the pull request incrementally with one additional comm

Re: RFR: 8320362: Load anchor certificates from Keychain keystore [v4]

2024-01-31 Thread Alexey Bakhtin
On Wed, 31 Jan 2024 15:33:28 GMT, Weijun Wang wrote: > Do you intend to call `addIdentitiesToKeystore` for both store types? Yes, you are right. Thank you. We do not need private identities in the root keystore. Updated - PR Comment: https://git.openjdk.org/jdk/pull/16722#issuecom

Re: RFR: 8320362: Load anchor certificates from Keychain keystore [v4]

2024-01-31 Thread Alexey Bakhtin
On Wed, 31 Jan 2024 15:08:09 GMT, Weijun Wang wrote: > Great! The change looks good. Can you manage to add a test? Maybe try to load > both store types. Make sure they have different contents and not empty (?). Thank you. I have updated `java/security/KeyStore/CheckMacOSKeyChainTrust.java` tes

Re: RFR: 8324585: JVM native memory leak in PCKS11-NSS security provider [v2]

2024-01-31 Thread Valerie Peng
On Wed, 31 Jan 2024 10:23:22 GMT, Daniel Jeliński wrote: >> Please review this patch that fixes a memory leak in P11TlsPrfGenerator, >> which is triggered during TLS1.2 Finished message generation and >> verification. >> >> The patch changes C_SignInit JNI method to free the mechanism data >>

Re: RFR: 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect comment information

2024-01-31 Thread SendaoYan
On Wed, 31 Jan 2024 17:48:19 GMT, Jamil Nimeh wrote: > Looks good, but please label the JBS bug with noreg-trivial. Done - PR Comment: https://git.openjdk.org/jdk/pull/17646#issuecomment-1920357757

Re: RFR: 8325022: Incorrect error message on client authentication [v2]

2024-01-31 Thread John Jiang
On Wed, 31 Jan 2024 20:43:31 GMT, Bernd wrote: >> John Jiang has updated the pull request incrementally with one additional >> commit since the last revision: >> >> fix more error messages > > src/java.base/share/classes/sun/security/ssl/CertificateMessage.java line 389: > >> 387:

Integrated: 8325022: Incorrect error message on client authentication

2024-01-31 Thread John Jiang
On Wed, 31 Jan 2024 07:42:32 GMT, John Jiang wrote: > If the server doesn't receive the client certificate for required client > authentication, it should raise error `Empty client certificate chain`. This pull request has now been integrated. Changeset: fe78c0f1 Author:John Jiang URL:

Re: RFR: 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect comment information

2024-01-31 Thread Fei Yang
On Wed, 31 Jan 2024 08:19:55 GMT, SendaoYan wrote: > 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect > comment information Marked as reviewed by fyang (Reviewer). Looks good and trivial. - PR Review: https://git.openjdk.org/jdk/pull/17646#pullrequest

Integrated: 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect comment information

2024-01-31 Thread SendaoYan
On Wed, 31 Jan 2024 08:19:55 GMT, SendaoYan wrote: > 8325024: java/security/cert/CertPathValidator/OCSP/OCSPTimeout.java incorrect > comment information This pull request has now been integrated. Changeset: 432756b6 Author:SendaoYan Committer: Fei Yang URL: https://git.openjdk.org