Skip to content
Account takeover Write-up Intermediate

$11,000 for Two Login Flows That Shared a Memory: A Session Puzzling Bug That Skipped MFA Entirely

The SSO login finalization logic treated any user identifier in the session, including a leftover pendingMfaUserId from an incomplete password login, as proof of an authenticated session. An attacker who knew a target's password could complete an unrelated SSO login in the same session to obtain a fully authenticated session for the target account, bypassing MFA.

T4nv1 Follow

Published on medium.com

Some of the hardest bugs to find aren’t hidden in any single endpoint at all — they live in the gap between two features that were each tested thoroughly on their own, by different people, at different times, neither of whom had reason to think about what happens when a user’s session touches both flows in an order…

T4nv1, on medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

The SSO merge logic checked only for the presence of any user identifier in the session, without distinguishing a fully authenticated session from a partial, MFA-pending one.

Impact

Any attacker with a target account's password could achieve full authentication bypassing MFA, provided they could complete any SSO login in the same session, which was trivial since SSO was available to any user.

What the attacker needed

Knowledge of the target account's password; ability to complete an SSO login in the same session

The fix

The SSO merge logic was fixed to require full authentication state, and partial-authentication session fields are cleared on flow transition.

How it was found

  1. Start a password login with correct credentials and stop after the pendingMfaUserId value is set but before submitting any MFA code.
  2. In the same browser session, start and complete a full SSO login using a separate identity provider account.
  3. Observe that the finalization step creates a fully authenticated session for the account associated with pendingMfaUserId, bypassing MFA.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

Multi-factor authentication (MFA) is a second proof of identity, like a code from an app, on top of a password. Here, the application stored a marker in the user's session after the password step but before the MFA step. A separate single sign-on (SSO) login flow then mistook that marker for a fully logged-in user and finished logging in the account without ever checking the MFA code.

What is Account takeover?

Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.

More by T4nv1

View all

113 more disclosed reports, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Account takeover

The lesson behind this report.

Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.