/

CVE-2026-124453

Severity:

HIGH RISK

(7.1)

IDOR (CWE-639) in OpenEMR Patient Portal Settings

CVE-2026-124453

Analyzed

Vulnerability type

Category:

Insecure Direct Object Reference (IDOR)

CWE:

CWE-639

Impact:

Unauthorized modification of another patient's portal settings

Severity:

HIGH RISK

(7.1)

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

OpenEMR's patient portal contains an insecure direct object reference that can let an authenticated patient change settings belonging to another patient. The issue becomes risky when the server accepts a patient identifier from a request without confirming that the requesting patient is authorized to update that patient's settings.

Affected context

The vulnerability is reported in portal/lib/persist.php in OpenEMR versions before 8.3.0. It concerns JSON POST requests that include the setting_patient parameter to identify whose portal settings are being changed; risk exists if the target patient identifier is not checked against the authenticated user's authorization.

Exploit preconditions

  • Attack surface: The patient portal settings persistence endpoint.
  • Required access: An authenticated portal patient account.
  • Trigger point: A JSON POST request handled by portal/lib/persist.php.
  • Why exploitation is possible: The request's setting_patient value can be changed to another patient's PID if the server does not verify that the authenticated user may modify settings for that patient.

Why this happens

The underlying issue is an authorization check that does not adequately bind the requested patient record to the authenticated user's permissions. Trusting a client-supplied object identifier without verifying access can allow one user to modify another user's data. This maps to CWE-639: Authorization Bypass Through User-Controlled Key.

Potential impact

  • An authenticated patient may be able to alter another patient's portal settings, such as the portal theme.
  • Unauthorized changes could affect the other patient's portal experience.
  • Repeated or broader access-control gaps could put additional patient-specific settings at risk.

General mitigation guidance

Common defensive patterns include:

  • Deriving the target patient identity from the authenticated session where possible, rather than trusting a client-supplied identifier.
  • Enforcing a server-side authorization check for every requested patient record and settings change.
  • Applying deny-by-default access rules and limiting permissions to the minimum necessary.
  • Validating requested changes against an explicit allowlist of settings and permitted actions.
  • Keeping authorization checks close to the operation that reads or writes patient data.

How teams detect issues like this

  • Review handlers that accept patient identifiers from request parameters and verify that authorization is checked for the specific target record.
  • Use static analysis or code review rules to flag writes keyed by client-controlled identifiers without a corresponding access-control check.
  • Add tests that confirm a patient cannot read or modify another patient's settings by changing an identifier.
  • Apply policy checks to require object-level authorization for patient data operations; automated code review tools may help identify missing checks.

Sources

SourceLink
github.comgithub.com/openemr/openemr/security/advisories/GHSA-rrw3-g25h-x68h
vulncheck.comvulncheck.com/advisories/openemr-before-8.3.0-idor-in-portal-patient-settings-via-persist-php

Frequently asked

questions

The described issue requires an authenticated patient portal account and an endpoint that accepts a target patient identifier without adequately checking authorization.

The reported behavior allows an authenticated patient to target another patient's PID; access to that patient's account is not described as a prerequisite.

Verify server-side that the authenticated user is authorized to modify settings for the specific patient record, and avoid relying on a client-supplied identifier alone.

Apply object-level authorization to every patient data operation and test that changing request identifiers cannot cross patient boundaries.

Find out what's already
exploitable in your codebase.