ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 197 - DOP-C02 discussion

Report
Export

A company uses AWS Organizations to manage its AWS accounts. The company has a root OU that has a child OU. The root OU has an SCP that allows all actions on all resources. The child OU has an SCP that allows all actions for Amazon DynamoDB and AWS Lambda, and denies all other actions.

The company has an AWS account that is named vendor-data in the child OU. A DevOps engineer has an IAM user that is attached to the AdministratorAccess IAM policy in the vendor-data account. The DevOps engineer attempts to launch an Amazon EC2 instance in the vendor-data account but receives an access denied error.

Which change should the DevOps engineer make to launch the EC2 instance in the vendor-data account?

A.
Attach the AmazonEC2FullAccess IAM policy to the IAM user.
Answers
A.
Attach the AmazonEC2FullAccess IAM policy to the IAM user.
B.
Create a new SCP that allows all actions for Amazon EC2. Attach the SCP to the vendor-data account.
Answers
B.
Create a new SCP that allows all actions for Amazon EC2. Attach the SCP to the vendor-data account.
C.
Update the SCP in the child OU to allow all actions for Amazon EC2.
Answers
C.
Update the SCP in the child OU to allow all actions for Amazon EC2.
D.
Create a new SCP that allows all actions for Amazon EC2. Attach the SCP to the root OU.
Answers
D.
Create a new SCP that allows all actions for Amazon EC2. Attach the SCP to the root OU.
Suggested answer: C

Explanation:

The correct answer is C. Updating the SCP in the child OU to allow all actions for Amazon EC2 will enable the DevOps engineer to launch the EC2 instance in the vendor-data account. SCPs are applied to OUs and accounts in a hierarchical manner, meaning that the SCPs attached to the parent OU are inherited by the child OU and accounts. Therefore, the SCP in the child OU overrides the SCP in the root OU and denies all actions except for DynamoDB and Lambda. By adding EC2 to the allowed actions in the child OU's SCP, the DevOps engineer can access EC2 resources in the vendor-data account.

Option A is incorrect because attaching the AmazonEC2FullAccess IAM policy to the IAM user will not grant the user access to EC2 resources. IAM policies are evaluated after SCPs, so even if the IAM policy allows EC2 actions, the SCP will still deny them.

Option B is incorrect because creating a new SCP that allows all actions for EC2 and attaching it to the vendor-data account will not work. SCPs are not cumulative, meaning that only one SCP is applied to an account at a time. The SCP attached to the account will be the SCP attached to the OU that contains the account. Therefore, option B will not change the SCP that is applied to the vendor-data account.

Option D is incorrect because creating a new SCP that allows all actions for EC2 and attaching it to the root OU will not work. As explained earlier, the SCP in the child OU overrides the SCP in the root OU and denies all actions except for DynamoDB and Lambda. Therefore, option D will not affect the SCP that is applied to the vendor-data account.

asked 16/09/2024
Ankitkumar Pandya
34 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first