Password Reset Vulnerabilities

Password reset flaws let an attacker complete the forgot-password flow for an account they don’t control. The usual causes are a reset token delivered to the attacker, a token that can be guessed or leaked, an account identity taken from the request instead of the token, or a reset endpoint with no verification at all.

How it works

Reset is an unauthenticated feature whose whole job is to hand a credential to someone who can’t prove who they are. It is really four components chained together, and each join can leak (XSSRat):

  1. Request endpoint: takes an identifier and triggers delivery.
    • It can enumerate accounts or leak PII in its response (PII disclosure).
    • It is an unauthenticated input sink, so SQL injection is possible (Metabase).
  2. Token generator: must produce high-entropy, single-use, expiring secrets. Non-cryptographic randomness makes them predictable (Meta Math.random()).
  3. Delivery channel: the reset URL is often built from the request’s Host or X-Forwarded-Host.
    • An attacker requests a reset for the victim with that header pointing at their own domain. The genuine email then carries a valid token to the attacker’s host, and one click by the victim leaks it. This is reset poisoning (1-click ATO, X-Forwarded-Host).
    • Forwarded headers are only trustworthy from a trusted proxy (X-Forwarded-Host).
  4. Consumption endpoint: must derive the account from the token.
    • If it trusts a client-supplied user_id or email, any token resets any account (User_Id).
    • Short numeric codes need attempt limits that hold up under concurrency, distributed sources and request batching (Instagram, GraphQL aliases).

Tokens also leak sideways. Query and filter frameworks can expose reset_password_token through attribute predicates, which allows character-by-character extraction (Ransack). GraphQL queries can return reset records directly (GraphQL mass ATO).

After a reset, existing sessions and refresh tokens must die. Otherwise the reset doesn’t evict an attacker who is already in (JWT Auth WP).

What to check

  • Request a reset with a modified Host, X-Forwarded-Host or similar forwarding header, and inspect the link in the email. Is it built from a configured canonical URL?
  • Is the token present on the reset page alongside third-party resources (Referer leakage)?
  • Token properties: length and entropy source, expiry, single use, invalidation when a new token is issued and after the password changes, bound to one account.
  • Consumption: is the target account taken only from the token, or also from a body or query parameter (user_id, email)? Try mixing your token with the victim’s identifier.
  • Codes (SMS or email OTP): attempts per account and per code, concurrency, alternate endpoints (mobile, legacy, GraphQL, SOAP), batching, IP rotation.
  • Do any object, filter or GraphQL endpoints expose reset-token fields or reset records?
  • Legacy and mobile APIs: can a reset be done with only an email, or with client-side “trust material”?
  • Is the reset endpoint safe as an input sink (unexpected fields, injection)?
  • After a reset: are other sessions and refresh tokens revoked, is MFA still required, is the user notified?
  • Does the response disclose PII or confirm whether an account exists?

Notable cases

  • Mavenlink ($1,500, Jack Cable): reset link built from the Host header, sending the token to an attacker domain (writeup).
  • Instagram ($30,000, 2019): two logic gaps in reset-code rate limiting, exploited through concurrency and distributed infrastructure. Any account could be reset in under 10 minutes for about $150 of cloud compute (writeup).
  • Meta ($66,000): a Math.random()-derived secret, combined with a postMessage handler, defeated the protection (writeup).
  • Ransack (Rails): the default configuration allowed brute-forcing reset tokens through association search predicates. Sequelize and Hasura had similar issues (Positive Security).
  • GraphQL tokenForgotPasswords: production introspection exposed a query returning other users’ reset records, giving takeover of 29,000 accounts (writeup).
  • Legacy mobile SOAP API (CVSS 9.3): reset any account’s password with just an email, with no token or inbox access (writeup).
  • ZTE SmartLife (CVE-2026-86553, CVSS 8.8): trust material recoverable from the app let the backend accept resets without a verification code. 100K+ Android installs (writeup).
  • Metabase (CVE-2026-72898, CVSS 10.0): unauthenticated SQLi via undeclared fields on POST /api/session/reset_password, exploited in the wild (Bishop Fox). A similar SQLi through a ukey parameter in a reset email dumped a whole database (writeup).
  • Consumed reset token replayable (P2): a POST /api/v1/auth/reset-password token kept working after a successful reset, allowing repeated password changes and persistent reset capability (CWE-640, CWE-613). The report stresses proving the second change actually happened, not just a 200 (writeup).
  • Reset-response enumeration: the Intel/CBSE AI platform’s forgot-password endpoint answered differently for existing and unknown emails, the first link in an ATO chain (writeup).
  • JWT Auth for WordPress ≤3.0.2 (CVE-2026-106466): refresh tokens survived password reset, so an attacker kept access up to Administrator (advisory).

Defenses

  • Build reset links from server configuration, never from Host or X-Forwarded-*. Only trust forwarding headers set by your own proxy (writeup).
  • Generate tokens with a CSPRNG, store them hashed, and make them single-use and short-lived, scoped to one account and invalidated on use or reissue. Mark the token consumed atomically in the same transaction as the password update (writeup).
  • Resolve the account from the token server-side only, and ignore client-supplied identifiers at consumption.
  • Rate-limit atomically per account and per token, so the limit survives concurrency, batching and IP rotation. Prefer long links over short codes.
  • Never expose token fields through generic query, filter or GraphQL interfaces. Allowlist filterable attributes (Positive Security).
  • Use the same response whether or not the account exists (OWASP).
  • On reset: revoke all sessions and refresh tokens, keep MFA in place, notify the user, and trigger re-authentication for risk events (OWASP).
  • Retire legacy reset endpoints, or hold them to the same controls.

Sources