Skip to main content
Technical

IDOR, BOLA and BFLA: understand authorization flaws

Learn how object- and function-level authorization flaws expose other users' data or privileged actions, and how to test server-side controls.

Understanding authorization flaws

Before the technical detail, distinguish two concepts. Authentication verifies a user’s identity: “who are you?”. Authorisation verifies their rights: “are you allowed to do this?”. An application can have strong authentication and still be vulnerable if it does not check rights for every operation.

IDOR: Insecure Direct Object Reference

IDOR is the most classic form of authorization flaw. It occurs when an application uses a user-supplied identifier to directly access a database object, without verifying that the user has the right to access that specific object.

Fictional example: an ecommerce application uses GET /api/orders/12345 to display an order. If the user changes the identifier to 12346 and the server checks only that they are signed in, they may obtain another customer’s order. The missing control is authorisation for that specific resource.

The consequences of an IDOR can be devastating: access to personal data of millions of users, viewing confidential documents, modifying data of other accounts. Real incidents have exposed medical records, bank statements, insurance contracts, and many other sensitive data. The impact is often amplified by the fact that identifiers are sequential (1, 2, 3...) or predictable, allowing systematic enumeration of all objects.

BOLA: Broken Object Level Authorization

BOLA describes the same type of object-level flaw in an API. OWASP uses the term Broken Object Level Authorization in its API Security Top 10.

In a modern API architecture, BOLA manifests in multiple ways. A user can access another user's resources by manipulating the identifier in the URL (/api/users/{"{userId}"}/profile). A tenant of a multi-tenant SaaS application can access another tenant's data by modifying the tenant ID in requests. A user can access other users' files by guessing or enumerating file names or storage identifiers.

BFLA: Broken Function Level Authorization

BFLA is a different variant: instead of accessing another user's data (same role, same privilege level), the attacker accesses functionality reserved for a higher role. It's a horizontal-to-vertical privilege escalation.

Concrete example: a SaaS application has three roles — standard user, manager, and administrator. The endpoint POST /api/admin/users/create is supposed to be accessible only to administrators. But if the application checks the role only on the frontend (by hiding the "Create a user" button for non-admins) without server-side verification, a standard user who knows the endpoint can create user accounts. Worse, they could create an administrator account for themselves.

Common manifestations of BFLA include accessing administration endpoints without being an administrator, modifying roles or permissions of other users, accessing management features (data export, system configuration) reserved for privileged roles, and executing destructive operations (deletion, mass modification) without the required privileges.

Frequently asked questions

Are IDOR and BOLA the same thing?

Conceptually yes. IDOR is the historical term used in classic web security. BOLA is the term used by OWASP in its API Security Top 10. Both describe the same problem: an authenticated user can access objects that don't belong to them by manipulating the object identifier.

Do UUIDs protect against IDORs?

No. UUIDs make enumeration more difficult but do not protect against IDORs. If an attacker obtains a valid UUID (through an information leak, a log, or another endpoint), they can use it to access the resource. The only reliable protection is server-side authorization verification.

How to manually test for an IDOR?

In an authorised environment, create two test accounts in separate scopes. From account B’s session, request a resource belonging to account A. If the server returns it, authorisation is failing. Repeat for the resource types and actions included in the mandate.

Do web frameworks automatically protect against these flaws?

No. No web framework (Express, Django, Rails, Spring) automatically protects against authorization flaws. Frameworks provide authentication tools, but authorization is always the developer's responsibility. That's why these flaws are so common: they are not a technical bug but a business logic oversight.

Jordan Fredj, Founder of Hacksessible -

Sources and reading method


Try on your scope