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.
Impact: Gain Privileges or Assume Identity
An attacker could gain unauthorized access to system resources.
Strategy: Separation of Privilege
pythonpython
#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