CVE-2026-49142

OpenEMR Before 8.5.0 SQL Injection via form_icd_codes[]

Published Oct 29, 2026 CVSS 4.0 · 8.7 High EPSS < 1% KEV · Not listed
Description
OpenEMR before 8.5.0 contains an authenticated SQL injection vulnerability in the Syndromic Surveillance module that allows users with Clinician-level privileges to read and modify arbitrary database contents by submitting crafted values in the form_icd_codes[] POST parameter to the syndromicsurveillance/index endpoint. Attackers can inject an unquoted numeric IN() clause and UNION DISTINCT SELECT statement using hex-encoded literals to abuse MySQL extractvalue() for error-based exfiltration of bcrypt password hashes and execute stacked queries that reset passwords, resulting in full administrative account takeover.

Analysis

AI-generated

Technical impact

An authenticated SQL injection flaw exists in the Syndromic Surveillance module of OpenEMR versions prior to 8.5.0. The flaw is triggered by passing crafted data in the POST parameter form_icd_codes[] to the syndromicsurveillance/index endpoint. Attackers can inject a numeric IN() clause and UNION DISTINCT SELECT statements using hex‑encoded literals, leveraging MySQL extractvalue() to achieve error‑based exfiltration of bcrypt password hashes. The injection also permits stacked queries that reset arbitrary user passwords, enabling a clinician‑level user to elevate privileges to full administrative control.

Affected Systems

The vulnerability affects OpenEMR software from the vendor openemr:openemr, specifically all releases before version 8.5.0. Users of these versions should verify their installed version and compare it to the official release notes indicating the fix of the SQL injection issue.

Risk and Exploitability

The CVSS score of 8.7 indicates a high impact weakness. No EPSS score is currently published, and the vulnerability is not listed in CISA’s KEV catalog, but the severity suggests a significant risk. The attack requires authenticated access to the system with Clinician-level privileges; once authenticated, the attacker can inject malicious SQL and obtain credential and database data or reset passwords. The practical exploitability is therefore high for users who have legitimate clinician-level logins, though public exploit availability is uncertain.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade to OpenEMR 8.5.0 or later, applying the commit that fixes the form_icd_codes[] injection.
  • If an immediate upgrade is not possible, enforce strict input validation on form_icd_codes[] and use prepared statements or properly escape user input to prevent SQL injection, addressing the CWE‑89 weakness.
  • If the Syndromic Surveillance module is not required, disable it and restrict access to its endpoints to privileged administrators only.

Generated by OpenCVE AI on October 29, 2026 at 16:18 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Open-emr
Open-emr openemr
CPEs cpe:2.3:a:open-emr:openemr:*:*:*:*:*:*:*:*
Vendors & Products Open-emr
Open-emr openemr
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Openemr
Openemr openemr
Vendors & Products Openemr
Openemr openemr
Type Values Removed Values Added
Description OpenEMR before 8.5.0 contains an authenticated SQL injection vulnerability in the Syndromic Surveillance module that allows users with Clinician-level privileges to read and modify arbitrary database contents by submitting crafted values in the form_icd_codes[] POST parameter to the syndromicsurveillance/index endpoint. Attackers can inject an unquoted numeric IN() clause and UNION DISTINCT SELECT statement using hex-encoded literals to abuse MySQL extractvalue() for error-based exfiltration of bcrypt password hashes and execute stacked queries that reset passwords, resulting in full administrative account takeover.
Title OpenEMR Before 8.5.0 SQL Injection via form_icd_codes[]
Weaknesses CWE-89
References
Metrics cvssV3_1

{'score': 8.8, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H'}

cvssV4_0

{'score': 8.7, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-89

    Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')

Sources

Status
PUBLISHED
Assigner
VulnCheck
Published
Updated
Nov 8, 2026, 2:04 PM
Reserved
May 27, 2026, 5:40 PM
Status
Analyzed
Published
Oct 29, 2026, 1:17 PM
Modified
Nov 10, 2026, 7:01 PM