• Authentication

IDOR (Insecure Direct Object Reference)

IDOR happens when an API or page lets you change an object ID and read or change someone else’s data because authorization was never checked on the server.

How attackers abuse it

Attackers start with a legitimate session — their own account — then swap resource identifiers in URLs, JSON bodies, or path segments. A request like GET /api/invoices/1001 becomes /api/invoices/1002. If the server only checks that the caller is logged in, not that they own invoice 1002, the attacker reads another tenant’s data.

The same pattern appears in multi-tenant SaaS: org_id, project_id, document keys, and UUID-looking IDs that still lack ownership checks. UI hiding is irrelevant; attackers hit the API directly with Burp-style proxies or simple scripts.

Impact ranges from privacy breaches and GDPR/DPDP exposure to privilege escalation when write endpoints accept foreign IDs. IDOR is one of the most common findings in modern API-heavy products.

What proof looks like

Proof is a reproducible request/response pair: authenticated as user A, requesting user B’s object ID, receiving B’s data or a successful mutation — with no elevated role. Safe PoCs redact sensitive fields but keep status codes, response shape, and the ID swap clear so engineers can retest after the fix.

In PandaONE, this class maps to the Authentication finding category. Alerts ship only with evidence — never as unverified scanner noise.

How to prevent it

  • Enforce authorization on every object access: load the resource, then assert ownership or role against the authenticated principal.
  • Prefer opaque, non-guessable IDs and still check ownership — obscurity is not access control.
  • Centralize tenancy filters (user_id / org_id) in data-access layers so new endpoints inherit the same rules.
  • Add automated tests that attempt cross-user access and expect 403/404.
  • Log authorization failures and rate-limit enumeration of sequential IDs.

• FAQ

Frequently asked questions

← All vulnerability classes

Hunt this class with proof

Or scan your domain.

Featured on ScrollLaunchFeatured on CodeHype