exam questions

Exam AWS Certified Developer Associate All Questions

View all questions & answers for the AWS Certified Developer Associate exam

Exam AWS Certified Developer Associate topic 1 question 5 discussion

Exam question from Amazon's AWS Certified Developer Associate
Question #: 5
Topic #: 1
[All AWS Certified Developer Associate Questions]

A developer designed an application on an Amazon EC2 instance. The application makes API requests to objects in an Amazon S3 bucket.
Which combination of steps will ensure that the application makes the API requests in the MOST secure manner? (Choose two.)

  • A. Create an IAM user that has permissions to the S3 bucket. Add the user to an IAM group.
  • B. Create an IAM role that has permissions to the S3 bucket.
  • C. Add the IAM role to an instance profile. Attach the instance profile to the EC2 instance.
  • D. Create an IAM role that has permissions to the S3 bucket. Assign the role to an 1AM group.
  • E. Store the credentials of the IAM user in the environment variables on the EC2 instance.
Show Suggested Answer Hide Answer
Suggested Answer: BC 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
GenePoole
Highly Voted 2 years, 6 months ago
Selected Answer: BC
You choice is either User or Role. Creating a role and assigning it to something is preffered over creating a user. An IAM role is an IAM identity that you can create in your account that has specific permissions. An IAM role is similar to an IAM user, in that it is an AWS identity with permission policies that determine what the identity can and cannot do in AWS. However, instead of being uniquely associated with one person, a role is intended to be assumable by anyone who needs it. Also, a role does not have standard long-term credentials such as a password or access keys associated with it. Instead, when you assume a role, it provides you with temporary security credentials for your role session. A - Create User (Role is better) B - Create Role C - Add role to Resource D - Create role and add to IAM group (Users live in groups) E - Add User to EC2
upvoted 23 times
...
sumanshu
Most Recent 4 months, 1 week ago
Selected Answer: BC
A) Eliminated: IAM users are meant for human access, not applications or services.
upvoted 1 times
sumanshu
4 months, 1 week ago
D) Eliminated: IAM roles cannot be assigned to IAM groups. Groups are for grouping users together and managing their permissions collectively.
upvoted 1 times
sumanshu
4 months, 1 week ago
E) Eliminated: Storing IAM user credentials (e.g., AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY) in environment variables is highly insecure.
upvoted 1 times
sumanshu
4 months, 1 week ago
B/C - Correct. IAM roles provide temporary security credentials to the EC2 instance without hardcoding credentials or storing them in environment variables. An instance profile is the mechanism that attaches an IAM role to an EC2 instance
upvoted 1 times
...
...
...
...
blondy_chess
12 months ago
Selected Answer: BC
BC Is correct
upvoted 2 times
...
seezie
1 year ago
Using IAM role is better and using an EC2 instance profile creates opportunity to resuse profile for many more EC2. It does not make sense creating a user role for an AWS service.
upvoted 1 times
...
Baalhammun
1 year, 2 months ago
Selected Answer: BC
BC Is correct
upvoted 1 times
...
AsmaZoheb
1 year, 3 months ago
the most secure is role, so option is B and C
upvoted 1 times
...
rcaliandro
1 year, 10 months ago
Selected Answer: BC
- Create an IAM role that has permissions to the S3 bucket. - Add the IAM role to an instance profile. Attach the instance profile to the EC2 instance. We first need to create a n IAM Role with permissions to read and eventually write a specific S3 bucket. Then, we need to attach the role to the EC2 isntance through an instance profile. In this way, the ec2 instance has the permissinos to read and eventually write the specified S3 bucket
upvoted 1 times
...
pancman
2 years, 1 month ago
Saw this question in the exam today (Feb 2023)
upvoted 2 times
...
Krt5894
2 years, 2 months ago
Selected Answer: BC
It should be B and C
upvoted 1 times
...
Dirisme
2 years, 3 months ago
Instance role over IAM user ALWAYS
upvoted 1 times
...
B1112
2 years, 7 months ago
B and C
upvoted 2 times
...
IdrisAWS
2 years, 7 months ago
Role always safe. B&C
upvoted 1 times
...
thure
2 years, 7 months ago
Should be B&C
upvoted 1 times
...
Spamuel
2 years, 7 months ago
Correct!
upvoted 2 times
pond27
2 years, 7 months ago
Yes. B&C.
upvoted 1 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago