cloud-iam-least-privilege
Skill1 starsChanged 33 days agoMITView on GitHub
Review and reduce cloud and platform permissions to least privilege — human and workload identities, wildcard policies, long-lived keys, cross-account trust, privilege escalation paths, break-glass and access reviews. Use when auditing AWS, Azure, GCP or Kubernetes RBAC permissions, after an incident, or when onboarding automation such as CI or AI agents.
In this repository105 other files it gives its agents.
- AGENTS.mdAGENTS.md
- instructions/AGENTS.mdAGENTS.md
- accessibility-reviewSkill
- agent-evaluationSkill
- agent-guardrailsSkill
- agenthub-routerSkill
- ai-red-teamingSkill
- ansible-reviewSkill
- api-designSkill
- api-integrationSkill
- architecture-decisionSkill
- backup-restoreSkill
- caching-strategySkill
- chaos-engineeringSkill
- ci-cd-pipeline-designSkill
- cloud-cost-optimizationSkill
- code-reviewSkill
- container-image-optimizationSkill
- cyber-resilience-actSkill
- database-migrationsSkill
- data-pipeline-reviewSkill
- data-privacySkill
- data-quality-checksSkill
- debugging-root-causeSkill
- dependency-auditSkill
- dependency-upgradeSkill
- disaster-recovery-drillSkill
- docker-hardeningSkill
- documentationSkill
- dora-readinessSkill
- dpiaSkill
- email-deliverabilitySkill
- embedding-model-selectionSkill
- error-handling-reviewSkill
- eu-ai-act-readinessSkill
- eu-data-sovereigntySkill
- european-accessibility-actSkill
- event-driven-architectureSkill
- feature-flagsSkill
- frontend-reviewSkill
- gdpr-dsar-handlingSkill
- github-actionsSkill
- gitlab-ciSkill
- git-workflowSkill
- go-developmentSkill
- graphql-api-reviewSkill
- helm-chart-reviewSkill
- i18n-localizationSkill
- incident-responseSkill
- java-spring-reviewSkill
- kubernetes-reviewSkill
- linux-server-hardeningSkill
- llm-cost-analysisSkill
- llm-gateway-routingSkill
- llm-observabilitySkill
- llm-output-evaluationSkill
- llm-structured-extractionSkill
- load-testingSkill
- local-llm-servingSkill
- log-analysisSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 3 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 10
Every human and workload has only the permissions it uses, through short-lived credentials, with escalation paths closed and access …
- Distinctive: line 32
No wildcard admin grants except documented break-glass roles.
- Distinctive: line 33
Every long-lived key has an owner and a rotation date, or is removed.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Cloud IAM Least Privilege
Goal
Every human and workload has only the permissions it uses, through short-lived credentials, with escalation paths closed and access reviewed regularly.
Inputs
- Identity inventory (users, groups, roles, service accounts, CI identities, agent identities), policies, access logs or "last used" data, organization structure.
Procedure
- Inventory identities: humans via SSO only; workloads via roles or managed identities; list every long-lived access key and service-account key with owner and last use.
- Find dangerous grants: wildcard actions or resources (
*), owner/admin roles on broad scopes, permissions that allow escalation (creating keys, attaching policies, passing roles, impersonation, editing their own IAM). - Use evidence: reduce permissions to those used in the last 90 days (access analyzers or audit logs), keeping documented exceptions.
- Short-lived credentials: workload identity federation (OIDC) for CI and external workloads instead of static keys; rotate or delete unused keys.
- Separate duties: production write access separate from development; deployment identities cannot modify IAM; break-glass accounts with MFA, alerting on use and sealed credentials.
- Cross-account and external trust: external IDs or conditions on trust policies; no trust of whole external accounts without conditions.
- Guardrails: organization policies or service control policies for invariants (no public buckets, allowed regions — for example EU-only), permission boundaries for delegated administration.
- Review cycle: quarterly access reviews by owners; automatic removal of leavers through the identity provider.
Example fixture
{"Effect": "Allow", "Action": "*", "Resource": "*"} // attached to the CI deploy roleExpected findings: CI role is effectively administrator (can modify IAM and exfiltrate data); replace with deployment-scoped actions on named resources and OIDC trust limited to the protected branch.
Acceptance checks
- No wildcard admin grants except documented break-glass roles.
- Every long-lived key has an owner and a rotation date, or is removed.
- Negative case: the reduced role is tested to fail on a forbidden action (for example creating an IAM user) while the deployment still succeeds.
Output
Identity and permission inventory, risk list, policy changes and access review schedule.
Safety
Permission changes can break production workloads: apply in stages with monitoring and a rollback copy of each policy. Never remove break-glass access without a replacement. Get approval for production IAM changes. Identity inventories and access logs are personal data: restrict access, keep them in the EU or under a valid transfer mechanism, and apply retention limits (GDPR).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

