r/Pentesting • u/JamesKnightAtDW • 10h ago
How are you testing for broken access control beyond swapping user IDs?
Swapping an ID in a request finds the obvious IDOR bugs, but a lot of access control problems sit somewhere else.
The ones that tend to get missed are function-level checks, where a regular user can call an admin endpoint directly, and state-based checks, where an action should only be allowed at a certain point in a workflow. Multi-tenant apps add another layer, since a user might be blocked from another account's records but not from another tenants.
Hypothetical example: an app correctly blocks users from viewing each other's invoices. But the "approve invoice" endpoint only checks that you're logged in, not that you're a manager, so any user can approve their own.
What I usually check beyond ID swapping:
- Replay admin requests with a low-privilege session
- Try actions out of order, like approving before submitting
- Test the same endpoints across tenants, not just across users
- Compare the web app with the mobile API, since they often enforce rules differently
Curious what others have added to their process. What's the access control bug you find most often that ID swapping alone would have missed?