Skip to content
IDOR Write-up Beginner

Autorize & IDOR: How a Simple Token Swap Exposed Sensitive Data

A non-admin user could retrieve admin-restricted order and transaction data through API and GraphQL endpoints because the application did not validate user roles. An attacker with a low-privilege token could access sensitive details such as order IDs, user IDs, transaction status, and hash values.

medium.com

Published on medium.com

Hi everyone! My name is Satyam Pawale, also known as @hackersatty in the bug bounty world.

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

The API and GraphQL endpoints fail to validate user roles before returning sensitive information, and the system does not enforce proper Role-Based Access Control (RBAC).

What the attacker needed

A non-admin account; Burp Suite with Autorize extension

The fix

The application should implement Role-Based Access Control (RBAC) and validate user roles on the backend before returning sensitive information from API and GraphQL endpoints.

How it was found

  1. Log in as a non-admin user and extract the authentication token using Burp Suite.
  2. Send an API request to the order details endpoint using the non-admin token.
  3. Observe that the response includes restricted details that should only be accessible to admins.
  4. Execute GraphQL queries for order details and payment transactions using the non-admin token.
  5. Confirm that the responses contain sensitive data such as order ID, status, hash, and user ID.

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.

This is an IDOR (Insecure Direct Object Reference) bug: the app lets you ask for data by its ID but forgets to check whether you are allowed to see it. A normal user's login token was accepted on admin-only endpoints, so they could read other people's order and payment details. The fix is to check the user's role on the server before returning any sensitive data.

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.