Skip to content
Account takeover Write-up Intermediate

How I Exploited Passkey to Gain Unauthorized Access and TakeOver

The platform allowed an attacker to register an account using a victim's email and enable passkey login without email verification. After the attacker disconnected a third-party login, the victim could still log in via OTP and accept an invitation, while the attacker retained persistent access via the passkey, leading to account takeover.

Ahmed Samir Ghallab Follow

Published on medium.com

Ever been on a rollercoaster of failed attempts before stumbling upon a eureka moment? Well, that’s exactly what happened during my hunt for vulnerabilities on a popular platform.

Ahmed Samir Ghallab, 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

Likely the platform allowed passkey registration without verifying email ownership, and did not invalidate existing passkeys when the legitimate user logged in via OTP.

Impact

An attacker could gain persistent unauthorised access to a victim's account, even after the victim logged in and verified the account, leading to account takeover.

What the attacker needed

Victim's email address known; attacker can register account with victim's email; victim interacts with an invitation

The fix

The platform should require email verification before allowing passkey registration and invalidate existing passkeys when a legitimate user logs in via OTP; the report states the vulnerability was patched.

How it was found

  1. Register an attacker-controlled account via Facebook using the victim's email.
  2. Enable passkey login on that account.
  3. Disconnect Facebook login from the account, leaving OTP and passkey as the only login methods.
  4. The victim enters their email when prompted by an invitation and receives an OTP.
  5. The victim enters the OTP, accesses the account, and accepts the invitation.
  6. The attacker retains access via the passkey even after the victim verifies the account.

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.

A passkey is a modern login method that uses your device's fingerprint or face recognition instead of a password. The bug meant someone could set up a passkey on an account that used your email address, and later you might log in with a one-time code sent to your email without realising someone else still had access. This let the attacker keep control of the account even after you started using it.

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 Ahmed Samir Ghallab

View all

1 more disclosed report, 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.