Interview Prep/AWS/IAM Best Practices

When do you use permission boundaries in production?

IntermediateProductionIAM Best Practices
Answer

When you delegate IAM creation. Developers or pipelines can create roles for their apps, but only if they attach a boundary, and the boundary caps what any created role can ever do:

{
  "Effect": "Deny",
  "Action": ["iam:CreateRole", "iam:PutRolePermissionsBoundary"],
  "Resource": "*",
  "Condition": {"StringNotEquals": {"iam:PermissionsBoundary": "arn:aws:iam::111122223333:policy/AppBoundary"}}
}

Also deny deleting the boundary and editing the boundary policy itself. Effective permissions are the intersection of identity policy and boundary.

aws All AWS questions Roadmap: AWS core services

More on IAM Best Practices