fix(yaiam): check the sign-in cookie and state before discovery

A callback that belongs to no sign-in of this browser is now
ErrSignInState without contacting the provider (before, an unreachable
provider turned it into a discovery error).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
terminarandClaude Opus 5.5 committed 2026-11-20 17:35:15 +01:00
1 parent 376ae3c970
commit 76543b23a0
3 files changed
+19 -5

No files matched your search

+2 -1
View File
@@ -16,7 +16,8 @@
(2026-11-20, first consumer yaemp, replacing go-oidc/oauth2):
`Web.PublicIssuer` (the browser reaches the provider under another
origin), `Client.AllowInsecure` (http off loopback, test installations
only), `email_verified` true only as JSON boolean.
only), `email_verified` true only as JSON boolean; `Callback` checks
the cookie and state before it contacts the provider (v0.5.1).
- [ ] **yaiam: web refresh.** `Web` has no refresh for a confidential
client (Client.Refresh sends no secret); add when an application keeps
access tokens beyond the sign-in.