backend: Keycloak token verification and sign-in #10

Open
opened 2026-11-15 22:24:07 -05:00 by forgejo_admin · 0 comments
Owner
  • Verify access tokens against the public realm JWKS (audience dongba), rgxr's oidc.rs as reference
  • First request of a sid calls sp_sign_in(sub, email, name, sid, ...); cache the user per sid
  • GET/PATCH /me, POST /me/sign-out (sp_sign_out), back-channel logout endpoint
  • isAdmin from the realm role dongba-admin (realm_access.roles); admin routes require it
  • nixos repo: client dongba and realm role dongba-admin in tofu/keycloak/public.tf
  • pendingDeletion on /me while a termination is scheduled or appealed

Conventions — CLAUDE.md and PLAN.md at the repo root.

- [ ] Verify access tokens against the public realm JWKS (audience `dongba`), rgxr's oidc.rs as reference - [ ] First request of a `sid` calls `sp_sign_in(sub, email, name, sid, ...)`; cache the user per sid - [ ] `GET/PATCH /me`, `POST /me/sign-out` (`sp_sign_out`), back-channel logout endpoint - [ ] `isAdmin` from the realm role `dongba-admin` (`realm_access.roles`); admin routes require it - [ ] nixos repo: client `dongba` and realm role `dongba-admin` in `tofu/keycloak/public.tf` - [ ] `pendingDeletion` on `/me` while a termination is scheduled or appealed **Conventions** — CLAUDE.md and PLAN.md at the repo root.
forgejo_admin added this to the M1 Core milestone 2026-11-15 22:24:07 -05:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
k8s-services/dongba#10
No description provided.