This vulnerability occurs when software fails to verify access permissions every single time a user or process tries to use a resource. Instead, it might rely on a single, outdated check, creating a security gap if the user's privileges are later revoked or changed.
Complete mediation is the security principle that every access to every object must be checked for authorization. Developers often break this rule by caching an initial permission check—like when a user first opens a file or page—and then assuming that permission remains valid for the entire session. This creates a time-of-check to time-of-use (TOCTOU) window where a user's reduced privileges are not enforced, allowing continued access they should no longer have. To prevent this, implement a consistent authorization layer that validates permissions on each individual request, regardless of previous checks. Treat all access as stateless and never assume a prior grant is still valid. This is especially critical in long-running sessions, multi-step transactions, or systems with dynamic user roles, where privilege changes must be reflected immediately to close security loopholes.
Impact: Gain Privileges or Assume IdentityExecute Unauthorized Code or CommandsBypass Protection MechanismRead Application DataOther
A user might retain access to a critical resource even after privileges have been revoked, possibly allowing access to privileged functionality or sensitive information, depending on the role of the resource.