mirror of
https://github.com/HeyPuter/puter.git
synced 2026-05-28 20:31:16 +00:00
1f1149e32e
Add a default-on email confirmation gate that rejects users with `requires_email_confirmation && !email_confirmed` on all authenticated routes, returning 403 with `email_confirmation_required`. Previously this was only enforced client-side via a GUI modal, meaning direct API calls could bypass the check entirely. Essential routes are exempted via `allowUnconfirmed: true`: `/whoami`, `/logout`, `/send-confirm-email`, `/confirm-email`, `/save_account`, `/get-anticsrf-token`, `/get-gui-token`, `/session/sync-cookie`, `/auth/revoke-session`, `/user-protected/delete-own-user` No impact on temp users (`requires_email_confirmation` is false), self-hosted deployments without email (flag is never set), or unauthenticated routes (login, signup, password recovery, OIDC). Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>