-
Notifications
You must be signed in to change notification settings - Fork 4.9k
don't close connection for responses to session based authentication and 100Continue #38744
Conversation
src/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/HttpConnection.cs
Show resolved
Hide resolved
I pushed another update to process sendRequestContentTask (if needed) after processing response headers. In normal case, we should either get 100 response or timer will kick in for sending request body. So the slight delay for paring response headers should not matter. That seems better choice than special case 401 handling. It seems like I missed this originally as our tests cannot distinguish between cases when we send response by timer or because of response logic. It would be great if @davidsh can help with validation in enterprise auth setup. |
src/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/AuthenticationHelper.cs
Outdated
Show resolved
Hide resolved
src/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/HttpConnection.cs
Outdated
Show resolved
Hide resolved
src/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/HttpConnection.cs
Show resolved
Hide resolved
src/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/HttpConnection.cs
Outdated
Show resolved
Hide resolved
/azp run |
Azure Pipelines successfully started running 4 pipeline(s). |
I am going to run a few more validations of this. I think this is an important fix for .NET Core 3.0. |
As this is such a small fix, could this be back ported to .NET Core 2.1 as it's the current LTS release? |
Yes. I think this meets the bar for a .NET Core 2.1/2.2 servicing fix. |
CI failures appear unrelated. |
…tinue Port fix from PR dotnet#38744 (.NET Core 3.0) to release/2.1 LTS branch. Fixes #30760
Port fix from PR dotnet#38744 (.NET Core 3.0) to release/2.1 LTS branch. Fixes #30760
…and 100-Continue (dotnet/corefx#38744) * don't close connection for responses to session based authenticatin * move sendRequestContentTask * feedback from review Commit migrated from dotnet/corefx@2e73965
This is minimal fix. We don't have unit test infrastructure for NTLM/NEGO authentication so I tested this with my real server on Windows.
I talked with @mconnew about possible optimizations but they are somewhat difficult because of layering in SocketHttpHandler. With window for 3.0 closing, I'm proposing this change to make it work, even if we may need to send more data and we can possibly improve it post 3.0.
fixes #30760