mirror of
https://github.com/rommapp/romm.git
synced 2026-11-29 01:58:41 +01:00
Addresses the two open review findings on the credential-change path. The endpoint was sequencing two Redis revocations around the database write itself, reaching past the handler layer into the session middleware. The whole sequence now lives in `auth_handler`, so the endpoint validates, calls a handler and serializes, as the rest of the backend does. The second revocation runs after the write has committed, so raising from it reported a failed change that had in fact succeeded, and an operator could not tell the two apart. It is now logged instead, naming the account and warning that a session created during the update may still be live. The first revocation still raises, because it has a write to abort. `set_user_new_password` (the forgot-password path) goes through the same helper, which gives it the pre-write pass it did not have: an unreachable Redis there used to change the password and leave the account's sessions live. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SPpv6W2ygP9tQ61fTQxdYp