Skip to content
IDOR Write-up Beginner

BAC — IDOR ($300–$2,500)

An IDOR flaw in a user profile API let an authenticated attacker read other users' profile data by changing the numeric user ID while keeping their own token. The server checked only that a valid token was present, not that the token's owner matched the requested profile.

medium.com

Published on medium.com

I discovered an IDOR vulnerability in a target application through HackerOne that allowed unauthorized access to other users’ profile data. Although initial validation appeared effective, further testing revealed that server-side authorization was insufficient.

Abin, 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

Impact

An authenticated attacker could read other users' profile data such as email, gender, bio and location, which could enable phishing, credential stuffing or identity theft; the report notes the issue was a duplicate of an earlier submission.

What the attacker needed

A free account; a valid authentication token

The fix

The server should enforce object-level authorisation, checking that the authenticated user owns the requested record, and use indirect identifiers such as UUIDs.

How it was found

  1. Create an account and open the user profile settings, noting the numeric ID in the URL.
  2. Intercept the profile request and change the ID; the server returns 401 Unauthorized.
  3. Change the ID directly in the UI; no data is returned, suggesting client and server validation.
  4. Copy the request as a cURL command using the attacker's token.
  5. Change the ID in the cURL request while keeping the same attacker token.
  6. Receive another user's profile data, confirming the IDOR.

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 uses a simple identifier, like a user number, to fetch data and does not check that the person asking is allowed to see that record. Here, a logged-in user could swap their own user number for someone else's in an API request and still get that person's profile back. The fix is to check on the server that the logged-in user owns the record being requested.

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.