CEH Web Application and Injection Attacks Practice Question
A web application takes a URL from user input and fetches the content to display on the page. An attacker submits a URL pointing to an internal service like http://localhost:8080/admin. The server retrieves the internal resource and returns it. What is this attack?
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
✓
Server-Side Request Forgery (SSRF)
Server-Side Request Forgery (SSRF) occurs when a server makes requests to internal resources based on user-supplied URLs.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Cross-Site Scripting (XSS)
Why it's wrong here
Cross-Site Scripting (XSS) involves injecting malicious client-side scripts, typically JavaScript, into web pages viewed by other users. This attack primarily targets the end-user's browser to steal cookies, deface websites, or redirect users, rather than manipulating the server itself to initiate outbound network requests to internal or external resources. Therefore, it does not fit the scenario where the server is tricked into fetching a URL.
- ✓
Server-Side Request Forgery (SSRF)
Why this is correct
Server-Side Request Forgery (SSRF) occurs when a web application is coerced into making requests to an arbitrary domain specified by the attacker, often to internal systems or services that are not directly accessible from the internet. By manipulating a user-supplied URL parameter, an attacker can trick the vulnerable server into fetching data from internal network resources, cloud metadata APIs, or other services, thereby exposing sensitive information or enabling further attacks. This directly matches the scenario described.
- ✗
Directory Traversal
Why it's wrong here
Directory Traversal, also known as Path Traversal, allows an attacker to access files and directories stored outside the intended web root directory by manipulating file paths with sequences like "../". This vulnerability exploits flaws in file system access controls to read or write arbitrary files on the server's local file system, but it does not involve the server making outbound network requests based on a user-supplied URL. The mechanism of attack is fundamentally different.
- ✗
Remote File Inclusion (RFI)
Why it's wrong here
Remote File Inclusion (RFI) vulnerabilities allow an attacker to cause the server-side application to include a remote file, typically a script, and execute it within the server's context. While it involves fetching a remote resource, the primary goal and mechanism of RFI are to achieve code execution by including a malicious script, rather than merely forcing the server to make an arbitrary network request to an internal or external URL for reconnaissance or port scanning purposes, which is the hallmark of SSRF.
Go deeper
Related to this question
About these practice questions
One of 870 original CEH 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 CEH practice question is part of Courseiva's free EC-Council 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 CEH exam.