Design Secure Architectures
A company frequently creates new projects and tags each project's IAM roles and Amazon EC2 instances with a Project value. How can it allow roles to manage only matching instances without creating a separate policy for every project?
Show the answer
Correct answerB. Compare principal and resource tags in a shared IAM policy.
AWhy not this: SCPs limit available permissions; they do not grant access.
BWhy this is right: Tag conditions can authorize supported EC2 actions when the role's Project tag matches the instance's Project tag.
CWhy not this: EC2 instances do not support resource-based policies for granting this management access.
DWhy not this: IAM groups contain IAM users, not IAM roles, and separate groups would not implement the required tag comparison.
Attribute-based access control uses policy conditions to compare principal tags with resource tags, allowing one policy to serve many projects. IAM groups cannot contain roles and would not provide this tag-based authorization.