Threat model a password reset flow
Larkhill Pay is adding a self-service password reset. A customer enters an email address, receives a link and sets a new password; support staff can also start a reset from an admin screen. Threat model the flow before it ships.
Rubric and preparationWhat a mid answer covers · 4 lessons to prepare
Mid standard
- A token that can be guessed or reused lets an attacker take over the account, and a token that leaks through logs, referrer headers or a shared inbox does the same. I would require a long random single-use token with a short expiry because a leak then has a small window, and I would invalidate it once used or when a newer one is issued.
- I would give the same response and timing whether or not the account exists, because otherwise the form becomes a way to list customers through enumeration. I would add a rate limit per address and per source and alert on bursts, because the form sends email on demand.
- I would require support to verify identity with a documented check, because a phone call alone can be social engineering. The action needs an audit record naming the agent, the owner should get a notify message at their existing contact, and I would test that a second reset invalidates the first link.