-
Notifications
You must be signed in to change notification settings - Fork 598
Should RemoteAuthenticationOptions validate SignInScheme != null? #1378
Comments
Or maybe we removed this validation to enable calling the default sign in scheme... |
Can we also validate and SignInScheme != Scheme, are the schemes stored on the instances of the handlers themselves? |
We will likely have to validate that outside of the normal validation (not AuthenticationSchemeOptions.Validate, but inside of the base RemoteAuthenticationHandler itself to have access to the scheme name, and we'd likely have to also explicitly check for when its the default that fallback to itself as well. |
Exactly what I had recommended here: #1264 (comment)
You can easily do that in Security/src/Microsoft.AspNetCore.Authentication/AuthenticationServiceCollectionExtensions.cs Lines 98 to 101 in 488eb44
|
Related issue to address: Security/src/Microsoft.AspNetCore.Authentication/AuthenticationServiceCollectionExtensions.cs Lines 98 to 101 in 488eb44
There should be an additional ?? _authOptions.DefaultScheme; for when DefaultSignInScheme isn't set. That's what was starting some of the stack overlfows by passing nulls.
|
This should validation was lost at some point, SignInScheme is required for remote auth.
The text was updated successfully, but these errors were encountered: