Repository navigation
[M2.2c1-fix] Stop account pre-hijacking through pending registrations - #101
Merged
Merged
Conversation
samuelmbabhazi
force-pushed
the
fix/m2.2-account-pre-hijacking
branch
from
November 5, 2026 13:58
0b9f92d to
ae781ec
Compare
Closed
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.
Task
Review follow-up for #44 (M2.2c1). Refs #21
What changed
API
POST /auth/verifytakes{ token, password }(VerifyEmailDto). Verification checks the password against the stored hash, with Argon2id work outside any lock or transaction. Under the user lock it then rechecks that the hash did not change in the meantime, before consuming the link and activating the account.identity.email_verifiedthenidentity.password_reset), invalidates outstanding verification links, and advances the security version as before.openapi.jsonand the api-client regenerated.Web
autocomplete=current-password) and links to password reset for people who did not create the account or forgot the password.Docs and tests
Why
Account pre-hijacking:
[email protected]with their own password. The account stays pending and the verification link goes to the victim.How it was tested
nx run-many -t lint typecheck test build -p web apiin a clean worktree: 12 tasks pass.pnpm gen:openapiandpnpm gen:api-client: the committed output is the regenerated output.Security considerations
POST /auth/verify: the password is now required. Only the bundled web UI calls this endpoint, and it is updated in this PR.verifyattempt limit (per network and account after [M2.2c2-fix] Stop unauthenticated account lockout and key IPv6 by /64 #97). No new enumeration signal: every failure returns the same 401.Checklist