Fatskills
Practice. Master. Repeat.
Study Guide: AI Privacy and Security: Access control permissions and least privilege
Source: https://www.fatskills.com/ai-for-work/chapter/ai-privacy-and-security-access-control-permissions-and-least-privilege

AI Privacy and Security: Access control permissions and least privilege

By Fatskills Exam Guides Team — the exam nerds behind 28,500+ quizzes and 2.1M practice questions across 500+ global exams.

⏱️ ~5 min read

Access Control, Permissions, and Least Privilege

What This Is Access control ensures only authorized users or systems can interact with data, tools, or infrastructure, while least privilege limits permissions to the bare minimum needed for a task. This matters daily because over-permissioned accounts (e.g., a marketing intern with admin access to a customer database) are a leading cause of data breaches, compliance violations, and AI model poisoning. Example: A hospital restricts EHR (electronic health record) access so nurses see only their assigned patients’ data—violating this could expose HIPAA-protected information or let an attacker alter medical histories.


Key Facts & Principles

  • Principle of Least Privilege (PoLP): Grant the minimum permissions required for a role or task. Example: A data analyst needs "read-only" access to a sales database, not "edit" or "delete."
  • Role-Based Access Control (RBAC): Assign permissions to roles (e.g., "Data Scientist," "Compliance Officer") rather than individuals. Example: All "ML Engineers" get access to the model training cluster, but not the production database.
  • Attribute-Based Access Control (ABAC): Permissions depend on attributes (e.g., time of day, device location, data sensitivity). Example: A contractor can only access internal docs from the office network, not remotely.
  • Temporary Elevation: Grant elevated permissions only for a limited time and log the action. Example: A DevOps engineer gets admin rights to deploy a hotfix, revoked automatically after 1 hour.
  • Separation of Duties (SoD): Critical tasks require multiple people to prevent fraud or errors. Example: One person approves a payment, another executes it; no single user can do both.
  • Just-In-Time (JIT) Access: Permissions are granted on demand and revoked immediately after use. Example: A support agent requests access to a customer’s account to troubleshoot, then loses access post-resolution.
  • Audit Logs: Record who accessed what, when, and why for accountability. Example: A compliance team reviews logs to prove no unauthorized access occurred during an audit.
  • Default Deny: If no explicit permission exists, access is automatically blocked. Example: A new employee can’t access any systems until their role is assigned.
  • Privileged Access Management (PAM): Secure and monitor accounts with high-risk permissions (e.g., admins, service accounts). Example: Admin passwords are rotated automatically every 30 days.
  • Zero Trust: "Never trust, always verify"—every access request is authenticated, authorized, and encrypted. Example: Even an internal user must re-authenticate to access a sensitive AI training dataset.

Step-by-Step Application

  1. Inventory Assets and Risks
  2. List all systems, data, and tools (e.g., databases, APIs, cloud storage, AI models).
  3. Identify sensitivity levels (e.g., PII, proprietary code, public docs) and threat vectors (e.g., insider threats, credential stuffing).
  4. Example: A fintech company tags customer transaction data as "High Risk" and AI model weights as "Medium Risk."

  5. Define Roles and Permissions

  6. Map job functions to roles (e.g., "Data Analyst," "ML Model Reviewer").
  7. Assign least-privilege permissions per role (e.g., "read-only" for analysts, "approve/deploy" for reviewers).
  8. Tool: Use AWS IAM, Azure RBAC, or Okta to create and enforce roles.

  9. Implement Access Controls

  10. Apply RBAC/ABAC rules to systems (e.g., "Only ‘Compliance Officers’ can export audit logs").
  11. Enable MFA for all privileged accounts and JIT access for temporary needs.
  12. Example: A cloud engineer requests "admin" access to a Kubernetes cluster via a PAM tool (e.g., CyberArk), which grants it for 1 hour.

  13. Monitor and Audit

  14. Set up real-time alerts for unusual activity (e.g., a user accessing 10x more data than usual).
  15. Schedule quarterly access reviews to remove unused permissions.
  16. Tool: Use Splunk or Datadog to monitor logs; automate reviews with tools like SailPoint.

  17. Enforce Default Deny and Zero Trust

  18. Configure systems to block all access by default (e.g., firewall rules, IAM policies).
  19. Require re-authentication for sensitive actions (e.g., downloading a dataset with PII).
  20. Example: A data scientist must request access to a "High Risk" dataset via a ticketing system, which triggers a manager approval.

  21. Train and Document

  22. Train teams on why least privilege matters (e.g., "Over-permissioned accounts are the #1 cause of breaches").
  23. Document who has access to what and how to request changes.
  24. Example: A wiki page lists all roles, their permissions, and the process to request access.

Common Mistakes

  • Mistake: Granting "admin" or "full access" by default to save time. Correction: Start with no access and add permissions only when justified. Why: 80% of breaches involve over-permissioned accounts (Verizon DBIR).

  • Mistake: Using shared accounts (e.g., "[email protected]") for convenience. Correction: Assign individual accounts with least-privilege roles. Why: Shared accounts make auditing impossible and increase risk.

  • Mistake: Ignoring service accounts (e.g., CI/CD pipelines, AI model APIs). Correction: Treat service accounts like human users—apply RBAC, rotate credentials, and monitor activity. Why: Attackers often target unmonitored service accounts.

  • Mistake: Skipping access reviews because "it’s too manual." Correction: Automate reviews with tools like Okta or SailPoint. Why: Unused permissions accumulate over time (e.g., ex-employees, role changes).

  • Mistake: Assuming "internal" users are trustworthy. Correction: Enforce Zero Trust—verify every access request, even from inside the network. Why: Insider threats account for ~30% of breaches (Ponemon Institute).


Practical Tips

  • Start with "High Risk" systems first: Prioritize access controls for databases with PII, AI model training data, and production environments.
  • Use "break-glass" accounts sparingly: Reserve emergency admin accounts for true crises (e.g., a ransomware attack) and log all usage.
  • Leverage automation: Use tools like Terraform or AWS IAM Access Analyzer to detect and remove unused permissions automatically.
  • Pair access controls with data classification: Tag data by sensitivity (e.g., "Public," "Internal," "Confidential") and apply permissions accordingly.

Quick Practice Scenario

Scenario: Your team is deploying a new AI chatbot that accesses customer support tickets to generate responses. The chatbot’s service account currently has "read/write" access to all tickets, including those marked "High Sensitivity" (e.g., payment disputes). Question: What’s the minimum permission change needed to follow least privilege? Answer: Restrict the chatbot’s service account to "read-only" access for non-sensitive tickets only. Explanation: The chatbot doesn’t need to write data or access sensitive tickets to function.


Last-Minute Cram Sheet

  1. Least Privilege: Only grant permissions absolutely needed for a task.
  2. RBAC: Assign permissions to roles, not individuals.
  3. ABAC: Permissions depend on attributes (e.g., time, location, data sensitivity).
  4. JIT Access: Grant permissions on demand, revoke immediately after use.
  5. Default Deny: Block access unless explicitly allowed.
  6. Zero Trust: "Never trust, always verify"—authenticate every request.
  7. Separation of Duties: Critical tasks require multiple people.
  8. Audit Logs: Record who accessed what, when, and why.
  9. Shared accounts: Avoid—use individual accounts with least privilege.
  10. Service accounts: Treat like human users—apply RBAC, monitor, rotate credentials.