Security Vulnerabilities Guide

Understanding and fixing common web security vulnerabilities detected by VitaPulse

Medium
X-Frame-Options

Controls whether your site can be embedded in iframes, protecting against clickjacking attacks.

Risk

Without this header, an attacker can embed your site in a transparent iframe on their malicious page. They overlay fake buttons on top of your site's real buttons. When users think they are clicking on the attacker's page, they are actually performing actions on your site (liking, purchasing, changing settings). This is called clickjacking.

Solution

Set X-Frame-Options to DENY (if your site doesn't need to be framed) or SAMEORIGIN (if you need self-framing). For more granular control, use the frame-ancestors directive in CSP.

Example
X-Frame-Options: DENY
Comments (0)

No messages yet.