OpenEMR Reflected Cross-Site Scripting Vulnerability in ajax_download.php

Vulnerability

A reflected cross-site scripting vulnerability has been identified in OpenEMR versions prior to 8.0.0.3. The issue arises in the 'custom/ajax_download.php' file, where the 'reportID' parameter is processed and echoed without proper sanitization. This flaw allows authenticated attackers to inject arbitrary JavaScript that is executed in the context of the victim's browser session.

Impact

Exploitation of this vulnerability allows for reflected cross-site scripting, where an attacker can execute arbitrary JavaScript in the victim's browser session.

Reproduction

To reproduce this vulnerability, an authenticated user can send a POST request to the 'ajax_download.php' endpoint with a crafted 'reportID' parameter. The injected JavaScript will be executed in the browser of the user who receives the crafted form submission.

Remediation

Users can upgrade to OpenEMR version 8.0.0.3 or later to address this vulnerability.

Added: Mar 25, 2026, 11:21 PM
Updated: Mar 25, 2026, 11:21 PM

Vulnerability Rating

Custom Algorithm
spread
4.5
impact
1.7
exploitability
5.5
remediation
7.7
relevance
4.7
threat
4.8
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.