Uh oh!
There was an error while loading. Please reload this page.
[release/8.0] Do not throw PNSE exception from NegotiateAuthentication constructor - #91753
Conversation
… report Unsupported status instead
ghost
commented
Sep 7, 2023
Tagging subscribers to this area: @dotnet/ncl, @bartonjs, @vcsjones Issue DetailsFixes #91131. This is a stripped down version of PR #91160 with more targeted fix and same unit test. Unlike #91160 it doesn't try to fix which status code is reported and always reports [TBD: Fill in the template; this is currently a draft to get a CI run]
|
Failures are instances of known infra issue #91705 |
rzikm
commented
Sep 8, 2023
/azp run runtime-extra-platforms |
|
Azure Pipelines successfully started running 1 pipeline(s). |
carlossanlop
commented
Sep 11, 2023
@karelz I see you approved this, but then also self-assigned it. Do you want to do something additional with it, or can we add the |
karelz
commented
Sep 12, 2023
@carlossanlop we are still waiting on E2E customer validation - see #91131 (comment) |
karelz
commented
Sep 13, 2023
@artl93 another issue ready for your approval - regression against 7.0 - see context in the template. |
artl93
commented
Sep 13, 2023
M2 Approved. |
rzikm
commented
Sep 14, 2023
Fix confirmed to work, see #91131 (comment) |
Fixes#91131
This is a stripped down version of 9.0 (main) PR #91160 with more targeted fix and same unit test.
Unlike #91160 it doesn't try to fix which status code is reported and always reports
Unsupported. This is in line with the .NET 7 behavior.Customer Impact
Regression against 7.0.
Due to refactoring in the space, on Android and tvOS we started throwing
PlatformNotSupportedExceptionforCredentialCache.DefaultCredentialsinstead of returningStatusCode=HttpStatusCode.Unauthorized(401) as we did in 7.0.For context:
PlatformNotSupportedExceptionfor this case, but it was inconsistent across platforms - it sometimes threwWin32Exceptionor even internalGssApiException.HttpClientto handle these exceptions and return 401 HTTP status code. How it should behave, depends if one looks at it from the low-level API perspective (NegotiateAuthentication), or from higher-level API perspective (HttpClient) - see discussion in Android NTLM: Empty Credentials now throws PlatformNotSupportedException #91131.Testing
Unit test is added to simulate the customer scenario. It fails without the fix and succeeds with it.
E2E validation by customer on private build of 8.0 branch - see #91131 (comment)
Risk
Low
Affects only managed NTLM implementation, which is used only on Android and tvOS. Changes only error handling, not main code path.