CVE-2011-0003: clickjacking vulnerability in mediawiki <1.16.1
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MediaWiki |
Fix Released
|
High
|
|||
mediawiki (Debian) |
Fix Released
|
Undecided
|
Unassigned | ||
mediawiki (Fedora) |
Fix Released
|
Medium
|
|||
mediawiki (Ubuntu) |
Invalid
|
Medium
|
Unassigned | ||
Hardy |
Invalid
|
Undecided
|
Unassigned | ||
Karmic |
Invalid
|
Medium
|
Unassigned | ||
Lucid |
Invalid
|
Medium
|
Unassigned | ||
Maverick |
Invalid
|
Medium
|
Unassigned | ||
Natty |
Invalid
|
Medium
|
Unassigned |
Bug Description
Binary package hint: mediawiki
A clickjacking vulnerability was reported in MediaWiki [1]. This could allow a
malicious web site to compromise the account of the user visiting a
MediaWiki-based web site (an attack similar to cross-site scripting). For full
protection, a user needs to be using a browser that supports the
X-Frame-Options feature [2].
MediaWiki 1.16.1 [3] has been released to correct this flaw. For MediaWiki
1.15.x and earlier, a patch [4] is available which denies all framing.
[1] https:/
[2] https:/
[3]
http://
[4] http://
CVE References
Changed in mediawiki (Debian): | |
status: | New → In Progress |
Changed in mediawiki (Debian): | |
status: | In Progress → Fix Released |
Changed in mediawiki (Ubuntu): | |
status: | New → In Progress |
Changed in mediawiki: | |
importance: | Undecided → Unknown |
status: | New → Unknown |
Changed in mediawiki (Ubuntu Lucid): | |
status: | Incomplete → Fix Released |
Changed in mediawiki (Ubuntu Natty): | |
status: | Incomplete → Fix Released |
Changed in mediawiki (Ubuntu Lucid): | |
status: | Fix Released → Incomplete |
Changed in mediawiki (Ubuntu Karmic): | |
status: | Incomplete → Won't Fix |
Changed in mediawiki (Ubuntu Hardy): | |
status: | Incomplete → Won't Fix |
Changed in mediawiki (Ubuntu): | |
status: | Incomplete → Fix Released |
Changed in mediawiki: | |
importance: | Unknown → High |
status: | Unknown → Fix Released |
Changed in mediawiki (Fedora): | |
importance: | Unknown → Medium |
status: | Invalid → Fix Released |
Clickjacking is a type of vulnerability discovered in 2008, which is similar to CSRF.
The attack involves displaying the target webpage in a iframe embedded in a malicious website. Using CSS, the submit button of the form on the target webpage is made invisible, and then overlaid with some button or link on the malicious website that encourages the user to click on it. For more information, see:
http:// en.wikipedia. org/wiki/ Clickjacking www.owasp. org/index. php/Clickjackin g
http://
Web browsers have standardised on a defence called X-Frame-Options, which puts the onus on the web application to prevent framing of sensitive content.
Wikipedia user PleaseStand brought it to our attention that despite the passage of more than two years, MediaWiki still had no defence against clickjacking. PleaseStand pointed out that when user or site JavaScript or CSS is enabled ($wgAllowUserJs, $wgAllowUserCss, $wgUseSiteJs or $wgUseSiteCss), clickjacking is essentially equivalent to cross-site scripting (XSS), that is to say, it allows full compromise of the account of the user visiting the malicious website.
A fix will be shortly released, in MediaWiki 1.16.1. Our approach is to allow framing of basic page views and search pages, but to deny framing of special pages unless they have explicitly opted out of clickjacking protection. By taking this moderate approach, instead of denying all framing, we hope to avoid having system administrators disable the security feature by patching it out.
Security-conscious system administrators may wish to disable framing entirely using $wgBreakFrames = true. In MediaWiki 1.16.1 or later, this will provide protection against clickjacking vulnerabilities in extensions which opt out incorrectly or embed sensitive forms on pages which are opted out.
Alternatively, you can configure your web server to send an X-Frame-Options header on all pages. For example with Apache mod_headers:
Header always set X-Frame-Options DENY
For MediaWiki 1.15.x or earlier branches, we will provide a simplified security patch which denies all framing.
Extensions which wish to allow framing on a given page should do so by calling $wgOut- >allowClickjack ing(). This should only be done on pages which do not contain CSRF-protected forms or links. Any extension which embeds a CSRF-protected form in an unprotected article view page should call $wgOut- >preventClickja cking() , after Article::view() has called $wgOut- >allowClickjack ing(), to reset the flag.
To be protected against clickjacking, all users need to use a browser which supports the X-Frame-Options header. Our patch does include standard frame-breaking JavaScript code, but this is known to be insufficient for most browsers. See the OWASP article for more details. For information on supported browsers, see:
<https:/ /developer. mozilla. org/en/ the_x-frame- options_ response_ header>