mediumMultiple ChoiceObjective-mapped
CAS-004 Practice Question: Based on the exhibit, what is the primary purpose…
Exhibit
Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::corporate-bucket/*",
"Condition": {
"IpAddress": {
"aws:SourceIp": [
"10.0.0.0/16",
"192.168.1.0/24"
]
}
}
}
]
}Based on the exhibit, what is the primary purpose of the condition in this IAM policy?
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
✓
Restrict access to requests originating from the specified IP ranges
The condition in the IAM policy uses the `aws:SourceIp` key to restrict access to requests originating from the specified IP ranges. Option A is incorrect because the condition does not address encryption in transit. Option B is incorrect because the policy does not allow all traffic; it allows only requests from the specified IPs. Option C is incorrect because the policy is an allow with a condition, not a deny statement. The condition effectively limits which IPs can perform the allowed actions, making D the primary purpose.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Enable encryption in transit for the S3 bucket
Why it's wrong here
Encryption requires additional policy.
- ✗
Allow all incoming traffic to the S3 bucket
Why it's wrong here
The condition restricts to specific IPs.
- ✗
Deny access from the specified IP ranges
Why it's wrong here
The Effect is Allow, not Deny.
- ✓
Restrict access to requests originating from the specified IP ranges
Why this is correct
The condition allows only requests from those IPs.
Go deeper
Related to this question
About these practice questions
One of 968 original CAS-005 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 CAS-005 practice question is part of Courseiva's free CompTIA 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 CAS-005 exam.