Skip to content
Account takeover Write-up Beginner

How To Get Easy critical 0 click account takeover on public bug bounty program at hackerone !

A subdomain's login flow accepted a fixed default OTP value, so anyone who knew the code could log into another user's account. The author says this allowed a zero-click account takeover on a public bug bounty programme.

kaforybory Follow

Published on medium.com

بس� الله الرح� ن الرحي� ,الح� دلله رب العال� ين ,والصلاة والسلا� علي أشرف ال� رسلين سيدنا � ح� د وعلى اله وصحبه أج� عين.

Hassan Makki, 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 OTP verification accepted a hard-coded default value instead of checking the real one-time code sent to the user.

Impact

An attacker could take over other users' accounts by logging in with the default OTP, without the victim doing anything.

What the attacker needed

Target subdomain reachable; attacker has an account; victim account exists

How it was found

  1. Create a new account on the affected subdomain.
  2. Log in for the first time, then log out, and choose the OTP login option sent by email or phone.
  3. Enter the default OTP value and get logged in.
  4. Repeat the same steps on a second account to confirm.

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.

When you log in with a one-time code (OTP), the server should generate a random number and check it. Here the server apparently accepted a fixed, guessable code, so an attacker did not need the real code sent to the victim. That let them sign in as someone else.

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.

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.