Authorization (AZ5)
Chad kan toegang krijgen tot bronnen (inclusief services, processen, AJAX, video, afbeeldingen, documenten, tijdelijke bestanden, sessiegegevens, systeemeigenschappen, configuratiegegevens, registerinstellingen, logboeken) die hij niet zou moeten kunnen vanwege ontbrekende autorisatie, of als gevolg van overmatige privileges (bijvoorbeeld het niet gebruiken van het principe van de minste privileges)
The key concept for this card is applying authorization controls to all resource types. See Authorization 6 (AZ6) for data controls, and Authorization 7 (AZ7) for function/object/property controls.
Scenario: Chad’s Unauthorized Access Due to Insufficient Authorization
Imagine a scenario where Chad gains access to various resources that he should not be able to access. This occurs due to:
- Missing Authorization Checks: Certain resources lack proper authorization controls.
- Excessive Privileges: The system grants more privileges than necessary, failing to adhere to the principle of least privilege.
Example
Chad discovers that a corporate application does not enforce strict authorization checks on certain resources, such as temporary files, system properties, and logs. He exploits this oversight to access sensitive documents and configuration data meant for higher-privileged users. Additionally, due to the system granting excessive privileges to regular users, Chad can access and interact with services and processes usually reserved for administrators.
Threat Modeling
STRIDE
This scenario maps primarily to STRIDE: Elevation of Privilege.
Elevation of Privilege (EoP) occurs when an attacker gains access to resources or actions they are not authorized to use. In this case, the attacker can access resources—files, processes, session data, configuration settings, logs, etc.—that should be protected by authorization controls. The root cause is missing authorization or excessive privileges, violating the principle of least privilege. The consequence of such an action leads to Information Disclosure in most cases.
What can go wrong?
Such vulnerabilities can lead to unauthorized access to critical resources, potentially resulting in data breaches, system manipulation, and other security compromises.
For more things that can go wrong, see the Common Attack Patterns related to this card in the table below.
What are we going to do about it?
- Implement comprehensive authorization checks for all resources, system component and requests, regardless of resource type. Ensure only appropriately privileged users can access them.
- Adhere to the principle of least privilege, granting users only the permissions they need to perform their duties.
- Regularly audit and review user privileges and resource access controls to identify and rectify any excesses or lapses in authorization.
- Ensure client applications can only request access to what is strictly necessary.
For detailed advice on how to mitigate threats related to the card, see the ASVS and OWASP Developer Guide requirements in the table below.
Mappings
OWASP ASVS (v5.0): 8.1.1,10.2.3,13.2.2,13.3.2,16.4.2
OWASP DevGuide: SC1,SC2,SDC1,SDA2,SM2,SM12,AC2,AC3,AC4,ACM4,ACM5,ACM6,ACM7,ACM8,ACM9,SCM2,SCM4,PDR3,PDR4,SLD3
STRIDE: Elevation of Privilege
CAPEC™: 54,58,75,77,87,122,126,143,144,149,155,203,240,268
CAPEC Map
| Code | Title | ASVS |
|---|---|---|
| 54 | Query System for Information | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 58 | Restful Privilege Elevation | 8.1.1,10.2.3,13.2.2,13.3.2,16.3.2 |
| 75 | Manipulating Writeable Configuration Files | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 87 | Forceful Browsing | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 122 | Privilege Abuse | 8.1.1,10.2.3,13.2.2,13.3.2,16.3.2 |
| 126 | Path Traversal | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 143 | Detect Unpublicized Web Pages | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 144 | Detect Unpublicized Web Services | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 149 | Explore for Predictable Temporary File Names | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 155 | Screen Temporary Files for Sensitive Information | 8.1.1,10.2.3,13.2.2,13.3.2,16.3.2 |
| 203 | Manipulate Registry Information | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 240 | Resource Injection | 8.1.1,10.2.3,13.2.2,16.3.2 |
| 268 | Audit Log Manipulation | 16.3.3,16.4.2 |