---
title: "CWE-266: Incorrect Privilege Assignment"
url: https://radicalnotion.ai/cwe/cwe-266
type: cwe
description: "A product incorrectly assigns a privilege to a particular actor, creating an unintended sphere of control for that actor."
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-266: Incorrect Privilege Assignment

- **Abstraction:** Base
- **Structure:** Simple
- **Status:** Draft
- **CVEs with this as primary weakness:** 713
- **Of those, in CISA KEV:** 1
- **New in 2026:** 320
- **CWE catalog version:** 4.21

## Description

A product incorrectly assigns a privilege to a particular actor, creating an unintended sphere of control for that actor.

## Modes of introduction

| Phase | Note |
| --- | --- |
| Implementation | REALIZATION: This weakness is caused during implementation of an architectural security tactic. |

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Access Control | Gain Privileges or Assume Identity | A user can access restricted functionality and/or sensitive information that may include administrative functionality and user accounts. |

## Potential mitigations

### Architecture and Design, Operation

Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.

### Architecture and Design, Operation (Environment Hardening)

Run 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 administrator, especially in day-to-day operations.

## Demonstrative examples

### Example 1

The following example demonstrates the weakness.

Bad code:

```c
seteuid(0);
/* do some stuff */

seteuid(getuid());
```

### Example 2

The following example demonstrates the weakness.

Bad code:

```java
AccessController.doPrivileged(new PrivilegedAction() {
    public Object run() {
        // privileged code goes here, for example:
        System.loadLibrary("awt");
        return null;
        // nothing to return
    }
```

### Example 3

This application sends a special intent with a flag that allows the receiving application to read a data file for backup purposes.

Bad code:

```java
Intent intent = new Intent();
intent.setAction("com.example.BackupUserData");
intent.setData(file_uri);
intent.addFlags(FLAG_GRANT_READ_URI_PERMISSION);
sendBroadcast(intent);
```

Attack code:

```java
public class CallReceiver extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
        Uri userData = intent.getData();
        stealUserData(userData);
    }
}
```

Any malicious application can register to receive this intent. Because of the FLAG\_GRANT\_READ\_URI\_PERMISSION included with the intent, the malicious receiver code can read the user's data.

## Observed examples

| CVE | Description |
| --- | --- |
| CVE-1999-1193 | untrusted user placed in unix "wheel" group |
| CVE-2005-2741 | Product allows users to grant themselves certain rights that can be used to escalate privileges. |
| CVE-2005-2496 | Product uses group ID of a user instead of the group, causing it to run with different privileges. This is resultant from some other unknown issue. |
| CVE-2004-0274 | Product mistakenly assigns a particular status to an entity, leading to increased privileges. |

## Real CVEs with this weakness (sample of 12 of 713)

| CVE | Title | Severity | CVSS | EPSS | CISA KEV | Published |
| --- | --- | --- | --- | --- | --- | --- |
| CVE-2026-48172 | LiteSpeed cPanel Plugin Privilege Escalation Vulnerability | critical | 10.0 | - | Yes | 2026-05-21 |
| CVE-2026-39773 | WordPress Doctreat Core plugin \<= 1.7.0 - Privilege Escalation vulnerability | critical | 10.0 | - | No | 2026-10-06 |
| CVE-2026-23800 | WordPress Modular DS plugin \<= 2.5.2 - Privilege Escalation vulnerability | critical | 10.0 | - | No | 2026-01-16 |
| CVE-2026-23550 | WordPress Modular DS plugin \<= 2.5.1 - Privilege Escalation vulnerability | critical | 10.0 | - | No | 2026-01-14 |
| CVE-2025-41115 | Incorrect privilege assignment | critical | 10.0 | - | No | 2025-11-21 |
| CVE-2024-9479 | - | critical | 10.0 | - | No | 2024-11-20 |
| CVE-2024-9478 | - | critical | 10.0 | - | No | 2024-11-20 |
| CVE-2026-42368 | GeoVision LPC2011/LPC2211 Web Interface privilege escalation vulnerability | critical | 9.9 | - | No | 2026-05-04 |
| CVE-2026-22907 | An attacker may gain unauthorized access to the host filesystem, potentially allowing them to read and modify system data. | critical | 9.9 | - | No | 2026-01-15 |
| CVE-2025-62645 | Restaurant Brands International assistant platform privileged token generation | critical | 9.9 | - | No | 2025-10-17 |
| CVE-2025-10725 | Openshift-ai: overly permissive clusterrole allows authenticated users to escalate privileges to cluster admin | critical | 9.9 | - | No | 2025-09-30 |
| CVE-2025-54049 | WordPress Custom API for WP \<= 4.2.2 - Privilege Escalation Vulnerability | critical | 9.9 | - | No | 2025-08-20 |

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-269](https://radicalnotion.ai/cwe/cwe-269) | Improper Privilege Management |
| Child | [CWE-9](https://radicalnotion.ai/cwe/cwe-9) | J2EE Misconfiguration: Weak Access Permissions for EJB Methods |
| Child | [CWE-520](https://radicalnotion.ai/cwe/cwe-520) | .NET Misconfiguration: Use of Impersonation |
| Child | [CWE-556](https://radicalnotion.ai/cwe/cwe-556) | ASP.NET Misconfiguration: Use of Identity Impersonation |
| Child | [CWE-1022](https://radicalnotion.ai/cwe/cwe-1022) | Use of Web Link to Untrusted Target with window.opener Access |
| Child | [CWE-1268](https://radicalnotion.ai/cwe/cwe-1268) | Policy Privileges are not Assigned Consistently Between Control and Data Agents |
| Can also be | [CWE-286](https://radicalnotion.ai/cwe/cwe-286) | Incorrect User Management |

## Taxonomy mappings

| Taxonomy | Entry | Id | Fit |
| --- | --- | --- | --- |
| PLOVER | Incorrect Privilege Assignment | - | - |
| The CERT Oracle Secure Coding Standard for Java (2011) | Do not allow privileged blocks to leak sensitive information across a trust boundary | SEC00-J | - |
| The CERT Oracle Secure Coding Standard for Java (2011) | Do not allow tainted variables in privileged blocks | SEC01-J | - |

## Frequently asked questions

### What is CWE-266?

A product incorrectly assigns a privilege to a particular actor, creating an unintended sphere of control for that actor.

### What CVEs are caused by CWE-266?

713 recorded CVEs are attributed to CWE-266, including CVE-2026-48172, CVE-2026-39773 and CVE-2026-23800. 1 is listed in CISA's Known Exploited Vulnerabilities (KEV) catalog.

### How do you prevent CWE-266?

Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.

### What are the consequences of CWE-266?

Exploiting CWE-266 can lead to: Gain Privileges or Assume Identity.

### Is CWE-266 actively exploited?

Yes. 1 CWE-266 vulnerability is in CISA's KEV catalog of actively exploited flaws, out of 713 recorded CVEs.

Primary source: [MITRE CWE](https://cwe.mitre.org/data/definitions/266.html)

---

Source: [RadicalNotion.AI](https://radicalnotion.ai/cwe/cwe-266). Licensed CC BY-NC 4.0; attribute RadicalNotion.AI and link the source page when you reuse this data.
