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.
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"); } }Vulnerabilities classified as CWE-267 (特权定义了不安全动作) represent 42 CVEs. The CWE taxonomy describes the weakness; review individual CVEs for product-specific impact.