Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CWE-267 (特权定义了不安全动作) — Vulnerability Class 42

42 vulnerabilities classified as CWE-267 (特权定义了不安全动作). AI Chinese analysis included.

CWE-267 represents a design flaw where a defined privilege, role, or capability inherently permits unsafe actions that were not originally intended by the system architects. This weakness arises when the scope of a permission is overly broad or poorly defined, allowing authorized entities to execute operations that compromise security or integrity. Attackers typically exploit this by leveraging legitimate credentials to perform unauthorized activities, such as accessing sensitive data or modifying system configurations, because the privilege itself grants excessive capabilities. Developers can mitigate this risk by adhering to the principle of least privilege, ensuring that each role is granted only the minimum permissions necessary for its specific function. Rigorous threat modeling and regular code reviews help identify and restrict unintended action paths within privilege definitions, thereby preventing abuse even when assigned to correct entities.

MITRE CWE Description
A particular privilege, role, capability, or right can be used to perform unsafe actions that were not intended, even when it is assigned to the correct entity.
Common Consequences (1)
Access ControlGain Privileges or Assume Identity
A user can access restricted functionality and/or sensitive information that may include administrative functionality and user accounts.
Mitigations (2)
Architecture and Design, OperationVery carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.
Architecture and Design, OperationRun your code using the lowest privileges that are required to accomplish the necessary tasks [REF-76]. If possible, create isolated accounts with limited privileges that are only used for a single task. That way, a successful attack will not immediately give the attacker access to the rest of the software or its environment. For example, database applications rarely need to run as the database ad…
Examples (1)
This code intends to allow only Administrators to print debug information about a system.
public enum Roles { ADMIN,USER,GUEST } public void printDebugInfo(User requestingUser){ if(isAuthenticated(requestingUser)){ switch(requestingUser.role){ case GUEST: System.out.println("You are not authorized to perform this command"); break; default: System.out.println(currentDebugState()); break; } } else{ System.out.println("You must be logged in to perform this command"); } }
Bad · Java

Vulnerabilities classified as CWE-267 (特权定义了不安全动作) represent 42 CVEs. The CWE taxonomy describes the weakness; review individual CVEs for product-specific impact.