OpenEMR before 8.3.0 contains a stored cross-site scripting vulnerability in the patient portal template import handler that allows authenticated… (CVE-2026-40508)
OpenEMR versions before 8.3.0 contain a stored cross-site scripting (XSS) vulnerability in the patient portal template import handler. Authenticated users with Forms Administration permissions can upload template files containing arbitrary HTML or JavaScript. These malicious scripts are stored without proper sanitization and execute in the browsers of other Forms Administration users who view the template in the HTML editor. This vulnerability has a medium severity rating with a CVSS score of 5.4.
AI Analysis
Technical Summary
The vulnerability (CVE-2026-40508) in OpenEMR prior to version 8.3.0 is a stored cross-site scripting flaw located in the patient portal template import handler. Authenticated attackers possessing Forms Administration permissions can upload templates embedding arbitrary HTML or JavaScript code. Because the uploaded content is not sanitized, the malicious scripts persist and execute in the context of any other Forms Administration user who opens the template in the HTML editor, potentially leading to session hijacking or other script-based attacks. The CVSS 3.1 vector indicates network attack vector, low attack complexity, requiring privileges and user interaction, with partial impact on confidentiality and integrity but no impact on availability.
Potential Impact
Successful exploitation allows an authenticated user with Forms Administration permissions to inject malicious scripts that execute in the browsers of other privileged users. This can lead to partial confidentiality and integrity compromise within the affected OpenEMR environment. There is no indication of availability impact or known active exploitation in the wild.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix is available, restrict Forms Administration permissions to trusted users only and avoid opening untrusted templates in the HTML editor. Monitor vendor channels for updates regarding patches or official mitigations.
OpenEMR before 8.3.0 contains a stored cross-site scripting vulnerability in the patient portal template import handler that allows authenticated… (CVE-2026-40508)
Description
OpenEMR versions before 8.3.0 contain a stored cross-site scripting (XSS) vulnerability in the patient portal template import handler. Authenticated users with Forms Administration permissions can upload template files containing arbitrary HTML or JavaScript. These malicious scripts are stored without proper sanitization and execute in the browsers of other Forms Administration users who view the template in the HTML editor. This vulnerability has a medium severity rating with a CVSS score of 5.4.
CVSS v3.1
Score 5.4medium
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability (CVE-2026-40508) in OpenEMR prior to version 8.3.0 is a stored cross-site scripting flaw located in the patient portal template import handler. Authenticated attackers possessing Forms Administration permissions can upload templates embedding arbitrary HTML or JavaScript code. Because the uploaded content is not sanitized, the malicious scripts persist and execute in the context of any other Forms Administration user who opens the template in the HTML editor, potentially leading to session hijacking or other script-based attacks. The CVSS 3.1 vector indicates network attack vector, low attack complexity, requiring privileges and user interaction, with partial impact on confidentiality and integrity but no impact on availability.
Potential Impact
Successful exploitation allows an authenticated user with Forms Administration permissions to inject malicious scripts that execute in the browsers of other privileged users. This can lead to partial confidentiality and integrity compromise within the affected OpenEMR environment. There is no indication of availability impact or known active exploitation in the wild.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix is available, restrict Forms Administration permissions to trusted users only and avoid opening untrusted templates in the HTML editor. Monitor vendor channels for updates regarding patches or official mitigations.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-xvw4-236w-442q
- Osv Schema Version
- 1.4.0
- Aliases
- ["CVE-2026-40508"]
- Ecosystems
- []
- Database Specific Severity
- MODERATE
- Cvss Version
- 3.1
Threat ID: 6a85ee14acd9273b4969a270
Added to database: 08/19/2026, 17:55:32 UTC
Last enriched: 08/19/2026, 18:25:32 UTC
Last updated: 08/19/2026, 19:58:12 UTC
Views: 3
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.