Join the Cyber Forum: Threat Intel on May 12, 2026 to learn how AI is reshaping threat defense.Join the Virtual Cyber Forum: Threat IntelRegister Now
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2025-67491

CVE-2025-67491: OpenEMR Stored XSS Vulnerability

CVE-2025-67491 is a stored XSS vulnerability in OpenEMR's billing interface that allows low-privileged users to inject malicious scripts and steal session cookies. This post covers the technical details, affected versions, and patches.

Published: February 27, 2026

CVE-2025-67491 Overview

CVE-2025-67491 is a stored cross-site scripting (XSS) vulnerability affecting OpenEMR, a widely-used free and open source electronic health records (EHR) and medical practice management application. The vulnerability exists in the ub04 helper component of the billing interface, where the $data variable is passed in a click event handler enclosed in single quotes without proper sanitization.

Despite the use of json_encode, attackers with low privileges can inject malicious JavaScript payloads that persist on the server. This stored XSS attack enables malicious users to steal session cookies and perform unauthorized actions while impersonating administrators, posing significant risks to healthcare data confidentiality and system integrity.

Critical Impact

Low-privileged users can embed persistent malicious JavaScript payloads in the billing interface to steal administrator session cookies and perform unauthorized actions, potentially compromising sensitive patient health records and medical practice data.

Affected Products

  • OpenEMR versions 5.0.0.5 through 7.0.3.4
  • OpenEMR billing interface ub04 helper component
  • Healthcare organizations using vulnerable OpenEMR deployments

Discovery Timeline

  • 2026-02-25 - CVE-2025-67491 published to NVD
  • 2026-02-25 - Last updated in NVD database

Technical Details for CVE-2025-67491

Vulnerability Analysis

This stored XSS vulnerability stems from insufficient input sanitization in the ub04_helpers.php file within OpenEMR's billing interface. The vulnerable code passes user-controlled data through a click event handler where it is enclosed in single quotes. While the application employs json_encode as a defensive measure, this encoding is insufficient to prevent XSS attacks when the output context is an HTML attribute within single quotes.

An attacker with low-privilege access to the billing system can craft a payload that breaks out of the single-quote context and injects arbitrary HTML and JavaScript. The malicious payload persists in the database and executes whenever other users—including administrators—view the affected billing records. This persistence makes the attack particularly dangerous in healthcare environments where billing data is frequently accessed by multiple staff members with varying privilege levels.

Root Cause

The root cause is improper output encoding in the interface/billing/ub04_helpers.php file. The $data variable is inserted into an HTML onclick attribute without context-appropriate escaping. While json_encode provides some protection against JavaScript string escaping, it does not properly handle HTML attribute context escaping, allowing attackers to break out of the attribute value and inject malicious content.

Attack Vector

The attack is network-accessible and requires low privileges (authenticated user with access to billing functions). User interaction is required as a victim must view the page containing the malicious payload. An attacker can inject a payload such as ac' ><img src=x onerror=alert(document.cookie)> into billing form fields. When another user views the affected record, the malicious JavaScript executes in their browser context, potentially stealing session tokens or performing actions with the victim's privileges.

php
// Security patch in interface/billing/ub04_form.php - Merge commit from fork (#9698)
         var ii = i+1;
         if(typeof(ub04id[ii]) != 'undefined' && ub04id[ii] !== ""){
             var val = ub04id[ii];
-            if( val.length > max && max > 0 ){
+            if(val != null && val.length > max && max > 0 ){
                 val = ub04id[ii].substring(0,max);
             }
             document.getElementById("ub04id"+ ii.toString()).value = val;

Source: GitHub Commit Log

Detection Methods for CVE-2025-67491

Indicators of Compromise

  • Unusual JavaScript code patterns in billing records containing <script>, onerror=, onclick=, or similar event handlers
  • Session cookie exfiltration attempts in network logs targeting external domains
  • Billing record entries containing HTML tags such as <img>, <iframe>, or <svg> with event attributes
  • Unexpected administrator actions performed during times when legitimate admins were not active

Detection Strategies

  • Implement Web Application Firewall (WAF) rules to detect XSS payload patterns in billing form submissions
  • Enable Content Security Policy (CSP) headers to prevent inline script execution and report violations
  • Deploy endpoint detection solutions to monitor for suspicious browser behavior and credential theft attempts
  • Review application logs for billing interface access patterns that suggest reconnaissance or exploitation

Monitoring Recommendations

  • Monitor OpenEMR audit logs for unusual billing record modifications or access patterns
  • Configure alerts for CSP violation reports indicating attempted XSS execution
  • Track session anomalies such as session tokens used from unexpected IP addresses or user agents
  • Implement database query logging to detect injection of HTML/JavaScript content in billing fields

How to Mitigate CVE-2025-67491

Immediate Actions Required

  • Upgrade OpenEMR to version 7.0.4 or later immediately to receive the security patch
  • Audit existing billing records in the database for signs of injected malicious content
  • Force session invalidation and password resets for all users, especially administrators, if compromise is suspected
  • Implement Content Security Policy headers to provide defense-in-depth against XSS attacks

Patch Information

OpenEMR version 7.0.4 addresses this vulnerability by implementing proper input validation and output encoding. The fix adds null checking and improves sanitization of the $data variable before it is rendered in HTML context. Organizations should prioritize this upgrade given the sensitive nature of healthcare data managed by OpenEMR.

Detailed patch information is available in the GitHub Security Advisory and the commit implementing the fix.

Workarounds

  • Restrict access to the billing interface to only essential personnel until patching is complete
  • Implement WAF rules to block requests containing common XSS payload patterns targeting billing endpoints
  • Enable strict Content Security Policy headers to prevent execution of injected scripts
  • Consider placing the OpenEMR billing interface behind additional authentication or network segmentation
bash
# Configuration example - Apache CSP header to mitigate XSS
# Add to OpenEMR Apache configuration or .htaccess
Header set Content-Security-Policy "default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; frame-ancestors 'none';"

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeXSS

  • Vendor/TechOpen Emr

  • SeverityHIGH

  • CVSS Score8.5

  • EPSS Probability0.16%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityHigh
  • AvailabilityNone
  • CWE References
  • CWE-79
  • Vendor Resources
  • GitHub Code Review

  • GitHub Commit Log

  • GitHub Security Advisory
  • Related CVEs
  • CVE-2026-33932: OpenEMR Stored XSS Vulnerability

  • CVE-2026-33912: Open-emr OpenEMR XSS Vulnerability

  • CVE-2026-33911: OpenEMR Cross-Site Scripting Vulnerability

  • CVE-2026-33933: OpenEMR Reflected XSS Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English