/

CVE-2026-124463

Severity:

HIGH RISK

(8.7)

Stored Cross-Site Scripting (CWE-79) in OpenEMR CAMOS

CVE-2026-124463

Analyzed

Vulnerability type

Category:

Stored Cross-Site Scripting

CWE:

CWE-79

Impact:

Attacker-controlled script execution in a victim's browser

Severity:

HIGH RISK

(8.7)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

OpenEMR contains a stored cross-site scripting vulnerability in CAMOS content handling. An authenticated user with CAMOS access may save malicious HTML that runs in a victim's browser when the entry is printed, potentially allowing actions or data access as that user.

Affected context

The issue affects OpenEMR versions before 8.3.0. It occurs when CAMOS content saved through ajax_save.php is later rendered by the non-print_html branch of rx_print.php without appropriate output encoding.

Exploit preconditions

  • Attack surface: CAMOS content creation and the printing flow in OpenEMR.
  • Required access: An authenticated account with CAMOS access to save content.
  • Trigger point: A victim views or prints the saved entry through the affected rendering path.
  • Why exploitation is possible: Saved HTML is output without encoding, allowing browser-interpreted script content to execute in the victim's context.

Why this happens

The application treats saved content as trusted HTML when rendering it for printing, rather than encoding it for the output context or restricting it to safe markup. This is a stored cross-site scripting flaw mapped to CWE-79: Improper Neutralization of Input During Web Page Generation.

Potential impact

  • A script could perform actions available to the victim within OpenEMR.
  • It could read information accessible to the victim through the application.
  • It may compromise the victim's session or expose sensitive data, depending on application controls and the victim's permissions.

General mitigation guidance

Defensive approaches generally focus on treating saved content as untrusted and safely handling it at every output point.

  • Encode content according to its HTML output context by default.
  • If formatted HTML is required, use a strict allowlist-based sanitizer and avoid unsafe rendering paths.
  • Reduce trust in user-submitted content, including content created by authenticated users.
  • Apply least privilege to user accounts and limit access to CAMOS features to those who need them.
  • Use consistent safe-rendering patterns across print and non-print views.

How teams detect issues like this

  • Review rendering code for saved or user-controlled content inserted into HTML without context-appropriate encoding.
  • Use static analysis to flag unsafe HTML output and bypasses of shared encoding or sanitization utilities.
  • Test CAMOS save-and-print workflows with security checks that verify untrusted markup is rendered inert.
  • Enforce code review and CI policies requiring safe output handling for user-controlled content.

Sources

SourceLink
github.comgithub.com/openemr/openemr/security/advisories/GHSA-rc6m-6pq4-r69x
vulncheck.comvulncheck.com/advisories/openemr-before-8.3.0-stored-xss-via-camos-rx-print-view

Frequently asked

questions

An authenticated user with CAMOS access can save content that may be rendered unsafely.

No. A victim generally needs to view or print the affected entry through the vulnerable rendering path, and the impact depends on that victim's access and permissions.

Treat saved content as untrusted and apply context-appropriate output encoding. If limited HTML is necessary, sanitize it with a strict allowlist before rendering.

Use safe-by-default rendering helpers, review all output paths for user-controlled data, and include automated checks and workflow tests for stored content.

Find out what's already
exploitable in your codebase.