feat(auth): close registration after the first user #12

Closed
opened 2026-11-01 16:49:00 +00:00 by jfro · 0 comments
Owner

There's no authorization model: every account can edit sources, AI keys and delete things (router.ex:47-60). With OIDC but not SSO_ONLY, or open registration once email works, any signup is effectively an admin.

Fix for 1.0: allow registration only while no users exist, unless ALLOW_REGISTRATION=true. Hide the register link when closed. (Roles/admin flag can come later; this also shapes #3's per-user API tokens.)

Found in the pre-1.0 gap audit of main @ 69e09f0.

There's no authorization model: every account can edit sources, AI keys and delete things (router.ex:47-60). With OIDC but not SSO_ONLY, or open registration once email works, any signup is effectively an admin. Fix for 1.0: allow registration only while no users exist, unless `ALLOW_REGISTRATION=true`. Hide the register link when closed. (Roles/admin flag can come later; this also shapes #3's per-user API tokens.) Found in the pre-1.0 gap audit of main @ 69e09f0.
jfro added this to the v1.0 milestone 2026-11-01 16:49:00 +00:00
jfro closed this issue 2026-11-01 17:48:13 +00: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.

Dependencies

No dependencies set

Reference
jfro/lamplighter#12
No description provided.