Broken Function-Level Authorisation (BFLA)
API functions meant for administrators or other privileged roles do not check the caller's role, so an ordinary user can call them directly.
| Severity | High |
| CVSS 3.1 | 8.1 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N Open in the calculator |
| CVSS 4.0 | 8.6 CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N Open in the calculator |
| CWE | CWE-862: Missing Authorization |
| OWASP Top 10 | A01:2025 Broken Access Control |
| MITRE ATT&CK | T1190 Exploit Public-Facing Application |
| Category | Broken Access Control |
Description
APIs expose functions with different privilege requirements: ordinary user operations, operations for managers or support staff, and administrative functions such as managing users, roles, configuration or other tenants. The API checks that the caller is authenticated but not that their role permits the function, or the check exists only in the client, which hides the corresponding buttons and menus. Any authenticated user who sends the request directly, including anyone who can register an account, can therefore perform actions reserved for more privileged roles.
Depending on the functions exposed, this can mean creating or promoting accounts, changing other users' permissions, reading or exporting all data, changing configuration or deleting records, which often amounts to full administrative control of the application. Where the API serves several tenants, administrative functions may also reach other tenants' data. The impact is lower where the exposed functions are limited, such as read-only reporting.
Common forms are administrative endpoints under a predictable path (for example an /admin/ or /internal/ segment, or a different API version) that rely on not being linked; endpoints where reading is restricted but another method on the same path, such as PUT, PATCH or DELETE, is not; role checks present in one service or gateway route but missing from another that reaches the same function; and checks that trust a role or permission value sent by the client.
The weakness is identified by mapping the API's functions from documentation, client code and traffic captured as a privileged user, then replaying each privileged request with an ordinary user's session or token and comparing the results. Changing the HTTP method and trying administrative paths alongside known ones finds functions the client never calls. The Autorize extension for Burp Suite automates much of the comparison.
Remediation
Enforce role and permission checks on the server for every function:
- Deny by default: require every endpoint and method to declare the roles or permissions it needs, and reject requests that do not meet them. Use the framework's authorisation features, for example authorisation policies or
[Authorize(Roles = ...)]in ASP.NET Core, method security with@PreAuthorizein Spring Security, or shared middleware in Node.js, rather than ad hoc checks in each handler. - Take the caller's roles from the validated session or token, or from the server's own records, never from a value supplied by the client.
- Check each HTTP method separately, so that permission to read a resource does not imply permission to change or delete it.
- Where practical, separate administrative functions from the public API: a separate service, host or gateway route that is reachable only from trusted networks and requires stronger authentication.
- Keep a matrix of functions against roles and test it automatically, calling each privileged function as each lower role and failing the build if access succeeds.
Confirm the fix by repeating every privileged request as each lower-privileged role and checking that the server refuses it.
References
Add This Finding to Your Library
In Pental this write-up is in Settings, Library. Add to my library copies it into your own, rated in your firm's CVSS version, ready to put in your own words.
Free trialYour trial starts when your portal goes live, not when you sign up, so the time you spend setting up does not count. · No card required
Only need the reporting? Our reporting tool is free and open source, with the same library.