š« A01:2021 ā Broken Access Control Explained


Imagine you walk into a hotel, and by mistake, the receptionist gives you a keycard to someone elseās room. You swipe the card, walk ināand suddenly, you're inside a strangerās room, with full access to their belongings.
Thatās exactly what Broken Access Control looks like in the digital world. The system should have verified whether you were authorized for that roomābut it didnāt.
Now, imagine this happening on a banking app, a healthcare portal, or a student record system. Scary, right?
šBroken Access Control occurs when these restrictions are not properly enforced, allowing attackers to:
View or modify other usersā data
Perform unauthorized operations
Escalate privileges
No wonder it jumped from 5th in 2017 to 1st place in 2021 in the OWASP Top 10 list! A staggering 94% of applications tested showed some form of broken access control, with an average incidence rate of 3.81%.
ā ļø Common Examples of Broken Access Control:
š Insecure Direct Object References (IDOR): Accessing or modifying someone elseās account using their user ID in the URL
šŖ Force Browsing: Accessing internal or admin pages without proper authentication or authorization
š„ API Exploits: APIs allowing post, put or delete operations without verifying user permissions
š”ļø How to Prevent Broken Access Control:
Access control logic must be implemented securely on the server side, where it cannot be bypassed or modified by attackers.
Here are some effective practices:
ā Enforce Ownership Checks: Validate that users can only access or modify their own data
š«Deny by Default: Unless a resource is public, deny access unless explicitly allowed
š Log and Alert: Monitor failed access attempts and notify admins when necessary
š§± Use Role-Based Access Control (RBAC): Clearly define what each role can and cannot do
š In short:
Broken access control is one of the most exploited vulnerabilities in web apps. Itās crucial to treat all access decisions with strict scrutiny, validate every userās permission server-side, and never trust client-side enforcement.
š In the next post, we'll dive into A02:2021 ā Cryptographic Failures, where we explore how weak or misused encryption can put sensitive data at risk.
Subscribe to my newsletter
Read articles from Kohsheen Razdan directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by
