Kelly Mears

Least Privilege

Granting only the permissions actually required, so a compromise has a small ceiling.

Systems & Tooling2 min read211 words12 out · 37 in
also calledPrinciple of least privilegeScoped credentials

Least privilege is the principle that any component should hold only the permissions it needs to do its job. Its value is not that it prevents compromise but that it bounds it: the question after any breach is what the compromised credential could reach.

The principle is stated easily and applied poorly, because broad permissions are convenient and the cost of narrowing them is paid up front. A few recurring patterns:

Scope tokens to operations, not to roles. A process that only reads should hold a read-only credential. A process that only posts a comment should not hold one that can write to the repository.

Know which credential is actually in play. A permissions declaration frequently bounds the platform-issued token while some other, separately-minted credential does the real work — so tightening the declaration achieves nothing. See Environment Variable for the related problem of an unexpected credential taking precedence.

Constrain outbound capability, not just inbound. For anything running untrusted input through an agent, the exfiltration path matters more than the permission set. See Prompt Injection and Supply Chain Security.

Wildcards are not a configuration. An allowlist of "anything" in a system that defaults to nothing is a common and understandable shortcut, and it grants exactly what the mechanism existed to restrict.

See also9

Secret Management

Storing, distributing, and rotating credentials without embedding them in code or history.

Systems & Tooling33 connections

Guardrail

A rule constraining what a model may do, enforced by prompt, schema, or surrounding code.

Agents & Language Models17 connections

Same-Origin Policy

The browser rule isolating documents by scheme, host, and port, and the mechanisms for relaxing it.

Web Platform30 connections

Code Signing

Cryptographically attesting who produced a binary, and the operating-system checks built on it.

Systems & Tooling27 connections

Model Context Protocol

An open protocol for exposing tools, data, and prompts to AI applications through a uniform interface.

Agents & Language Models11 connections

System Prompt

The standing instructions that frame every turn of a conversation with a model.

Agents & Language Models16 connections

Browser Extension

Small programs that modify the browser and the pages it shows, from bookmarklets and userscripts to ad blockers, with access broad enough to make them a standing security risk.

Web Platform6 connections

Server-Side Request Forgery

Tricking a server into making requests on an attacker's behalf, reaching internal services and cloud credential endpoints that the attacker could never reach directly, behind some of the largest cloud breaches.

Web Platform14 connections

Time-of-Check to Time-of-Use

A race where a program checks a condition and then acts on it, but the world changes in between, the root of classic file-permission exploits and of double-spending bugs in web applications.

Systems & Tooling12 connections

Linked from37