Privilege leastness, often called the principle of least privilege, means giving each account, application, or process only the permissions needed to perform its intended tasks-and no more. Access should be limited in scope and duration wherever practical.
This principle reduces the damage an attacker or a software flaw can cause. For example, if a developer tool processes an untrusted repository and unexpectedly runs code, a restricted account can help prevent that process from accessing unrelated files, credentials, or system settings. Defenses include using non-administrator accounts for routine work, limiting application permissions, and separating sensitive credentials from tools that handle untrusted content.


