Skip to content

Bug class · Beginner

Insecure direct object reference (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.

median public bounty
$1,500

Covers CWE 639, 566.

How it works

Full lesson

The pattern behind every report in this class.

Insecure direct object reference, usually shortened to IDOR, is a class of access control bug where an application takes an identifier from the client and uses it to fetch or change a record without checking that the caller is allowed to touch that record. The identifier can be a number, a UUID, an email address, a filename or a value hidden inside a cookie or token. The common thread is that the server trusts the client to say which object it wants and never confirms ownership against the authenticated session. This pattern appears across web apps, mobile backends, GraphQL APIs and file storage, and it is one of the most frequently reported issues in the dataset behind this lesson.

Programs care about IDOR because it breaks the core promise that one user cannot read or alter another user's data. The impact ranges from privacy leaks such as names, emails and addresses, through exposure of financial records and invoices, to full account takeover when a profile update or password reset flow accepts a swapped user identifier. In several reports the same missing ownership check allowed deletion of another user's content or account, which turns a read-only bug into destructive action. Because the flaw is often a single missing check on an otherwise authenticated endpoint, it is cheap to test and easy to demonstrate with two accounts.

The most common places to find IDOR are endpoints that take an object identifier directly: profile and settings updates, delete handlers for files, images, comments and accounts, order and invoice lookups, multi-tenant APIs that accept a tenant or organisation identifier, and GraphQL queries or mutations with an id argument. It also shows up in mobile app APIs reached after certificate pinning bypass, in minified JavaScript bundles that reveal unlinked internal endpoints, and in password reset flows that carry a user identifier in the request. Sequential numeric identifiers and predictable filenames make discovery easier, but even UUIDs can be vulnerable when they are the only secret and never expire.

Conceptually, the application receives a request that names an object, for example a user id in a path, a file id in a query string, or an object id in a JSON body. The server looks up that object by the supplied identifier and returns it or acts on it. The bug appears when the lookup is not paired with an authorisation check that compares the object's owner or tenant against the authenticated session. The server may have validated the session token, but it never asks whether this particular caller is entitled to this particular object.

Things to try

All 2,027

Each line worked in a disclosed report. Test only what a program's scope allows.

Profile and account updates 266

  • Change the ID parameter in a profile update request to a victim's identifier and change their email without supplying the old password.
  • Change the id parameter in an account settings save request to another user's identifier, change the email, then reset their password.
  • Register at a wholesale store using another customer's email and a business address, then check whether their default address changed.
  • Replace your account identifier with a victim's in the rename request and set a new display name.

Organisations and multi-tenant resources 259

  • Change the Host header to a victim company's domain and search responses for leaked CorpID and SiteID values, then use them in your own API calls.
  • Swap CorpID and SiteID parameters in captured API calls for a victim's values to retrieve their API keys and billing details.
  • Trigger a request that returns a third-party analytics login URL, then replay it with another organisation's site ID.
  • Add an account_id parameter to an SSO settings request and check whether another user's SSO configuration can be edited.

Other 207

  • Change base64-encoded IDs, hashes and UUIDv1 references in requests to test for access to other users' data.
  • Brute force MongoDB ObjectIds on a token record endpoint, using the timestamp and counter parts to narrow the search.
  • Look for several informative findings that can be chained into an IDOR or authentication bypass.
  • Send repeated GraphQL directives in one request and watch for unbounded execution or denial of service.

User enumeration and identifier harvesting 164

  • Check whether a login page reached after username disclosure lacks rate limiting.
  • Request pending user details and attachment endpoints with numeric identifiers without authenticating.
  • Request a customer registration endpoint with sequential numeric user IDs while unauthenticated.
  • Submit an email address to the change-email feature and compare the response for a registered address against an unregistered one to see whether it reveals account existence.

Image and media handling 128

  • Guess numeric clip identifiers on an unauthenticated transcode job endpoint, then use the returned job and video identifiers to fetch video details.
  • Set your profile image to another user's image ID, then upload a new image and check whether the other user's image is deleted.
  • Intercept the GraphQL refetch query on a producer or dashboard page, change the video ID variable to another user's stream and check whether private configuration data comes back.
  • Upload an image, note the filename pattern of sequential ID, username and timestamp, then generate filenames to fetch other users' images.

Bypasses and variations

All 155
  • Decode a base64 identifier, change the inner JSON id value, re-encode it and send it in the same parameter.
  • Chaining an id leaked from one endpoint into an export or session endpoint reached data the first endpoint did not expose.
  • Enumerate identifiers below the visible range or in small predictable ranges to reach records not linked in the UI.
  • Adding whitespace, a trailing slash or a path traversal segment to an identifier got past a raw comparison in the authorisation check.
  • Misleading or differing error messages revealed whether an action succeeded or leaked object state.
  • Racing the upload or edit request reached objects that were otherwise empty or newly created.

Typical fixes

All 185
  • Derive the object owner from the authenticated session rather than trusting an ID supplied by the client.
  • Derive the target user from the authenticated session rather than accepting a user identifier from the request.
  • Check object ownership server-side against the authenticated session on every request, not just token validity.
  • Check that the requester is allowed to see the record identified by the client-supplied identifier.
  • Check authorisation in every GraphQL resolver and node lookup before returning an object by identifier.
  • Check on the server that the requested object belongs to the authenticated user before returning it.

Tips for beginners

All 14
  • Start with two accounts you control and map every request that carries an identifier: user id, file id, order number, tenant id, email address or token. Focus first on profile and settings updates, delete endpoints and order or invoice lookups, because these are the most common places for missing ownership checks and the impact is easy to show.
  • When you find a numeric identifier, try neighbouring values and low numbers such as the first few ids. Administrators and early users often have low ids, and a successful response with another user's data is a clear demonstration. Do not stop at a 403: try changing the request method, adding a query parameter or altering the path slightly, because authorisation checks are sometimes applied inconsistently across route variations.
  • For GraphQL, run introspection where it is available and test every query and mutation that takes an id argument. Pay particular attention to nested fields: a root query may be protected while a nested resolver returns private data for objects you do not own. Also look for hidden or unlinked GraphQL endpoints referenced in JavaScript bundles.
  • Read minified JavaScript bundles and archived copies of the site to find internal endpoints that are not linked in the interface. These often return per-user data by identifier and may lack the checks applied to the public API. Test each discovered endpoint for missing authentication and object ownership checks.
  • When an identifier looks encoded, decode it, change the inner value, re-encode it and send it back. Base64-wrapped ids and composite identifiers are common, and developers sometimes validate only part of the value, such as the last element of a comma-separated list or the GUID inside a Base64 string.
  • Test password reset and email change flows carefully. If a reset request carries a user identifier, try swapping it for another account's identifier while keeping a valid token. If a profile update endpoint lets you change an email address without the old password, change it to an address you control and then trigger a password reset to demonstrate account takeover.

Start here: a reading path

Open the path

Clear reports in order, easiest first.

Guides and techniques

View all

The best explainers, cheat sheets and technique posts on IDOR, from around the web.

Newest reports

All 1,761

Most recently disclosed.

New IDOR reports by email

Follow IDOR and get each week's new disclosures in one short email.

Free. New reports for what you follow, weekly by default. One-click unsubscribe. Privacy