CWE-283 Base Borrador

Unverified Ownership

This vulnerability occurs when an application fails to confirm that a user has legitimate ownership rights to a sensitive resource before allowing them to perform actions on it.

Definición

What is CWE-283?

This vulnerability occurs when an application fails to confirm that a user has legitimate ownership rights to a sensitive resource before allowing them to perform actions on it.
At its core, this flaw is about broken authorization. The application might check if a user is authenticated but then skips the crucial second step: verifying that the specific data or function they're trying to access actually belongs to them. This often happens when developers use an identifier from the client (like an ID in a URL, form field, or cookie) to directly fetch or modify a database record without first checking if the current session is authorized for that exact record. Exploiting this weakness is a primary goal for attackers, leading directly to data breaches and privilege escalation. For example, by simply changing a number in a URL parameter, an attacker could view another user's private messages, financial details, or administrative panels. To prevent this, every single request for a user-specific resource must be validated against the current session's ownership rights, ensuring the user is only ever acting upon resources they truly own.
Impacto en el mundo real

Real-world CVEs caused by CWE-283

  • Program does not verify the owner of a UNIX socket that is used for sending a password.

  • Owner of special device not checked, allowing root.

Cómo lo explotan los atacantes

Ruta del atacante paso a paso

  1. 1

    This function is part of a privileged program that takes input from users with potentially lower privileges.

  2. 2

    This code does not confirm that the process to be killed is owned by the requesting user, thus allowing an attacker to kill arbitrary processes.

  3. 3

    This function remedies the problem by checking the owner of the process before killing it:

Ejemplo de código vulnerable

Vulnerable Python

This function is part of a privileged program that takes input from users with potentially lower privileges.

Vulnerable Python
def killProcess(processID):
  	os.kill(processID, signal.SIGKILL)
Ejemplo de código seguro

Secure Python

This function remedies the problem by checking the owner of the process before killing it:

Seguro Python
def killProcess(processID):
  		user = getCurrentUser()
```
#Check process owner against requesting user* 
  		if getProcessOwner(processID) == user:
  		```
  			os.kill(processID, signal.SIGKILL)
  			return
  		else:
  			print("You cannot kill a process you don't own")
  			return
What changed: the unsafe sink is replaced (or the input is validated/escaped) so the same payload no longer triggers the weakness.
Lista de prevención

How to prevent CWE-283

  • Architecture and Design / Operation Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.
  • Architecture and Design Consider following the principle of separation of privilege. Require multiple conditions to be met before permitting access to a system resource.
Señales de detección

How to detect CWE-283

SAST High

Ejecuta análisis estático (SAST) sobre el código buscando el patrón inseguro en el flujo de datos.

DAST Moderate

Ejecuta pruebas dinámicas de seguridad de aplicaciones (DAST) contra el endpoint en vivo.

Runtime Moderate

Vigila los logs en tiempo de ejecución para detectar trazas de excepción inusuales, entradas malformadas o intentos de bypass de autorización.

Code review Moderate

Revisión de código: marca cualquier código nuevo que maneje entrada desde esta superficie sin usar los helpers validados del framework.

Auto-corrección de Plexicus

Plexicus detecta automáticamente CWE-283 y abre un PR de corrección en menos de 60 segundos.

Codex Remedium escanea cada commit, identifica esta debilidad concreta y entrega un pull request listo para revisión con el parche. Sin tickets. Sin traspasos.

Preguntas frecuentes

Frequently asked questions

¿Qué es CWE-283?

This vulnerability occurs when an application fails to confirm that a user has legitimate ownership rights to a sensitive resource before allowing them to perform actions on it.

¿Qué gravedad tiene CWE-283?

MITRE no ha publicado una calificación de probabilidad de explotación para esta debilidad. Trátala como de impacto medio hasta que tu modelo de amenazas demuestre lo contrario.

¿Qué lenguajes o plataformas se ven afectados por CWE-283?

MITRE no ha especificado plataformas afectadas para esta CWE — puede aplicar a la mayoría de los stacks de aplicaciones.

¿Cómo puedo prevenir CWE-283?

Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software. Consider following the principle of separation of privilege. Require multiple conditions to be met before permitting access to a system resource.

¿Cómo detecta y corrige Plexicus CWE-283?

El motor SAST de Plexicus detecta la firma de flujo de datos para CWE-283 en cada commit. Cuando hay coincidencia, nuestro agente Codex Remedium abre un PR de corrección con el código corregido, las pruebas y un resumen de una línea para el revisor.

¿Dónde puedo aprender más sobre CWE-283?

MITRE publica la definición canónica en https://cwe.mitre.org/data/definitions/283.html. También puedes consultar la documentación de OWASP y NIST para guías relacionadas.

Listo cuando tú lo estés

Deja de pagar por desarrollador.
Empieza a cerrar el bucle.

Plexicus es el ASPM nativo de IA que escanea, filtra, corrige, pentestea y explica — de forma autónoma. Desarrolladores ilimitados, repos ilimitados, acciones de IA de uso justo. Nivel gratuito real, €269/mo anual cuando estés listo.