fix(auth): don't read the provider's userinfo endpoint by default

Cloudflare Access answers userinfo without a Content-Type, which the
OpenID Connect handler rejects ("Unknown response type"), so every
sign-in failed after the code exchange. The ID token already carries
sub and email; DorkNet:SignIn:UseUserInfoEndpoint turns the call back
on for providers that need it.
This commit is contained in:
Alexa
2026-10-25 17:24:25 +02:00
parent 99f8c2e016
commit 94781fd11a
3 changed files with 10 additions and 1 deletions
@@ -26,6 +26,12 @@ public sealed class ExternalSignInOptions
public string Scopes { get; set; } = "openid email profile";
/// <summary>Also read the provider's userinfo endpoint after sign-in. Off by
/// default: the ID token already carries <c>sub</c> and <c>email</c>, and
/// Cloudflare Access answers userinfo without a Content-Type, which the
/// OpenID Connect handler rejects.</summary>
public bool UseUserInfoEndpoint { get; set; }
public bool IsConfigured =>
Authority.Length > 0 && ClientId.Length > 0 && ClientSecret.Length > 0;
}