{
  "id": "authorization",
  "title": "Authorization",
  "lang": "en",
  "source_lang": "en",
  "summary": "Authorization determines which actions a user, service, or other principal may perform on protected resources under a security policy.",
  "category": "computer-science",
  "subcategory": "networks-security",
  "type": "concept",
  "aliases": [
    "Authorisation"
  ],
  "generated_at": "2026-11-05",
  "model": "pro/gpt-6.1-sol",
  "url": "https://aiwiki.page/en/authorization/",
  "translations": {
    "zh-Hans": {
      "url": "https://aiwiki.page/zh/authorization/",
      "json": "https://aiwiki.page/zh/authorization.json"
    }
  },
  "sections": [
    {
      "heading": "",
      "text": "Authorization is the process of determining whether a user, program, device, or other entity is permitted to perform a particular action on a protected resource. It also refers to the permissions or authority granted through that process. In computer science, authorization governs activities ranging from opening a file and querying a database to deploying cloud infrastructure or approving a payment. It is a central component of access control and differs from authentication: authentication establishes evidence about an entity’s identity or credentials, whereas authorization determines what that entity may do.\n\nAn authorization decision depends on more than identity. Relevant information may include the requested operation, the resource’s owner, organizational roles, relationships between users and objects, device properties, time, and the purpose of access. Systems express these conditions through policies and enforce them at boundaries where resources can be accessed. Effective authorization therefore requires both a correct policy and an implementation that applies that policy consistently.\n\nAuthorization mechanisms range from operating-system permission bits to distributed policy engines and delegated access protocols. Their design connects security models, application architecture, organizational administration, and the behavior of systems under failure. A valid login, a correctly signed token, or an encrypted connection does not by itself establish permission to access a particular resource."
    },
    {
      "heading": "Foundations and historical development",
      "text": "An authorization request can be represented as a question about a subject, an action, a resource, and a context. The subject is the active entity requesting access; a principal is an entity to which a system can attribute identity or authority. Principals include people, service accounts, processes, and devices. Resources may be files, records, network services, administrative operations, or physical equipment controlled by software. Actions are resource-specific: reading a document, changing its owner, and granting another user access are distinct permissions even when they concern the same object.\n\nA simplified decision function is\n\n\\[D(s,a,r,c,P)\\in\\{\\mathrm{permit},\\mathrm{deny}\\},\\]\n\nwhere \\(s\\) is the subject, \\(a\\) the action, \\(r\\) the resource, \\(c\\) the relevant context, and \\(P\\) the applicable policy. Real policy systems may also return “not applicable,” “indeterminate,” or obligations that must accompany a permit decision. For example, a policy may permit access only if the response is filtered or the event is recorded. An enforcement component must interpret these additional results correctly; an indeterminate result is not equivalent to permission.\n\nModern authorization developed from protection problems in multiuser computing. Time-sharing systems needed to prevent one user’s program from reading another user’s memory or modifying shared system files. In 1971, Butler Lampson described the access matrix as a general model of protection: rows represent protection domains or subjects, columns represent objects, and entries record allowed operations. An access-control matrix remains useful conceptually, although practical systems rarely store a complete matrix because most entries would be empty.\n\nSecurity models subsequently addressed different objectives. The Bell–LaPadula model, developed in the 1970s, formalized confidentiality constraints involving security levels; its familiar rules restrict reading higher-classified information and writing information to lower classifications. The Biba model addressed integrity through different information-flow constraints. These models illustrate that permission is not simply a matter of ownership: an organization may prohibit a transfer even when the immediate participants would consent.\n\nIn their 1975 paper on computer-system protection, Jerome Saltzer and Michael Schroeder articulated principles including fail-safe defaults, complete mediation, and least privilege. These remain central to authorization. Fail-safe defaults make access depend on positive permission rather than the absence of a prohibition. Complete mediation requires protected accesses to be checked, while least privilege limits authority to what a task requires. The practical difficulty lies in preserving these properties across caches, background jobs, administrative interfaces, and changing organizational relationships."
    },
    {
      "heading": "Identity, permissions, and representations of authority",
      "text": "Authentication supplies evidence that authorization can use, but the two processes remain logically separate. A user may authenticate successfully yet lack permission to view a particular account. Conversely, a public document may be readable without an identified user. Systems often distinguish an unauthenticated principal, an authenticated user, and an authenticated service acting on a user’s behalf. Treating all authenticated callers as equally trusted eliminates the very distinctions authorization is intended to enforce.\n\nPermissions usually associate an operation with a resource or resource class. A permission such as “read invoices” is broader than “read invoice 741,” while “administer billing” may imply several operations. The granularity must match the application’s security requirements. Checking only whether a caller can invoke an application programming interface endpoint may be insufficient when that endpoint handles objects belonging to many customers. Authorization may need to consider the individual object, specific fields, and the proposed change, not merely the route or method name.\n\nAn access-control list stores permissions with an object, identifying principals or groups and the operations they may perform. A document might allow its owner to edit it, members of a review group to comment, and everyone else no access. This representation makes it relatively straightforward to answer who may access that document. Determining everything a particular user can access, however, may require searching many objects or maintaining a separate index. Group membership, inheritance, and explicit denial rules add further complexity.\n\nA different representation is capability-based security. A capability is an unforgeable reference or token that conveys authority over an object. A process possessing a capability to read a particular object can exercise that authority without necessarily having a globally meaningful identity. Capabilities can combine object designation and permission, reducing reliance on broad ambient privileges. Object-capability systems constrain how such references are created and transferred; possession of an ordinary, guessable object identifier is not equivalent to possession of a secure capability.\n\nRevocation exposes an important difference between representations. An access-control list can often be changed at the resource, while a previously distributed capability may require indirection, expiration, revocation tracking, or replacement of the underlying object reference. Neither representation is inherently superior in all settings. Lists emphasize centrally inspectable relationships between objects and principals; capabilities emphasize explicit possession and delegation of authority. Hybrid systems are common, such as a server that checks an access-control list before issuing a short-lived download token."
    },
    {
      "heading": "Role-, attribute-, and relationship-based policies",
      "text": "Role-based access control assigns permissions to roles and assigns users to those roles. Instead of granting each accountant individual rights to every accounting operation, an organization can attach those permissions to an accountant role. David Ferraiolo and Richard Kuhn published an influential formulation in 1992, and the ANSI INCITS 359 standard appeared in 2004. Role hierarchies allow one role to inherit permissions from another, while constraints limit which combinations of roles may be assigned or activated.\n\nRole constraints can express separation of duties. For example, the person who creates a payment instruction may be prohibited from approving it. Static separation restricts role assignments, whereas dynamic separation restricts combinations of roles activated during a session or task. Some requirements need still more detail: two people may both hold an approval role, but a transaction may require approval by someone other than its creator. A simple role check cannot express that distinction without incorporating transaction state.\n\nAttribute-based access control evaluates properties of subjects, resources, actions, and environments. A policy might permit a support engineer to inspect a customer record only when the engineer belongs to the relevant support team, the case is assigned to that engineer, and the record is not subject to an additional restriction. NIST Special Publication 800-162, first published in 2014, describes this approach. Attributes can make policies more precise than a large collection of narrowly defined roles, but their reliability depends on authoritative sources, appropriate update intervals, and unambiguous meanings.\n\nRelationship-based authorization evaluates links among entities. In a collaboration service, a user might edit a document because the user belongs to a team that owns the document’s parent folder. A relationship can be represented as a tuple such as \\((\\text{document},\\text{editor},\\text{user})\\), with rules deriving additional permissions through group membership or containment. Google’s Zanzibar system, described publicly in 2019, demonstrated a distributed approach to relationship-based authorization for large collections of objects. Such designs must define inheritance, recursion, cycles, and consistency between relationship updates and checks.\n\nThe categories overlap rather than forming mutually exclusive alternatives. A role may be represented as an attribute, and a group membership may be modeled as a relationship. The important distinction is how policy is expressed, administered, and evaluated. Role systems can suffer from role proliferation when every exception creates a new role. Attribute systems can become difficult to understand when many conditions interact. Relationship systems can conceal unexpectedly broad access through nested groups or inherited sharing. Effective policy analysis therefore examines the resulting permissions, not merely the model’s name."
    },
    {
      "heading": "Policy decision and enforcement architecture",
      "text": "Authorization architectures often distinguish a policy decision point from a policy enforcement point. The decision point evaluates policy; the enforcement point controls the operation and applies the result. Supporting components may administer policies or provide attributes. This terminology appears in the architecture of the Extensible Access Control Markup Language, commonly called XACML, whose version 3.0 became an OASIS standard in 2013. The same conceptual separation is useful even when a system does not use XACML.\n\nConsider a request to download a report. An enforcement point obtains the caller’s authenticated identity, resolves the report’s actual owner and classification, and asks whether the caller may read it. The decision point evaluates the relevant policy and returns a decision. If access is permitted, the enforcement point delivers the report, potentially applying obligations such as removing restricted fields. A decision that is never enforced has no protective effect. Likewise, a policy engine cannot compensate for incorrect facts supplied by the application, such as a client-controlled claim about who owns the report.\n\nCentralizing policy can improve consistency across services and make policy changes easier to review. It can also introduce network latency and availability dependencies. Embedding all policy logic in each application avoids a remote call but risks inconsistent implementations and slow propagation of changes. Common compromises include a centrally administered policy distributed to local evaluators, sidecar processes, or libraries using versioned policy bundles. Each arrangement places the trust boundary differently and changes how failures and updates affect authorization.\n\nPolicy combination requires explicit semantics. If one rule permits access and another denies it, a system might use deny-overrides, permit-overrides, first-applicable evaluation, or a more specialized algorithm. These choices are not interchangeable. “Default deny” describes what happens without sufficient permission; it does not establish that every explicit denial overrides every grant. Some services distinguish identity policies, resource policies, organizational restrictions, and session limits, combining them through both unions and intersections. Understanding effective permission requires following the actual combination rules.\n\nEnforcement must also cover indirect paths. Hiding an interface button does not prevent a caller from invoking the underlying operation. A web gateway may enforce coarse permissions, but a downstream service still needs enough context to protect individual resources. Background exports, batch operations, search results, and administrative tools can bypass otherwise well-designed checks. Complete mediation does not necessarily mean contacting a central server for every byte read; it means that every protected operation remains governed by valid authority, including when an earlier decision is safely reused."
    },
    {
      "heading": "Operating systems and database authorization",
      "text": "An operating system enforces authorization at interfaces between processes and protected resources. In Unix-like systems, traditional file permissions distinguish the owner, group, and others, with read, write, and execute bits for each class. These permissions have different meanings for files and directories. Directory execute permission permits searching or traversing the directory, while directory write permission generally concerns modifying directory entries. Consequently, permission to delete a file depends substantially on the containing directory rather than on whether the file itself is writable.\n\nModern operating systems add richer controls. Access-control lists can grant permissions to additional users and groups. Linux capabilities divide some powers historically associated with the superuser into separate privileges, while mandatory access-control mechanisms can impose restrictions beyond discretionary owner-controlled permissions. The kernel provides an important enforcement boundary because ordinary applications cannot simply choose to ignore its checks. However, a kernel-level permission does not establish that an application’s own business rules are satisfied.\n\nPermissions are often checked when a resource handle is acquired rather than continuously during its use. On Unix-like systems, changing a file’s permissions does not generally invalidate an already open file descriptor. The process may retain access through that descriptor even after pathname-based access would be denied. This is not necessarily an implementation error: it reflects a model in which opening the file grants a usable reference. Similar questions arise with memory mappings, sockets, and inherited handles, making the lifetime and transfer of authority as important as the initial check.\n\nA database management system provides another authorization layer. SQL includes mechanisms such as GRANT and REVOKE, and database products commonly support users, roles, table privileges, views, and stored routines. Some also support row-level security, allowing a policy to restrict which records a session can read or modify. Definer-rights routines execute with authority associated with the routine’s owner, while invoker-rights routines use the caller’s authority. These choices affect whether a routine safely exposes a narrow operation or inadvertently supplies broader access.\n\nApplication identity and database identity need not coincide. A web application may connect through a pool using one service account while serving thousands of users. In that arrangement, the database cannot automatically infer which end user initiated a query. Authorization may reside in the application, in securely established database session context, or in both. Row filtering must also cover joins, aggregates, exports, and writes. A read policy that hides another tenant’s records is insufficient if an update or insertion can assign data to that tenant without an equivalent ownership check."
    },
    {
      "heading": "Delegation, OAuth, and tokens",
      "text": "Delegation allows one entity to act with authority derived from another. It is central to scheduled jobs, third-party integrations, service-to-service calls, and shared administration. A secure delegation mechanism identifies the relevant parties and limits what is delegated. The authority to read a calendar need not include authority to change sharing settings or delegate access onward. Delegation is therefore not merely copying an identity: it involves specifying the scope, recipient, duration, and permitted use of authority.\n\nOAuth is a widely used framework for delegated authorization. OAuth 2.0 was published in RFC 6749 in 2012. Its principal roles are the resource owner, client, authorization server, and resource server. In a typical authorization-code flow, a client directs a user to an authorization server, receives a code after the relevant authorization process, and exchanges that code for tokens. The resource server accepts an access token according to its validation rules and applies the permissions associated with it. OAuth does not itself define a general user-authentication protocol; OpenID Connect builds an identity layer on top of OAuth 2.0.\n\nAn access token may be opaque to the client or use a structured format such as a JSON Web Token. A signed token can carry claims about its issuer, intended audience, expiration, subject, and permissions. Validation requires more than verifying a digital signature: the recipient must also establish that the issuer is trusted, the token is intended for that resource, the validity interval is acceptable, and the claimed permissions cover the operation. A well-formed token with a valid signature can still be inappropriate for a particular service.\n\nScopes describe categories of delegated access, but their interpretation is defined by the authorization system and resource server. A scope named documents.read does not necessarily authorize reading every document. The resource server may still need to check ownership, sharing relationships, tenant membership, or document status. An access token is also not interchangeable with an identity token. An identity token primarily communicates an authentication result to its intended client; accepting it as an API access credential can cross protocol and audience boundaries.\n\nBearer tokens confer authority on whoever possesses them, so exposure can enable unauthorized use until expiration or revocation takes effect. Transport Layer Security protects tokens in transit but not against every form of leakage from logs, storage, or compromised applications. Proof Key for Code Exchange, standardized in RFC 7636 in 2015, binds authorization-code redemption to a verifier held by the initiating client. Sender-constrained mechanisms can additionally bind token use to a key or authenticated client connection. These controls address different threats and do not remove the resource server’s responsibility to evaluate authorization."
    },
    {
      "heading": "Distributed systems, revocation, and consistency",
      "text": "In distributed computing, authorization depends on information that may be stored and updated in several places. User status, group membership, object ownership, policy rules, and token revocations can change independently. A service making a decision must work with some version of each fact. The resulting question is not merely whether the policy is correct, but whether the facts used to evaluate it are sufficiently current for the operation being protected.\n\nCaching improves latency and availability but extends the life of earlier decisions. Suppose a service caches a positive authorization result for five minutes. Removing the user from the relevant group may not stop access through that cache immediately. Short-lived tokens impose an expiration bound on some forms of stale authority, but expiration alone is not immediate revocation. Conversely, checking a central revocation service on every request introduces additional latency and failure dependencies. Different resources may justify different bounds: reading a public draft and moving funds need not use identical freshness requirements.\n\nA particularly important problem occurs when content and permissions are observed at inconsistent points in time. A user may lose access to a document, after which the document receives sensitive new content. If the authorization system uses an old permission state while the storage system returns the new content, the former user can receive information created after revocation. Designs can address this through versioned permission data, consistency tokens, coordinated reads, or stronger ordering guarantees. The appropriate mechanism depends on how the authorization store and resource store interact.\n\nAuthorization can also race with the protected action. Checking permission and then acting later may be unsafe if ownership, policy, or resource state changes in between. This is a form of race condition, often described as a time-of-check-to-time-of-use problem. For operations governed by mutable state, the check may need to occur within the same database transaction as the change, or use a conditional update that verifies the expected state. Long-running jobs introduce a related choice: whether authorization is fixed when the job is submitted or reevaluated during execution.\n\nA zero-trust architecture treats network location as insufficient evidence of permission and emphasizes explicit, context-sensitive access decisions. This is relevant to microservices, where one request may cause a chain of internal calls. Each service must distinguish its own authority from authority delegated by an upstream caller. When a policy service is unavailable, denying access preserves restrictions but may interrupt essential operations; permitting access preserves availability at the risk of violating policy. Systems can instead use bounded, previously validated authority or separate emergency procedures, but those choices must be part of the policy rather than accidental failure behavior."
    },
    {
      "heading": "Administration, privilege lifecycle, and accountability",
      "text": "Authorization is an ongoing administrative process rather than a one-time configuration. Permissions are created when people join organizations, change when responsibilities shift, and should cease to apply when the relevant relationship ends. Service accounts, automated jobs, and external integrations have comparable lifecycles, although they may lack an obvious human departure event. Unused accounts and obsolete grants can therefore persist long after the original operational need disappears.\n\nThe effective authority of a principal may be indirect. A user who cannot read a protected database may nevertheless be able to modify an application that reads it, assume a privileged role, reset another user’s credentials, or change a policy. These are authorization relationships in their own right. Privilege analysis must account for the ability to grant permissions and influence privileged execution, not just list the resources directly readable by a user. Administrative control over a role can be as consequential as membership in that role.\n\nPrivileged access management applies additional controls to powerful accounts and operations. Common mechanisms include time-bounded role activation, approval workflows, isolated administrative sessions, and recording of sensitive actions. Just-in-time elevation reduces the period during which standing authority is available, while narrowly defined privileges reduce what that elevation permits. Emergency, or “break-glass,” access follows a different path from ordinary approval, but its authority, activation conditions, and audit treatment still need explicit definition.\n\nAuthorization records support accountability when they capture enough context to explain what occurred. Useful fields can include the authenticated principal, any represented user, the client or service, the requested operation, resource identifiers, the decision, the policy version, and the time. Decision logs and action logs answer different questions: a permit decision does not prove that an operation completed, while a completed operation should be traceable to the authority under which it ran. Logs also require protection because they can contain sensitive identifiers, business relationships, or credentials mistakenly included in requests.\n\nPeriodic access reviews compare existing grants with current responsibilities and resource ownership. Their effectiveness depends on comprehensible evidence: an unexplained role name or a large list of opaque identifiers is difficult to assess. Automated analysis can identify inactive grants, unexpected external sharing, or combinations of privileges that violate separation rules. It cannot by itself determine every legitimate business need. In cloud computing and other large environments, policy administration therefore combines technical constraints, ownership records, review workflows, and evidence about actual use, while recognizing that a rarely used emergency permission may still have a defined purpose."
    },
    {
      "heading": "Failure modes, testing, and formal assurance",
      "text": "Broken authorization frequently arises when a system authenticates the caller but fails to check access to the requested object or operation. Changing a record identifier in a request may expose another user’s data if the server checks only that a session is valid. Object identifiers that are difficult to guess can reduce casual discovery, but unpredictability is not a substitute for permission checks. Related failures occur when a caller may read an object but can also modify restricted fields, change its owner, or invoke an administrative operation through an alternative endpoint.\n\nHorizontal privilege escalation crosses boundaries between similarly privileged users, such as one customer reading another customer’s records. Vertical privilege escalation obtains a more powerful role or operation. Multi-tenant applications must defend against both. Tenant identifiers supplied by clients require validation against authenticated membership and the target resource’s actual tenant. Filtering the main query is not enough if caches, search indexes, file storage paths, or asynchronous exports use different assumptions about tenant ownership.\n\nThe confused deputy problem occurs when a component uses its own authority on behalf of a caller without adequately distinguishing the caller’s authority. A conversion service, for example, may have broad storage access but should not read any file merely because an unprivileged user supplied its name. Explicitly scoped resource references and separate handling of service authority and delegated authority can reduce this risk. In systems using AI agents, prompt injection creates a related boundary problem: untrusted content may attempt to induce privileged tool use. Authorization must remain enforced by the tools or surrounding application rather than depending solely on the model’s interpretation of instructions.\n\nTesting authorization requires checking both permitted and forbidden behavior. A test matrix can vary principal, resource ownership, role, action, tenant, and context. Negative cases include cross-user access, missing credentials, expired or wrong-audience tokens, revoked membership, and attempts to change protected fields. Workflow tests examine whether individually permitted operations can be combined to bypass a restriction. Concurrency tests exercise policy changes during operations, while fault tests examine what happens when an attribute source or decision service is unavailable. These tests are distinct from verifying that legitimate users can complete a successful workflow.\n\nFormal verification and model checking can analyze properties such as whether a principal can acquire a forbidden permission through a sequence of grants. The general protection-system safety problem is difficult: Harrison, Ruzzo, and Ullman showed in 1976 that deciding whether a right can be leaked is undecidable for their general model. Restricted models and bounded configurations remain amenable to analysis. Practical policy tools can detect unreachable rules, conflicting conditions, unintended public access, or privilege paths, but their conclusions depend on the fidelity of the model. A proof about policy does not automatically cover omitted enforcement paths, incorrect resource attributes, or implementation defects."
    }
  ],
  "links": [
    "computer-science",
    "access-control",
    "authentication",
    "time-sharing",
    "least-privilege",
    "application-programming-interface",
    "capability-based-security",
    "attribute-based-access-control",
    "operating-system",
    "unix",
    "linux",
    "kernel-operating-system",
    "database-management-system",
    "sql",
    "digital-signature",
    "transport-layer-security",
    "distributed-computing",
    "race-condition",
    "database-transaction",
    "zero-trust-architecture",
    "cloud-computing",
    "confused-deputy-problem",
    "ai-agent",
    "prompt-injection",
    "formal-verification",
    "model-checking"
  ],
  "sources": [],
  "license": "https://creativecommons.org/licenses/by/4.0/"
}