Post Thu Apr 11, 2013 4:18 pm

HTB23149: Multiple XSS in Hero Framework

Advisory ID: HTB23149
Product: Hero Framework
Vendor: heroframework.com
Vulnerable Versions: 3.791 and probably prior
Tested Version: 3.791
Vendor Notification: March 20, 2013
Vendor Fix: March 29, 2013
Public Disclosure: April 10, 2013
Vulnerability Type: Cross-Site Scripting [CWE-79]
CVE Reference: CVE-2013-2649
Risk Level: Medium
CVSSv2 Base Score: 4.3 (AV:N/AC:M/Au:N/C:N/I:P/A:N)
Solution Status: Fixed by Vendor
Discovered and Provided: High-Tech Bridge Security Research Lab

Advisory Details:
High-Tech Bridge Security Research Lab discovered two XSS vulnerabilities in Hero Framework, which can be exploited to perform cross-site scripting attacks against vulnerable application.

1) Multiple XSS in Hero Framework: CVE-2013-2649
1.1 The vulnerability exists due to insufficient sanitisation of user-supplied data in "username" HTTP GET parameter passed to "/users/login" URL. A remote attacker can trick a logged-in user to open a specially crafted link and execute arbitrary HTML and script code in victim's browser in context of the vulnerable website.
The exploitation example below uses JavaScript 'alert()' function to display user's cookies:
  Code:
http://[host]/users/login?username=%22%3E%3Cscript%3Ealert%28document.cookie%29;%3C/script%3E


1.2 The vulnerability exists due to insufficient sanitisation of user-supplied data in "error" HTTP GET parameter passed to "/users/forgot_password" URL. The parameter is passed to the vulnerable script in base64 encoding. A remote attacker can trick a logged-in user to open a specially crafted link and execute arbitrary HTML and script code in victoms's browser in context of the vulnerable website.
The exploitation example below uses the same XSS payload as above encoded in base64 to display user's cookies:
  Code:
http://[host]/users/forgot_password?error=PHNjcmlwdD5hbGVydChkb2N1bWVudC5jb29raWUpOzwvc2NyaXB0Pg==


Solution:
Upgrade to Hero Framework version 3.80
More Information:
http://www.heroframework.com/download

References:
[1] High-Tech Bridge Advisory HTB23149 - https://www.htbridge.com/advisory/HTB23149 - Multiple XSS in Hero Framework.
[2] Hero Framework - heroframework.com - Hero is a white label, open source PHP website content management system (CMS) and development platform.
[3] Common Vulnerabilities and Exposures (CVE) - cve.mitre.org - international in scope and free for public use, CVE® is a dictionary of publicly known information security vulnerabilities and exposures.
[4] Common Weakness Enumeration (CWE) - cwe.mitre.org - targeted to developers and security practitioners, CWE is a formal list of software weakness types.