How I Found a Broken Access Control Vulnerability During a Penetr
A financial application used a client-controlled parameter to decide which functionality to load, without checking the user's role on the server. A normal user could change that parameter to the administrator's value and view the admin user management page.
Published on medium.com
If there’s one vulnerability I keep running into during penetration testing, it’s Broken Access Control. It doesn’t always involve complicated payloads or advanced techniques.
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 server relied on a client-controlled parameter to choose which functionality to load and did not verify the user's role before returning it.
Impact
A normal user could view the administrator's user management page and the information it contains, which should have been restricted to administrators.
What the attacker needed
A normal user account; ability to intercept and modify requests
The fix
The server should enforce authorization on every request by checking the logged-in user's role before loading the requested functionality, rather than trusting a client-supplied parameter.
How it was found
- Log in as a normal user and intercept a request in Burp Suite.
- Notice a parameter named path that determines which functionality the server loads.
- Log in as an administrator and intercept the request for the user management page.
- Compare both requests and note that only the path value differs.
- Replace the normal user's path value with the administrator's value, keeping the normal user's session.
- Send the modified request and receive the administrator's user management page.
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.
Access control is the check that decides whether a logged-in user is allowed to do something. Here the server confirmed who the user was but never checked whether a normal user was allowed to see the admin page. By changing one value in the request, a normal user could open a page meant only for administrators.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.