SY0-701 Threats, Vulnerabilities, and Mitigations Practice Question
A cloud-hosted API lets users supply a URL for the service to fetch an image. Shortly after release, logs show requests to 169.254.169.254 and internal admin addresses. What control best reduces this risk?
⚠ Common exam trap
Watch out — candidates often confuse data-at-rest protection (encryption) with access control, or mistakenly think allowing redirects improves functionality without realizing it exacerbates SSRF; The SY0-701 exam often tests the specific cloud metadata endpoint (169.254.169.254) as a classic SSRF indicator.
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 outbound requests to an allowlist and block internal address ranges.
Restricting outbound requests to an allowlist and blocking internal address ranges directly mitigates the Server-Side Request Forgery (SSRF) vulnerability. The requests to 169.254.169.254 (the AWS/GCP/Azure metadata endpoint) and internal admin addresses indicate an attacker is using the API to probe internal services. An allowlist ensures the API only connects to trusted external hosts, while blocking private and link-local ranges prevents access to internal infrastructure.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Allow the API to follow any redirect so it works with more image sources.
Why it's wrong here
Allowing the API to follow any redirect would expand the attack surface by enabling Server-Side Request Forgery (SSRF) exploitation, as attackers could chain redirects to reach the link-local metadata endpoint 169.254.169.254 or internal admin addresses. This option is tempting because redirect following is a legitimate feature for fetching images from services that use temporary URLs, but in this scenario it directly facilitates the SSRF vector rather than mitigating it.
- ✓
Restrict outbound requests to an allowlist and block internal address ranges.
Why this is correct
This is a classic server-side request forgery pattern: the server is making attacker-influenced requests to internal or metadata addresses. An allowlist of approved destinations, combined with blocking private and link-local ranges, prevents the service from being used as a proxy into internal systems. That control directly targets the unsafe outbound request behavior and is more effective than trying to clean malicious URLs after the fact. It also reduces exposure to cloud metadata theft and internal service probing.
- ✗
Store the fetched image in encrypted form before sending it to users.
Why it's wrong here
Encrypting the fetched image protects data at rest but does nothing to prevent the server from making the attacker-controlled outbound request in the first place. The SSRF vulnerability occurs during the fetch, before any encryption is applied, and an attacker can still direct the server to internal endpoints like 169.254.169.254 or intranet admin panels. Encryption is a confidentiality control for stored data, not an access control for outbound connections, so it fails to address the root cause.
- ✗
Increase the session timeout to reduce repeated logins by legitimate users.
Why it's wrong here
Session timeout controls only affect how long an authenticated session remains valid; they have no impact on the server-side URL fetching behavior that enables SSRF. An attacker supplying a malicious URL can trigger the request regardless of whether the user is logged in or how long their session lasts. Increasing the timeout might even widen the window for session hijacking, but more importantly, it is entirely orthogonal to the need to restrict outbound destinations.
Go deeper
Related to this question
Learn chapter
Vulnerability Scanning and Assessment
Key term
Vulnerability
A vulnerability is a weakness in a system, network, or software that could be exploited by a threat to cause harm or unauthorized access.
Key term
Risk
Risk is the possibility that an event or action will negatively affect an organization's ability to achieve its goals, often measured in terms of likelihood and impact.
About these practice questions
This SY0-701 question is part of Courseiva's 1,013-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This SY0-701 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 SY0-701 exam.