Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v7]

2022-01-24 Thread Michael McMahon
> Hi, > > This change adds Channel Binding Token (CBT) support to HTTPS > (java.net.HttpsURLConnection) when used with the Negotiate (SPNEGO, Kerberos) > authentication scheme. When enabled, the implementation preemptively includes > a CBT with authentication requests over Kerberos. The feature

RFR: 8065422: Trailing dot in hostname causes TLS handshake to fail with SNI disabled

2022-01-24 Thread Xue-Lei Andrew Fan
A hostname in an URL ending with a dot is valid (See RFC 1034). However, it is not a valid SNI hostname. The ending dot should be ignored while checking the hostname with SNI or the name in a X.509 certificate. The update should be verified with jshell. No new regression test added as there

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v7]

2022-01-24 Thread Weijun Wang
On Mon, 24 Jan 2022 22:11:51 GMT, Michael McMahon wrote: >> Hi, >> >> This change adds Channel Binding Token (CBT) support to HTTPS >> (java.net.HttpsURLConnection) when used with the Negotiate (SPNEGO, >> Kerberos) authentication scheme. When enabled, the implementation >> preemptively inclu

RFR: 8280546: Remove hard-coded 127.0.0.1 loopback address

2022-01-24 Thread Liam Miller-Cushon
This change replaces hard-coded 127.0.0.1 loopback addresses with `InetAddress.getLoopbackAddress().getHostAddress()`, to allow the tests to work on IPv6-only systems. This matches the approach of previous fixes in [JDK-8220083](https://bugs.openjdk.java.net/browse/JDK-8220083). -

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v6]

2022-01-24 Thread Michael McMahon
> Hi, > > This change adds Channel Binding Token (CBT) support to HTTPS > (java.net.HttpsURLConnection) when used with the Negotiate (SPNEGO, Kerberos) > authentication scheme. When enabled, the implementation preemptively includes > a CBT with authentication requests over Kerberos. The feature

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v5]

2022-01-24 Thread Michael McMahon
On Fri, 21 Jan 2022 19:48:02 GMT, Weijun Wang wrote: >> Michael McMahon has updated the pull request incrementally with one >> additional commit since the last revision: >> >> added root cause to NamingException > > src/java.base/share/classes/java/net/doc-files/net-properties.html line 220:

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v6]

2022-01-24 Thread Daniel Fuchs
On Mon, 24 Jan 2022 13:36:47 GMT, Michael McMahon wrote: >> Hi, >> >> This change adds Channel Binding Token (CBT) support to HTTPS >> (java.net.HttpsURLConnection) when used with the Negotiate (SPNEGO, >> Kerberos) authentication scheme. When enabled, the implementation >> preemptively inclu

Re: RFR: 8255739: x509Certificate returns � for invalid subjectAlternativeNames

2022-01-24 Thread Sean Mullan
On Sat, 22 Jan 2022 22:48:29 GMT, Michael StJohns wrote: > I originally started using the BC certificate factory > because the SUN factory didn't understand RSA-OAEP as a key type in > SubjectKeyInfo and I was getting a few of those from a group of TPMs.?? Is that still an issue? I would have ex

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v6]

2022-01-24 Thread Weijun Wang
On Mon, 24 Jan 2022 13:36:47 GMT, Michael McMahon wrote: >> Hi, >> >> This change adds Channel Binding Token (CBT) support to HTTPS >> (java.net.HttpsURLConnection) when used with the Negotiate (SPNEGO, >> Kerberos) authentication scheme. When enabled, the implementation >> preemptively inclu

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v4]

2022-01-24 Thread Weijun Wang
On Fri, 21 Jan 2022 15:40:16 GMT, Daniel Fuchs wrote: >> Michael McMahon has updated the pull request incrementally with one >> additional commit since the last revision: >> >> more tidy-up > > src/java.naming/share/classes/com/sun/jndi/ldap/sasl/LdapSasl.java line 144: > >> 142:

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v6]

2022-01-24 Thread Weijun Wang
On Mon, 24 Jan 2022 13:54:12 GMT, Daniel Fuchs wrote: >> Michael McMahon has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains eight additional >> com

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v6]

2022-01-24 Thread Michael McMahon
On Mon, 24 Jan 2022 15:23:44 GMT, Weijun Wang wrote: >> Michael McMahon has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains eight additional >> comm

Re: RFR: 8273236: keytool does not accurately warn about algorithms that are disabled but have additional constraints [v2]

2022-01-24 Thread Sean Mullan
On Fri, 21 Jan 2022 03:27:44 GMT, Hai-May Chao wrote: >> src/java.base/share/classes/sun/security/tools/keytool/Main.java line 1129: >> >>> 1127: } >>> 1128: >>> 1129: buildTrustedCerts(); >> >> Can we reuse the keystore loaded by `buildTrustedCerts()` instead of >> reloading

Re: RFR: 8273236: keytool does not accurately warn about algorithms that are disabled but have additional constraints [v2]

2022-01-24 Thread Sean Mullan
On Fri, 21 Jan 2022 03:34:24 GMT, Hai-May Chao wrote: >> `keytool` currently uses a simpler scheme in `DisabledAlgorithmConstraints` >> class when performing algorithm constraints checks. This change is to >> enhance `keytool` to make use of the new methods >> `DisabledAlgorithmConstraints.per

Re: RFR: 8279842: HTTPS Channel Binding support for Java GSS/Kerberos [v6]

2022-01-24 Thread Weijun Wang
On Mon, 24 Jan 2022 15:54:01 GMT, Michael McMahon wrote: >> src/java.base/share/classes/sun/security/util/TlsChannelBinding.java line >> 100: >> >>> (failed to retrieve contents of file, check the PR for context) >> I think this method should stay here. Suppose one day the CBT type is >> confi

Re: RFR: 8255739: x509Certificate returns � for invalid subjectAlternativeNames [v2]

2022-01-24 Thread Weijun Wang
On Fri, 14 Jan 2022 11:18:23 GMT, Masanori Yano wrote: >> Could you please review the JDK-8255739 bug fix? >> >> I think sun.security.x509.SubjectAlternativeNameExtension() should throw an >> exception for incorrect SubjectAlternativeNames instead of returning the >> substituted characters, wh

Re: RFR: 8255739: x509Certificate returns � for invalid subjectAlternativeNames

2022-01-24 Thread Michael StJohns
On 1/24/2022 9:51 AM, Sean Mullan wrote: On Sat, 22 Jan 2022 22:48:29 GMT, Michael StJohns wrote: I originally started using the BC certificate factory because the SUN factory didn't understand RSA-OAEP as a key type in SubjectKeyInfo and I was getting a few of those from a group of TPMs.?? I

Re: RFR: 8273236: keytool does not accurately warn about algorithms that are disabled but have additional constraints [v3]

2022-01-24 Thread Hai-May Chao
> `keytool` currently uses a simpler scheme in `DisabledAlgorithmConstraints` > class when performing algorithm constraints checks. This change is to enhance > `keytool` to make use of the new methods > `DisabledAlgorithmConstraints.permits` with `CertPathConstraintsParameters` > and `checkKey`

Re: RFR: 8273236: keytool does not accurately warn about algorithms that are disabled but have additional constraints [v4]

2022-01-24 Thread Hai-May Chao
> `keytool` currently uses a simpler scheme in `DisabledAlgorithmConstraints` > class when performing algorithm constraints checks. This change is to enhance > `keytool` to make use of the new methods > `DisabledAlgorithmConstraints.permits` with `CertPathConstraintsParameters` > and `checkKey`

Re: RFR: 8273236: keytool does not accurately warn about algorithms that are disabled but have additional constraints [v4]

2022-01-24 Thread Hai-May Chao
On Mon, 24 Jan 2022 16:00:14 GMT, Sean Mullan wrote: >> No change. This is because `caks` global variable can only be initialized >> with cacerts keystore when the `trustcacerts` option is specified; >> otherwise if has to be kept null. `buildTrustedCerts`() is always executed. > > I was think

Re: RFR: 8273236: keytool does not accurately warn about algorithms that are disabled but have additional constraints [v2]

2022-01-24 Thread Hai-May Chao
On Mon, 24 Jan 2022 16:12:25 GMT, Sean Mullan wrote: >> Hai-May Chao has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Update with review comments > > src/java.base/share/classes/sun/security/tools/keytool/Main.java line 4908: > >> 4906:

Re: RFR: 8255739: x509Certificate returns � for invalid subjectAlternativeNames [v2]

2022-01-24 Thread Michael StJohns
On 1/24/2022 2:23 PM, Weijun Wang wrote: On Fri, 14 Jan 2022 11:18:23 GMT, Masanori Yano wrote: Could you please review the JDK-8255739 bug fix? I think sun.security.x509.SubjectAlternativeNameExtension() should throw an exception for incorrect SubjectAlternativeNames instead of returning th