Use HTTP Host header for Kerberos auth SPN calculation (dotnet/corefx#38465)
authorDavid Shulman <david.shulman@microsoft.com>
Wed, 12 Jun 2019 02:53:55 +0000 (19:53 -0700)
committerGitHub <noreply@github.com>
Wed, 12 Jun 2019 02:53:55 +0000 (19:53 -0700)
commit78c12983dd1abdff41bb4d7370a151701107cee9
tree426cfa66aed424e636951a077848fe2192cf44d9
parent749b2c80db9726f2a096462ed75f57fd99d21e7d
Use HTTP Host header for Kerberos auth SPN calculation (dotnet/corefx#38465)

Fixed SocketsHttpHandler so that it will use the request's Host header,
if present, as part of building the Service Principal Name (SPN) when
doing Kerberos authentication. This now matches .NET Framework behavior.

Contributes to dotnet/corefx#34697 and dotnet/corefx#27745

Commit migrated from https://github.com/dotnet/corefx/commit/6cb854630083aac733d5b8001b266b872b56748e
src/libraries/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/AuthenticationHelper.NtAuth.cs
src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Authentication.cs