Repository navigation
Conversation
Administrators can now add and manage the people who sign in to the console, from a Console Users page and from /api/admin-users, instead of with SQL. - User types: Administrator (owner), Read-write (security_admin), Read-only (viewer), or Custom (chosen roles; never owner or admin). - A new user and a password reset get a generated temporary password, shown once, that must be changed at first sign-in. With SSO on, non-administrators sign in with SSO and get no password. - Edit type, roles, email and SSO subject; reset password; disable and enable; delete only once disabled. - An administrator cannot change, disable, reset or delete their own account here, and the last enabled administrator cannot be removed; changes are serialised with an advisory lock. - Role, enabled and password changes end the user's sessions through the existing authorization_version trigger. Every change is strictly audited as admin_user.*; no response or audit row carries a password or hash. Only owner and admin reach the new routes. The rules live in admin/admin_users.py, shared by the API and the pages.
Contributor
Author
|
Landed on main as 803ef07 (squashed; change identical to the PR diff). |
jogunjobi
added a commit
that referenced
this pull request
Oct 16, 2026
Administrators can now add and manage the people who sign in to the console, from a Console Users page and from /api/admin-users, instead of with SQL. - User types: Administrator (owner), Read-write (security_admin), Read-only (viewer), or Custom (chosen roles; never owner or admin). - A new user and a password reset get a generated temporary password, shown once, that must be changed at first sign-in. With SSO on, non-administrators sign in with SSO and get no password. - Edit type, roles, email and SSO subject; reset password; disable and enable; delete only once disabled. - An administrator cannot change, disable, reset or delete their own account here, and the last enabled administrator cannot be removed; changes are serialised with an advisory lock. - Role, enabled and password changes end the user's sessions through the existing authorization_version trigger. Every change is strictly audited as admin_user.*; no response or audit row carries a password or hash. Only owner and admin reach the new routes. The rules live in admin/admin_users.py, shared by the API and the pages.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Second of two PRs (the first, #59, added the viewer role). Feedback from evaluators: after deployment an administrator could not add more console users; the only way was SQL.
What it adds
/api/admin-users: list, add, edit, reset password, disable, enable, delete.owner), Read-write (security_admin), Read-only (viewer), Custom (any of the fine-grained roles; never owner/admin).admin_user.create|update|reset_password|disable|enable|delete, strict (fails closed), before/after summaries with no password, hash or SSO subject.admin/admin_users.py, shared by API and pages. No migration.Tests
test_admin_user_management.py(4 tests): read-only user signs in with the temporary password, is held until they change it, reads pages, is refused writes and console users; read-write user can write but not manage users or map console SSO subjects; disable ends the session; delete needs disable; reset forces a new choice.Docs: rewritten Manage admin users guide (types, one-time password, reset, disable vs delete, guards, SSO, SQL recovery appendix), admin-access link, regenerated admin-roles/admin-api/OpenAPI, CHANGELOG.