AWS Certified Developer – Associate — Question 72

A development team is building a new application that will run on Amazon EC2 and use Amazon DynamoDB as a storage layer. The developers all have assigned IAM user accounts in the same IAM group. The developers currently can launch EC2 instances, and they need to be able to launch EC2 instances with an instance role allowing access to Amazon DynamoDB.

Which AWS IAM changes are needed when creating an instance role to provide this functionality?

Answer options

Correct answer: B

Explanation

Option B is correct because it specifies that the trust policy must allow Amazon EC2 to assume the role, which is necessary for the instance role's functionality. The permissions policy attached to the role must allow access to DynamoDB, and developers only need the iam:PassRole permission to use the instance role. The other options incorrectly include DynamoDB in the trust policy or require permissions that are not needed for this scenario.