/

CVE-2026-85399

Severity:

HIGH RISK

(7.3)

SQL Injection (CWE-89) in Hospital Information System

CVE-2026-85399

Deferred

Vulnerability type

Category:

SQL Injection

CWE:

CWE-74, CWE-89

Impact:

Unauthorized database access and data manipulation

Severity:

HIGH RISK

(7.3)

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

A SQL injection vulnerability in the Hospital Information System allows attacker-controlled input supplied to the prescription lookup function to alter database queries. Because the affected endpoint can be reached remotely, an attacker who can submit crafted identifier values may access, modify, or otherwise interfere with sensitive healthcare data.

Affected context

The vulnerability occurs in the getSinglePresp function within includes/presp/PrespController.php when the prescription identifier is incorporated into a database query without sufficient separation between data and SQL syntax. Risk is higher when the function is exposed through a remotely reachable application endpoint and the input is not consistently validated or parameterized.

Exploit preconditions

  • Attack surface: A remotely reachable Hospital Information System endpoint that invokes the prescription lookup functionality
  • Required access: The ability to submit requests to the affected function; authentication requirements depend on the application's access controls
  • Trigger point: Processing of the ID argument by getSinglePresp
  • Why exploitation is possible: Attacker-controlled input may be interpreted as part of a database statement when query construction does not reliably use parameter binding

Why this happens

The underlying bug is an injection flaw caused by treating externally supplied identifier data as query syntax. If the value is concatenated into a SQL statement or otherwise passed to a database API without parameterization, database commands and user data are not kept separate. This maps primarily to CWE-89: Improper Neutralization of Special Elements used in an SQL Command (SQL Injection); CWE-74 broadly describes the unsafe interpretation of externally controlled input in an expression or command.

Potential impact

  • An attacker may retrieve sensitive patient, prescription, or administrative records.
  • An attacker could alter or delete database information.
  • The application may disclose database errors or internal schema details.
  • Database availability could be degraded through resource-intensive queries.
  • Compromised records could affect clinical workflows, reporting, or regulatory compliance.

General mitigation guidance

Mitigation generally centers on making database queries data-only by design and reducing trust in request parameters.

Common defensive patterns include:

  • Use parameterized queries or prepared statements for every database operation.
  • Apply allowlist validation for identifier fields, including expected type, format, and bounds.
  • Avoid constructing SQL statements through string concatenation or interpolation.
  • Use database accounts with only the permissions required by the application.
  • Return generic error messages while keeping detailed database errors in protected logs.
  • Apply consistent authorization checks before exposing prescription or patient records.
  • Treat validation as a secondary control rather than a replacement for parameter binding.

How teams detect issues like this

Organizations can identify SQL injection risks through:

  • Static analysis rules for string-built SQL and database calls that receive request parameters directly.
  • Code review checks for query construction in controller and data-access layers.
  • Dynamic application testing that evaluates identifier and filter parameters for unexpected query behavior.
  • Database activity monitoring for anomalous statement patterns, access volumes, or privilege use.
  • Web application firewall and API policy rules that detect suspicious input patterns, used as defense-in-depth rather than the primary fix.
  • Automated security review tools that flag unparameterized queries and missing input validation.

Sources

SourceLink
code-projects.orgcode-projects.org/
github.comgithub.com/lccc-t/CVE/issues/4
vuldb.comvuldb.com/cve/CVE-2026-85399
vuldb.comvuldb.com/submit/894860
vuldb.comvuldb.com/vuln/398542
vuldb.comvuldb.com/vuln/398542/cti

Frequently asked

questions

Yes, the affected functionality is described as remotely reachable. Successful exploitation still depends on the endpoint being exposed and on any authentication or authorization controls protecting it.

The available details do not establish whether authentication is required. The critical prerequisite is the ability to submit input that reaches the vulnerable prescription lookup function.

Use parameterized queries or prepared statements, validate identifier values against an allowlist, and enforce authorization before returning records.

Combine secure database APIs, centralized data-access patterns, least-privileged database accounts, code review, static analysis, and regular dynamic security testing.

Find out what's already
exploitable in your codebase.