Skip to content
IDOR Write-up Beginner

How I Found a Critical IDOR Leading to Account Takeover in Two EdTech Platforms

The profile update API accepted a client-supplied user_id without checking ownership, letting an attacker modify another user's profile. By changing the victim's mobile number, an attacker could receive the login OTP and take over the account.

impyhacker Follow

Published on medium.com

Recently, while performing security testing on two EdTech platforms — LearningWay and LearningRanking, I discovered several serious vulnerabilities in their authentication and authorization mechanisms.

PYHACKER, 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 server trusted the client-supplied user_id parameter and did not verify that the authenticated user owned the account being modified.

Impact

An attacker could take over any user account by changing the victim's mobile number and then logging in with an OTP sent to the attacker's phone; the same flaw affected both platforms because they share backend infrastructure.

What the attacker needed

A valid user account; ability to intercept and modify requests

The fix

The server should remove user_id from client-controlled parameters and identify users via session-based authentication with strict access control checks.

How it was found

  1. Intercept the profile update request.
  2. Change the user_id value to another user's ID.
  3. Forward the request and observe a success response, confirming the other user's profile was updated.

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.

An IDOR (Insecure Direct Object Reference) happens when a website lets you change a number or name in a request to access someone else's data. Here, the profile update request included a user_id that the server trusted, so changing it updated another person's profile. Because login used a one-time code sent by text message, changing the victim's phone number let the attacker receive that code and log in as them.

What is IDOR?

One user can read or change another user's data, usually by changing an identifier the server trusts without checking who is asking. One of the most paid bug classes on web programs.

Similar reports

View all

Same bug class and techniques, clearest first.

Insecure direct object reference (IDOR)

The lesson behind this report.

One user can read or change another user's data, usually by changing an identifier the server trusts without checking who is asking. One of the most paid bug classes on web programs.