-
Bug
-
Resolution: Fixed
-
P4
-
8, 11, 17, 18
-
b18
-
generic
-
generic
-
Verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8276867 | 17.0.3-oracle | Alex Kasko | P4 | Resolved | Fixed | b01 |
JDK-8276710 | 17.0.2 | Alex Kasko | P4 | Resolved | Fixed | b04 |
JDK-8277898 | 11.0.14 | Alex Kasko | P4 | Resolved | Fixed | b05 |
JDK-8280033 | openjdk8u332 | Alex Kasko | P4 | Resolved | Fixed | b01 |
JDK-8281145 | na | Alex Kasko | P4 | Closed | Duplicate |
Failure example:
java.util.NoSuchElementException
at java.base/java.util.StringTokenizer.nextToken(StringTokenizer.java:347)
at java.base/sun.net.www.protocol.http.HttpURLConnection.doTunneling0(HttpURLConnection.java:2191)
at java.base/sun.net.www.protocol.http.HttpURLConnection.doTunneling(HttpURLConnection.java:2136)
at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:181)
at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1665)
at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1589)
at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:224)
Problem happens because HttpURLConnection#reset() is called on NTLM stage 2 to consume (and discard) NTLMSSP_CHALLENGE response body. But reset() does not discard the body when the request method (of the initial client request) is HEAD. If HTTPS resource is requested (in this case CONNECT request is sent to proxy server to establish TLS tunnel) and NTLMSSP_CHALLENGE response size is larger than a buffer in BufferedInputStream, then status code of the following response (to NTLMSSP_AUTH request) cannot be read (because there is stale data in socket) and authentication fails.
- backported by
-
JDK-8276710 NTLM authentication fails if HEAD request is used
-
- Resolved
-
-
JDK-8276867 NTLM authentication fails if HEAD request is used
-
- Resolved
-
-
JDK-8277898 NTLM authentication fails if HEAD request is used
-
- Resolved
-
-
JDK-8280033 NTLM authentication fails if HEAD request is used
-
- Resolved
-
-
JDK-8281145 NTLM authentication fails if HEAD request is used
-
- Closed
-
- links to
-
Commit openjdk/jdk11u-dev/242bbefe
-
Commit openjdk/jdk17u/de474887
-
Commit openjdk/jdk/3e0d7c33
-
Review openjdk/jdk11u-dev/666
-
Review openjdk/jdk17u/161
-
Review openjdk/jdk/4753