Infrastructure Security

Which IAM resource delivers an IAM role to an EC2 instance so its applications can obtain temporary AWS credentials?

Show the answer

Correct answerC. An instance profile

AWhy not this: A service-linked role lets a particular AWS service perform actions on your behalf.

BWhy not this: A resource-based policy controls access to a resource; it does not deliver role credentials to EC2.

CWhy this is right: An instance profile associates an IAM role with EC2 so applications can obtain temporary role credentials.

DWhy not this: A permissions boundary limits a role's maximum permissions; it does not associate the role with an instance.

An instance profile is the container used to associate an IAM role with an EC2 instance. A service-linked role is used by its linked AWS service, not as the application's instance role.