How to design OIDC third-party access, consent, and scopes

Blog post: OIDC third parties: client credentials, consent, and scope design Choose the right grant Use authorization code when an end user delegates access to an application. Use client credentials only when a machine or service acts as itself and no end user is involved. Do not use client_credentials as a shortcut for user-delegated access. Its token subject is the client ID, not a user; downstream services cannot make user-specific authorization decisions from it. ...

December 4, 2026 · 3 min

OIDC edge gateway JWT validation checklist

Blog post: The OIDC edge gateway: validating tokens you did not issue Token validation Resolve discovery and JWKS from the trusted issuer. Validate signature, issuer, expiry, and not-before time. Enforce the route-specific audience and scopes. Return 401 for missing or invalid authentication and 403 for insufficient authorization. Use introspection only where rapid revocation detection is required; cache briefly and fail closed. Trusted identity propagation Strip every client-supplied identity or forwarding header before routing. Derive downstream identity headers only from validated claims, including subject, username, roles, and client ID. Do not forward bearer tokens unless the downstream contract explicitly requires them. ...

December 3, 2026 · 1 min

OIDC public vs confidential clients: security differences

Blog post: The OIDC relying party, built twice Confidential client A server-side application can protect a client secret and keep tokens in a server session. It can authenticate at the token endpoint, receive refresh tokens, validate ID tokens through a mature framework, and perform RP-initiated logout with an id_token_hint. Public client Browser and native clients cannot protect a secret. Use authorization code with PKCE and register clientAuthenticationMethod: none. The client must: ...

December 3, 2026 · 1 min

Spring Authorization Server production checklist

Blog post: Spring Authorization Server: from zero to a working OIDC provider Protocol surface Verify discovery, authorization, token, JWKS, introspection, revocation, and UserInfo endpoints. Enable only the grant types and scopes each registered client needs. Persistence Back these contracts with durable storage: RegisteredClientRepository OAuth2AuthorizationService OAuth2AuthorizationConsentService UserDetailsService Manage schemas with migrations and refuse production startup when required secrets or database settings are absent. Security checklist Persist RSA or EC signing keys and rotate them without dropping still-valid public keys. Map sub to an immutable UUID, not a username. Keep browser login and consent routes session-based with CSRF protection. Keep token and administrative APIs stateless with explicit 401 responses. Prefer client_secret_basic; avoid client_secret_post logging exposure. Require PKCE for public clients. Rate-limit credential-bearing endpoints. Use separate development seed data and production configuration. End-to-end verification Complete a full authorization-code roundtrip, validate the ID token, call UserInfo, refresh where permitted, revoke the token, and confirm the revoked credential is rejected.

December 3, 2026 · 1 min

What an OIDC provider must implement beyond protocol endpoints

Blog post: Building your own OIDC provider Problem OIDC endpoint support is only the protocol core. A production-shaped provider must also make identity, keys, clients, consent, tokens, and operations durable and secure. Responsibilities Publish discovery metadata and JWKS. Implement authorization code with PKCE, refresh token, and client credentials where appropriate. Persist registered clients, authorizations, consents, users, and authorities. Use an immutable identifier for sub; keep mutable usernames in a separate claim. Persist and rotate signing keys while retaining keys needed to validate existing tokens. Separate browser/session security from stateless protocol and administrative APIs. Restrict client authentication methods and avoid secrets in request bodies. Rate-limit login, token, introspection, and user-info endpoints. Provide revocation, health probes, audit logs, and explicit production startup validation. Gotchas A provider that generates a signing key at every restart invalidates tokens in flight. Disabling CSRF globally to simplify token endpoints also weakens browser-facing session routes. Treat these as separate security domains.

December 3, 2026 · 1 min