Skip to content
IDOR Write-up Beginner

How I Found an IDOR Vulnerability in a Public Program on HackerOne

A user-stats endpoint returned other users' order numbers, account age and pro status when the user ID in the request was changed. The IDs were not sequential, but the same IDs were exposed in product-page comments, so any commenter's data could be read.

muhammadfurqanoffical Follow

Published on medium.com

I hope you all are doing great. I am a cybersecurity enthusiast, and I have been in this field for the last few years, learning about different things and participating in CTFs on TryHackMe and HackTheBox.

Muhammad Furqan, 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 user-stats endpoint looked up records by the supplied user ID without checking that the ID belonged to the logged-in user.

Impact

An attacker could read other users' order numbers, account age and pro-user status, but only for IDs that could be obtained, since sequential guessing returned a not-found error.

What the attacker needed

A free account; a second account for testing; valid user IDs from public comments

How it was found

  1. Create two accounts to test safely.
  2. Crawl the site with Burp Suite and review the captured requests.
  3. Find the user-stats endpoint that takes a user ID.
  4. Change the ID to the second account and confirm its data is returned.
  5. Find user IDs of commenters on a product page in the response.
  6. Use those IDs on the endpoint to read other users' information.

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.

Many websites put a number or code in the address to say which record to show, for example your own profile. If the site does not check that the record belongs to you, changing that number shows someone else's record. This is called an insecure direct object reference, or IDOR.

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.