exam questions

Exam AWS Certified SysOps Administrator - Associate All Questions

View all questions & answers for the AWS Certified SysOps Administrator - Associate exam

Exam AWS Certified SysOps Administrator - Associate topic 1 question 422 discussion

A company has attached the following policy to an IAM user:



Which of the following actions are allowed for the IAM user?

  • A. Amazon RDS DescribeDBInstances action in the us-east-1 Region
  • B. Amazon S3 PutObject operation in a bucket named testbucket
  • C. Amazon EC2 DescribeInstances action in the us-east-1 Region
  • D. Amazon EC2 AttachNetworkInterface action in the eu-west-1 Region
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️

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
igor12ghsj577
5 months ago
Selected Answer: C
Explicit Deny Overrides Everything - If there is a statement with an Effect: Deny that explicitly denies an action, the action is denied outright, regardless of any "Allow" statements elsewhere in the policy.
upvoted 1 times
...
6022a06
5 months ago
Selected Answer: C
Vote C. The last policy (3° part) deny all actions that are different by ec2:* e s3:GetObject, so the only permsisson are ec2:* e s3:GetObject, based of last policy. This last policy deny the first about allow rds:describe because like i said the only permission is ec2:* e s3:GetObject . So remain the 2° policy where we have ec2 :* with condition of us-east-1 Region. The only action allowed are the actions coming that from us-east-1 Region so the the answer is C.
upvoted 1 times
...
Albanki
5 months ago
Explicit deny overrides explicit allow.
upvoted 1 times
...
SysOps4
10 months ago
Selected Answer: C
C is the only possible answer for me NotAction explicitly matches everything except the specified list of actions. So there is EXPLICIT "Deny" for all actions EXCEPT "ec2:*", "s3:GetObject" , which would deny "rds:Describe*" because it is not in the list. According to AWS policy evaluation logic - "An explicit deny in any policy overrides any allows." - so Allow "rds:Describe*" would be overridden because of the Deny. https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html#policy-eval-denyallow https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_notaction.html
upvoted 3 times
...
pawake8973
1 year ago
Agree with AC but D also seems fine - note that policy uses the NotAction element. This means it denies all actions EXCEPT listed in the NotAction array. In this case, all ec2:* actions and the s3:GetObject action are not denied, which means they are allowed.
upvoted 1 times
pawake8973
1 year ago
Sorry I meant D seems fine - so EC2 action AttachNetworkInterface (it falls under ec2:*) is not denied hence allowed, and the user can perform this action in any region, including eu-west-1.
upvoted 1 times
...
...
klayytech
1 year, 1 month ago
Selected Answer: C
A. Amazon RDS DescribeDBInstances action in the us-east-1 Region: Allowed. The policy grants describe access to all RDS resources (rds:Describe*). B. Amazon S3 PutObject operation in a bucket named testbucket: Not Allowed. There's no mention of S3 permissions in the policy, and there's a deny statement for s3:GetObject. PutObject likely isn't allowed either. C. Amazon EC2 DescribeInstances action in the us-east-1 Region: Allowed. The policy allows all EC2 actions (ec2:* ) in the us-east-1 region due to the condition. D. Amazon EC2 AttachNetworkInterface action in the eu-west-1 Region: Not Allowed. The policy allows EC2 actions only in the us-east-1 region (ec2:* with condition). Actions in any other region (eu-west-1 here) are not allowed due to the deny statement for ec2:* Therefore, the allowed actions for the IAM user are: A. Amazon RDS DescribeDBInstances action in the us-east-1 Region C. Amazon EC2 DescribeInstances action in the us-east-1 Region
upvoted 3 times
...
klayytech
1 year, 1 month ago
Selected Answer: A
A. Amazon RDS DescribeDBInstances action in the us-east-1 Region: Allowed. The policy grants describe access to all RDS resources (rds:Describe*). B. Amazon S3 PutObject operation in a bucket named testbucket: Not Allowed. There's no mention of S3 permissions in the policy, and there's a deny statement for s3:GetObject. PutObject likely isn't allowed either. C. Amazon EC2 DescribeInstances action in the us-east-1 Region: Allowed. The policy allows all EC2 actions (ec2:* ) in the us-east-1 region due to the condition. D. Amazon EC2 AttachNetworkInterface action in the eu-west-1 Region: Not Allowed. The policy allows EC2 actions only in the us-east-1 region (ec2:* with condition). Actions in any other region (eu-west-1 here) are not allowed due to the deny statement for ec2:* Therefore, the allowed actions for the IAM user are: A. Amazon RDS DescribeDBInstances action in the us-east-1 Region C. Amazon EC2 DescribeInstances action in the us-east-1 Region
upvoted 2 times
...
klayytech
1 year, 1 month ago
A. Amazon RDS DescribeDBInstances action in the us-east-1 Region: Allowed. The policy grants describe access to all RDS resources (rds:Describe*). B. Amazon S3 PutObject operation in a bucket named testbucket: Not Allowed. There's no mention of S3 permissions in the policy, and there's a deny statement for s3:GetObject. PutObject likely isn't allowed either. C. Amazon EC2 DescribeInstances action in the us-east-1 Region: Allowed. The policy allows all EC2 actions (ec2:* ) in the us-east-1 region due to the condition. D. Amazon EC2 AttachNetworkInterface action in the eu-west-1 Region: Not Allowed. The policy allows EC2 actions only in the us-east-1 region (ec2:* with condition). Actions in any other region (eu-west-1 here) are not allowed due to the deny statement for ec2:* Therefore, the allowed actions for the IAM user are: A. Amazon RDS DescribeDBInstances action in the us-east-1 Region C. Amazon EC2 DescribeInstances action in the us-east-1 Region
upvoted 1 times
...
nightmerv
1 year, 1 month ago
Selected Answer: C
I will vote A and C because both statements are right. However, the question allows only one choice. so I will go with C.
upvoted 3 times
tgv
1 year ago
Cannot be C since "ec2" is specifically denied below. Always a deny has priority over an allow statement. The correct answer here is A. The only action that remains allowed is "rds".
upvoted 1 times
tgv
1 year ago
Actually I've made some research and it seems like the "NotAction" statement in the Deny block works like an "except" logic. It allows all actions except those specified in the NotAction list. So, it's like saying "deny everything except these actions." In the end, according to the presented policy, both A and C would be allowed.
upvoted 1 times
tgv
1 year ago
After some more consideration I think that if I had to choose between A and C, i would go with C because while the policy explicitly allows the rds:Describe* action, it doesn't restrict it to any particular region (like the answer A suggests). Final answer: 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