PT0-001 · Question #91
A penetration tester notices that the X-Frame-Optjons header on a web application is not set. Which of the following would a malicious actor do to exploit this configuration setting?
The correct answer is B. Create a frame that overlays the application. A missing X-Frame-Options header leaves a web application vulnerable to clickjacking, where an attacker embeds the legitimate site in a transparent frame to trick users into unintended actions.
Question
A penetration tester notices that the X-Frame-Optjons header on a web application is not set. Which of the following would a malicious actor do to exploit this configuration setting?
Options
- AUse path modification to escape the application's framework.
- BCreate a frame that overlays the application.
- CInject a malicious iframe containing JavaScript.
- DPass an iframe attribute that is malicious.
How the community answered
(40 responses)- A5% (2)
- B83% (33)
- C3% (1)
- D10% (4)
Why each option
A missing X-Frame-Options header leaves a web application vulnerable to clickjacking, where an attacker embeds the legitimate site in a transparent frame to trick users into unintended actions.
Path modification to escape an application framework describes a path traversal or framework-escape vulnerability class that is entirely unrelated to the X-Frame-Options header.
The X-Frame-Options header instructs browsers to prevent the page from being embedded in a frame by another origin. Without it, an attacker can load the target application inside an iframe on a malicious page, overlay deceptive UI elements on top, and manipulate users into performing actions - such as clicking buttons or submitting forms - without their knowledge.
Injecting a malicious iframe containing JavaScript describes a cross-site scripting vector and is not the direct exploitation of a missing X-Frame-Options header, which specifically enables clickjacking.
Passing a malicious iframe attribute relates to HTML attribute injection, not the clickjacking risk that arises specifically from an absent X-Frame-Options header.
Concept tested: Clickjacking exploitation via missing X-Frame-Options header
Source: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options
Topics
Community Discussion
No community discussion yet for this question.