AttackVector.tech

What is Clickjacking?

Clickjacking is a UI attack using invisible iframes to deceive users. Discover how it works, real examples, and defense strategies.

Explain Like I'm 5

Think about playing a game at a carnival where you throw a ball to hit a target and win a prize. But the game is rigged with an invisible shield in front of the target. You throw the ball, it hits the shield, and you don't win the prize. Clickjacking is like that trick. Hackers put invisible layers over buttons or links on a website. You think you're clicking something safe, but you're actually clicking something harmful, like signing into a fake page or sharing a post you didn't mean to. This matters because, just like losing the prize, clickjacking can make you lose personal info or spread false information online. Protecting against it is like making sure the games you play are fair and transparent.

Technical Definition

Definition

Clickjacking is a UI redressing attack where an attacker deceives a user into clicking on a seemingly safe webpage element that conceals a hidden malicious element. This often involves transparent iframes to execute actions without the user's knowledge.

How It Works

  1. 1An attacker creates a webpage with a transparent iframe.
  2. 2This iframe is placed over a legitimate button or link on a webpage.
  3. 3The user clicks the visible button, unknowingly activating the hidden iframe's function.

Key Characteristics

  • Involves transparent or opaque overlays.
  • Depends on user interaction.
  • Targets actions like clicks, keystrokes, or drag-and-drop.

Comparison

ConceptDescription
PhishingTricks users into providing personal data.
Cross-Site Scripting (XSS)Inserts malicious scripts into websites.
ClickjackingMisleads users into clicking concealed elements.

Real-World Example

CVE-2008-3834 describes a vulnerability where a webpage's content could be obscured and replaced with an attacker-controlled iframe, leading to unauthorized actions.

Detection & Prevention

  • Use the X-Frame-Options HTTP header to block framing.
  • Implement Content Security Policy (CSP) with the frame-ancestors directive.
  • Test with tools like Burp Suite's Clickbandit to simulate clickjacking.
  • Frame-busting JavaScript alone is often ineffective, as attackers can bypass it.

Common Misconceptions

  • Frame-busting scripts alone are enough: They can be bypassed by attackers.
  • Clickjacking is only about clicks: It can involve other interactions like typing or dragging.
  • It's only a concern for large sites: Any site with user interactions can be targeted.

Related Terms

Keywords

what is ClickjackingClickjacking explainedClickjacking detectionClickjacking preventionUI redressing attackinvisible iframes security

Ready to scan your site?

AttackVector uses AI agents to find vulnerabilities before attackers do. Start a free scan now.

Start Free Scan