IAM Quiz
You are deploying an application on Amazon EC2, which must call AWS APIs. What method should you use to securely pass credentials to the application?
A. PassAPI credentials to the instance using Instance userdata.
B. StoreAPI credentials as an object in Amazon S3.
C. Embedthe API credentials into your application.
D. AssignIAM roles to the EC2 Instances.
D AWS Documentation mentions the following: You can use roles to delegate access to users, applications, or services that don’t normally have access to your AWS resources. It is not a good practice to use IAM credentials for a production based application. A good practice however, is to use IAM Roles. For more information on IAM Roles, please visit the following URL: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html