Professional Cloud Security Engineer free question 2 / 10 · Domain 1: Configuring access
The denialCondition of an IAM deny rule cannot be evaluated. The principal and the permission match the rule, and the principal is not in the exceptions. What is the access decision?
- The result of the previous condition evaluation is reused to decide the access
- The permission is denied if a different deny rule at the same level also matches
- The deny rule applies, so the principal is denied the matching permission
- The deny rule is skipped, and the decision is made from the allow policies
Show the answer and explanation
Answer: C
Why this is correct
The IAM documentation on deny rules, in "Denial conditions", says that if the condition evaluates to true or cannot be evaluated, the deny rule applies and the principals are unable to use the specified permissions. The rule is not applied when the condition evaluates to false. The design fails toward denial, so an error in a condition does not become a way around the deny.
Why the other options are wrong
"The result of the previous condition evaluation is reused to decide the access" … There is no rule that reuses an earlier condition evaluation for a principal. The documented behavior depends on how the condition evaluates this time.
"The deny rule is skipped, and the decision is made from the allow policies" … A deny condition is not handled like an allow condition. An unevaluable condition does not make IAM ignore the deny rule.
"The permission is denied if a different deny rule at the same level also matches" … The existence of another rule is not needed. This rule produces the denial on its own, because an unevaluable condition counts as a match.
Key point
When you change a tag condition, test the normal values and also the cases where a value is missing or cannot be evaluated. The same condition expression means something different in an allow policy and in a deny policy.