Clickjacking (User Interface redress attack, UI redress attack, UI redressing) is a malicious technique of tricking a Web user into clicking on something different from what the user perceives they are clicking on, thus potentially revealing confidential information or taking control of their computer while clicking on seemingly innocuous web pages. It is a browser security issue that is a vulnerability across a variety of browsers and platforms. A clickjack takes the form of embedded code or a script that can execute without the user's knowledge, such as clicking on a button that appears to perform another function. The term "clickjacking" was coined by Jeremiah Grossman and Robert Hansen in 2008. Clickjacking can be understood as an instance of the confused deputy problem.
Clickjacking is possible because seemingly harmless features of HTML web pages can be employed to perform unexpected actions.
A clickjacked page tricks a user into performing undesired actions by clicking on a concealed link. On a clickjacked page, the attackers load another page over it in a transparent layer. The users think that they are clicking visible buttons, while they are actually performing actions on the hidden page. The hidden page may be an authentic page; therefore, the attackers can trick users into performing actions which the users never intended. There is no way of tracing such actions to the attackers later, as the users would have been genuinely authenticated on the hidden page.
A user might receive an email with a link to a video about a news item, but another valid page, say a product page on amazon.com, can be "hidden" on top or underneath the "PLAY" button of the news video. The user tries to "play" the video but actually "buys" the product from Amazon.
Other known exploits include:
- tricking users into enabling their webcam and microphone through Flash (which has since been corrected by Adobe);
- tricking users into making their social networking profile information public;
- making users follow someone on Twitter;
- sharing links on Facebook
Likejacking is a malicious technique of tricking users of a website into posting a Facebook status update for a site they did not intentionally mean to "like". The term "likejacking" came from a comment posted by Corey Ballou in the article How to "Like" Anything on the Web (Safely), which is one of the first documented postings explaining the possibility of malicious activity regarding Facebook's "like" button.
According to an article in IEEE Spectrum, a solution to likejacking was developed at one of Facebook's hackathons. A "Like" bookmarklet is available that avoids the possibility of likejacking present in the Facebook Like Button.
Cursorjacking is a UI redressing technique to change the cursor from the location the user perceives, discovered in 2010 by Eddy Bordi, researcher at Vulnerability.fr, Marcus Niemietz demonstrated this with a custom cursor icon, and in 2012 Mario Heiderich by hiding the cursor.
Protection against clickjacking (including likejacking) can be added to Mozilla Firefox desktop and mobile versions by installing the NoScript add-on: its ClearClick feature, released on 8 October 2008, prevents users from clicking on invisible or "redressed" page elements of embedded documents or applets. According to Google's "Browser Security Handbook", NoScript's ClearClick is "the only freely available product that offers a reasonable degree of protection" against Clickjacking. Protection from the newer cursorjacking attack was added to NoScript 2.2.8 RC1.
GuardedID (a commercial product) includes client-side clickjack protection for users of Internet Explorer and Firefox without interfering with the operation of legitimate iFrames. GuardedID clickjack protection forces all frames to become visible.
Gazelle is a Microsoft Research project secure web browser based on IE, that uses an OS-like security model, and has its own limited defenses against clickjacking. In Gazelle, a window of different origin may only draw dynamic content over another window's screen space if the content it draws is opaque.
Server and client 
On 26 January 2009 Microsoft released RC1 of Internet Explorer 8, which includes a new partial clickjacking prevention option. Web site developers will be able to add a page header to help detect and prevent frame-based UI redressing. IE 8, according to Microsoft, “will detect sites that insert the tag and give users a new error screen indicating that the content host has chosen not to allow their content to be framed, while giving users the option to open the content in a new window.” 
Microsoft's suggested solution, which has since also been implemented in the Safari, Firefox, Chrome, and Opera Web browsers, is to check for a new HTTP header, X-Frame-Options. This header can take the values DENY, SAMEORIGIN, or ALLOW-FROM origin, which will prevent any framing, prevent framing by external sites, or allow framing only by the specified site, respectively. In addition to that, some advertising sites return a non-standard ALLOWALL value with the intention to allow framing their content on any page (equivalent of not setting X-Frame-Options at all).
Content Security Policy is proposed standard countermeasure against clickjacking and other similar attacks.
See also 
- Browser security
- Internet security
- Internet safety
- Hacker (computer security)
- Cross-site scripting
- Robert McMillan (2008-09-17). "At Adobe's request, hackers nix 'clickjacking' talk". PC World. Retrieved 2008-10-08.
- Megha Dhawan (2008-09-29). "Beware, clickjackers on the prowl". India Times. Retrieved 2008-10-08.
- Dan Goodin (2008-10-07). "Net game turns PC into undercover surveillance zombie". The Register. Retrieved 2008-10-08.
- Fredrick Lane (2008-10-08). "Web Surfers Face Dangerous New Threat: 'Clickjacking'". newsfactor.com. Retrieved 2008-10-08.[dead link]
- Sumner Lemon (2008-09-30). "Business Center: Clickjacking Vulnerability to Be Revealed Next Month". Retrieved 2008-10-08.
- The Confused Deputy rides again!, Tyler Close, October 2008
- Daniel Sandler (2009-02-12). "Twitter's "Don't Click" prank, explained (dsandler.org)". Retrieved 2009-12-28.
- Krzysztof Kotowicz (2009-12-21). "New Facebook clickjacking attack in the wild". Retrieved 2009-12-29.
- BBC (2010-06-03). "Facebook "clickjacking" spreads across site". BBC News. Retrieved 2010-06-03.
- Cohen, Richard (2010-05-31). "Facebook Work - "Likejacking"". Sophos. Retrieved 2010-06-05.
- Ballou, Corey (06/02/2010). ""Likejacking" Term Catches On". jqueryin.com. Retrieved 2010-06-08.
- Perez, Sarah (06/02/2010). ""Likejacking" Takes Off on Facebook". readwriteweb.com. Retrieved 2010-06-05.
- Kushner, David (June 2011). "Facebook Philosophy: Move Fast and Break Things". spectrum.ieee.org. Retrieved 2011-07-15.
- Perez, Sarah (23 April 2010). "How to "Like" Anything on the Web (Safely)". ReadWriteWeb. Retrieved 24 August 2011.
- Krzysztof Kotowicz (2012-01-18). "Cursorjacking Again". Retrieved 2012-01-31.
- Aspect Security. "Cursor-jacking attack could result in application security breaches". Retrieved 2012-01-31.
- Giorgio Maone (2011-06-24). "NoScript Anywhere". hackademix.net. Retrieved 2011-06-30.
- Giorgio Maone (2008-10-08). "Hello ClearClick, Goodbye Clickjacking". hackademix.net. Retrieved 2008-10-27.
- Michal Zalevski (2008-12-10). "Browser Security Handbook, Part 2, UI Redressing". Google Inc. Retrieved 2008-10-27.
- Robert Hansen (2009-02-04). "Clickjacking and GuardedID ha.ckers.org web application security lab". Retrieved 2011-11-30.
- Wang, Helen J.; Grier, Chris; Moschchuk, Alexander; King, Samuel T.; Choudhury, Piali; Venter, Herman (August, 2009). "The Multi-Principal OS Construction of the Gazelle Web Browser". 18th Usenix Security Symposium, Montreal, Canada. Retrieved 2010-01-26.
- Giorgio Maone (2008-10-27). "Hey IE8, I Can Has Some Clickjacking Protection". hackademix.net. Retrieved 2008-10-27.
- Mary Jo Foley (2009-01-26). "Near-final IE 8 test build ready for download". Retrieved 2009-01-26.
- Eric Lawrence (2009-01-27). "IE8 Security Part VII: ClickJacking Defenses". Retrieved 2010-12-30.
- Eric Lawrence (2010-03-30). "Combating ClickJacking With X-Frame-Options". Retrieved 2010-12-30.
- Ryan Naraine (2009-06-08). "Apple Safari jumbo patch: 50+ vulnerabilities fixed". Retrieved 2009-06-10.
- https://developer.mozilla.org/en/The_X-FRAME-OPTIONS_response_header The X-Frame-Options response header — MDC
- Adam Barth (2010-01-26). "Security in Depth: New Security Features". Retrieved 2010-01-26.
- "Web specifications support in Opera Presto 2.6". 2010-10-12. Retrieved 2012-01-22.
- "The mess with X-Frame-Options: ALLOWALL". IPSec.pl. Retrieved March 1, 2013.
- Original paper on clickjacking
- clickjacking links collected by Steve Gibson of GRC.com
- Waterken article on clickjacking and capability-based security
- OWASP clickjacking
- Example of Facebook ClickJacking
- UI Redressing: Attacks and Countermeasures Revisited
- New Insights into Clickjacking @ Owasp AppSec Research 2010
- Clickjacking attack on Flash Player,20 Oct 2011
- Cursorjacking Demo page Original custom cursor method
- A good example of cursorjacking? Hidden cursor method