In-depth lesson · Account takeover
Root causes
Every point the Account takeover reports back under this heading, best-backed first, each with the reports it is seen in.
-
The reset link created an authenticated session before a new password was set.
Seen in 3 reports
-
The reset token was not invalidated by a successful login, only by time or use.
Seen in 3 reports
-
The same session identifier was reused across logout, login and password reset.
Seen in 3 reports
-
The server did not validate the JWT signature, so the payload could be edited and re-encoded.
Seen in 3 reports
-
The SPF record ended with a soft-fail qualifier instead of a hard-fail qualifier, so unauthorised senders were not rejected.
Seen in 3 reports
-
The verification endpoint lacked rate limiting or lockout after repeated failed attempts.
Seen in 3 reports
-
A copy-and-paste error in the token cache key comparison checked the username twice instead of checking the password.
-
A dangling DNS record pointed at a third-party service where the corresponding app or domain was never claimed.
Seen in 2 reports
-
A flaw in authentication state management let one user's session or identity be confused with another's.
-
A missing await on an asynchronous password check made a truthy Promise stand in for the boolean result, and the username went into a database query without type validation.
-
A separate basic authentication path did not enforce the second factor that the normal login flow required.
-
An account had Kerberos preauthentication disabled and used a weak, dictionary-crackable password, with further credentials stored insecurely on the host.
-
Authentication tokens were placed in URLs that got crawled and archived publicly, carried the user ID, and remained valid long after capture.
-
Existing reset tokens were not invalidated when the email address or password changed.
-
Login and session checks were tied to the old email identity rather than being invalidated when the email changed.
-
No rate limiting or lockout was implemented on authentication and password reset endpoints.
-
Password resets were allowed to addresses on expired domains that anyone could register.
-
Previous reset tokens were not invalidated when a new one was issued and validation was not atomic with the password update.
-
Reconnection relied only on cached addresses and names without validating re-authentication keys.
-
Registration and recovery handled special characters in email addresses inconsistently, so a modified address matched the victim's account.
-
Registration lacked email confirmation and social login did not check for an existing account.
Seen in 2 reports
-
Reset tokens were accepted without checking expiry, prior use or whether the email had changed since issue.
-
Reset tokens were not bound to the user account they were issued for.
-
Reset tokens were not invalidated after use or after the password was changed.
-
Reset tokens were not invalidated when the password changed, and links were only expired on reset-initiated changes.
Seen in 2 reports
-
Reset tokens were predictable counters rather than random values and were not bound to the account or single use.
-
Reset tokens were predictable, unsigned encodings of email and timestamp rather than random signed values.
-
Reset tokens were stored without invalidating earlier ones, so each new request added a valid token instead of replacing or expiring the previous ones.
Seen in 2 reports
-
Security tokens were generated from time-based, low-entropy functions instead of a cryptographically secure random source.
-
Server-side OTP verification was missing or accepted a hardcoded default value.
Seen in 2 reports
-
Session cookies were not bound to a browser or device and stayed valid when replayed elsewhere.
Seen in 2 reports
-
Session cookies were set without the Secure attribute, so they could travel over plain HTTP.
-
The 2FA secret was generated once per account and reused for every setup attempt until 2FA was enabled.
-
The address was normalised for comparison but the original unnormalised address was used for delivery.
-
The app trusted the client-supplied X-Forwarded-Host header when building the absolute reset URL.
-
The app used the untrusted Host header when generating the reset link instead of a fixed domain.
-
The application did not clear the session or prevent caching of sensitive pages after logout.
-
The application failed to normalise or reject Unicode look-alike characters, so visually identical addresses were treated as one account.
-
The application relied on a client-controlled status code in the response body instead of validating the OTP server-side.
-
The application relied on a client-side response to decide OTP success, and the password change endpoint did not enforce authorisation.
-
The application trusted a client-side status field to decide whether the OTP had been verified instead of enforcing it on the server.
-
The application trusted the email address as a unique identifier and merged accounts without verifying ownership.
-
The application used the mutable and unverified email claim as the unique user identifier instead of the immutable subject claim.
-
The application used the unvalidated Host or X-Forwarded-Host header to build absolute URLs in reset emails.
-
The authentication code returned a distinct error for an unknown username versus a wrong password instead of one generic failure.
Seen in 2 reports
-
The authorisation code was not bound to the user or session that initiated the login, so a client-supplied session identifier was trusted.
-
The backend deserialised the email field without enforcing a single string, so an array was accepted as multiple recipients.
-
The change-password endpoint had no rate limit or lockout on repeated wrong current-password attempts.
-
The client trusted a response field to decide verification success, and the server did not enforce the verified state on the next request.
-
The client trusted the server response to indicate verification success without independently validating the code.
Seen in 2 reports