mediumMultiple ChoiceObjective-mapped
CCSP Practice Question: A cloud security analyst is troubleshooting an…
Exhibit
Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Deny",
"Principal": "*",
"Action": "s3:*",
"Resource": "arn:aws:s3:::example-bucket/*",
"Condition": {
"StringNotEquals": {
"aws:PrincipalArn": "arn:aws:iam::123456789012:role/DataAccessRole"
}
}
},
{
"Effect": "Allow",
"Principal": "arn:aws:iam::123456789012:role/DataAccessRole",
"Action": "s3:*",
"Resource": "arn:aws:s3:::example-bucket/*"
}
]
}A cloud security analyst is troubleshooting an access denied error when an application attempts to read an object from an S3 bucket. The application uses an IAM user that is not associated with the role specified in the policy. Which of the following is the most likely cause of the error?
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
The IAM user is not the specified role and is explicitly denied by the Deny statement.
The bucket policy likely includes a Deny statement that explicitly denies all principals except the specified role. Since the IAM user is not that role, the Deny overrides any Allow and blocks access. Option A is incorrect because even if the user were to assume the role, it would then be the role and gain access; however, the issue is that the user is not assuming the role. Option C is incorrect because a conflicting Allow and Deny would result in an explicit Deny, not an implicit deny—the Deny always overrides. Option D is incorrect because region restriction is not mentioned as a factor in the access denied error.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
The IAM user is not assuming the role before accessing the bucket.
Why it's wrong here
The policy does not require the user to assume the role; it simply denies access to any principal that is not that role. The user could still access if they were the role, but they are not.
- ✓
The IAM user is not the specified role and is explicitly denied by the Deny statement.
Why this is correct
The Deny statement explicitly denies all principals that are not the specified role, so any other principal (including this IAM user) is denied access.
- ✗
The bucket policy has a conflicting Allow and Deny statement, causing an implicit deny.
Why it's wrong here
There is no conflict; the Deny is conditional and explicit. If the condition is met (i.e., the principal is not the role), Deny applies. The Allow only applies to the role, so no conflict.
- ✗
The bucket policy is missing a condition for region restriction.
Why it's wrong here
Region restriction is not relevant; the policy already explicitly denies all except the specified role.
Quick reference
AWS S3 Storage Class Comparison
| Storage Class | Min Duration | Retrieval | Use Case |
|---|---|---|---|
| S3 Standard | None | Immediate | Frequently accessed data |
| S3 Standard-IA | 30 days | Immediate | Infrequent access, rapid retrieval |
| S3 One Zone-IA | 30 days | Immediate | Non-critical infrequent data |
| S3 Intelligent-Tiering | None | Immediate–hours | Unknown or changing access patterns |
| S3 Glacier Instant | 90 days | Milliseconds | Archive with instant retrieval |
| S3 Glacier Flexible | 90 days | Minutes–hours | Archive, flexible retrieval |
| S3 Glacier Deep Archive | 180 days | Hours | Long-term compliance archive |
Go deeper
Related to this question
About these practice questions
One of 964 original CCSP practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This CCSP practice question is part of Courseiva's free ISC2 certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the CCSP exam.