-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Fix WebSockets Negotiate Auth in Kestrel #26480
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Who's the customer? #21886 seems like it's been sitting there a while. |
@vinaykapoor brought this up on https://gitter.im/aspnet/SignalR this morning. Fortunately @BrennanConroy noticed. |
70c69b4
to
5e71ad9
Compare
Ok, it's at least worth asking about for 5.0 then. |
5e71ad9
to
02a2755
Compare
DescriptionThis fixes a bug in Kestrel that prevents WebSocket clients from authenticating using Negotiate Auth. I've copied the Exception you get from
After this change, Kestrel will keep HTTP/1.1 connections open after "Connection: Upgrade" (WebSocket) requests are challenged by Negotiate Auth with a "401 Unauthorized" response. This allows WebSocket clients to authenticate succesfully. Customer ImpactCustomers are unable to use Kestrel if they need to support Windows Auth for WebSocket connections. We first learned about this back in May and it resurfaced when another customer ran into the issue and reported it on https://gitter.im/aspnet/SignalR yesterday. WorkaroundUsing IIS or HttpSysServer instead of Kestrel. Regression?No. RiskLow. This PR allows some HTTP/1.1 connections to stay open in very specific circumstances where they should not have been prematurely closed. These connections are still tracked and subject to Kestrel's normal keep-alive timeout. |
Hello human! Please make sure you've included the Shiproom Template in a comment or (preferably) the PR description. Also, make sure this PR is not marked as a draft and is ready-to-merge. |
02a2755
to
d46f1ea
Compare
Approved over email. |
Addresses #21886