Skip to content
Account takeover Write-up Beginner

Resetting the Admin’s Password Without Touching Their Inbox

The password reset flow used a sequential integer identifier as the sole proof of authorisation, so an attacker could change the number to target another user's reset request. By supplying the super-admin's identifier, the attacker could reset that account's password without any email or secondary check and then log in as admin.

Sid Follow

Published on infosecwriteups.com

Hey everyone, it’s been a while since my last write-up — work got in the way for a bit — but I’m back and planning to start posting on Medium again. Let’s jump into it.

Sid, on infosecwriteups.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 reset token was a predictable sequential integer that was not bound to the requesting session or user, and possession of the number alone was treated as authorisation.

Impact

An attacker could take over any account, including administrators, without access to the victim's inbox or phone, and because the platform handles payroll and HR data this could lead to a serious data breach; the flow was also scriptable and not rate-limited.

What the attacker needed

Ability to request a password reset; ability to intercept and modify requests; no victim interaction required

The fix

The reset token should be a cryptographically random, single-use, time-limited value bound to the requesting session, with the email or SMS verification step actually required and reset attempts rate-limited.

How it was found

  1. Request a password reset from a test account and intercept the response.
  2. Observe that the idToken value increases by one with each request.
  3. Request another reset but supply the next idToken value, which belongs to the super-admin.
  4. Complete the reset without any email or confirmation step.
  5. Log in using the new password and the manipulated identifier.

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 forget a password, a site usually emails you a special link to prove it is really you. Here, that link contained a simple counting number instead of a long random secret, and the server never checked that the number belonged to the person asking. Anyone could change the number to point at someone else's reset request and set a new password for that account, including the administrator's.

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 Sid

View all

4 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.