{"id":"CVE-2026-126491","kind":"vulnerability","aliases":["CVE-2026-126491"],"related":[],"title":"OpenEMR: stored SQL injection lets users read patient and credential data","description":"OpenEMR before 8.5.0 contains a stored SQL injection vulnerability in getByPatientDemographics() where layout_options field_id values are concatenated into the patient search WHERE clause. Attackers with Layout Editor access can plant a malicious field_id, allowing any authenticated low-privilege user to exfiltrate data from patient_data and users_secure tables.","summary":"OpenEMR, an electronic health records system, concatenates layout field IDs into its patient search SQL query without escaping them. A user who can edit form layouts can plant a malicious field ID that lets any logged-in low-privilege user extract data from the patient and user-credential tables.","severity":"high","cvss":8.3,"epss":null,"exploited":false,"exploited_at":null,"products":[{"name":"OpenEMR","fixed":[],"affected":"","ecosystem":"vendor"}],"ecosystems":["vendor"],"tags":["healthcare","openemr","other","self-hosted"],"not_affected_if":["openemr-8.5.0-or-later"],"how_to_check":"- Check the installed OpenEMR version in the admin footer or `version.php`; versions below `8.5.0` are listed as affected.\n- Review who holds Layout Editor access in the admin settings.","fix":"- Upgrade OpenEMR to `8.5.0` or later.","status":"open","published_at":"2026-11-13T10:17:59+00:00","first_seen_at":"2026-11-13T10:47:26+00:00","triaged_at":"2026-11-13T10:51:08+00:00","updated_at":"2026-11-13T10:51:08+00:00","category":"other","confidence":0.7,"triage":{"at":"2026-11-13T10:51:08Z","model":"claude-haiku-5-5","output":{"fix":"- Upgrade OpenEMR to `8.5.0` or later.","reach":"network","title":"OpenEMR: stored SQL injection lets users read patient and credential data","impact":"high","summary":"OpenEMR, an electronic health records system, concatenates layout field IDs into its patient search SQL query without escaping them. A user who can edit form layouts can plant a malicious field ID that lets any logged-in low-privilege user extract data from the patient and user-credential tables.","audience":"businesses","category":"other","nicknames":[],"who_cares":["openemr","healthcare","self-hosted"],"confidence":0.7,"fix_status":"available","needs_auth":"yes","worst_case":"Authenticated users read patient records and user credential tables","analyst_note":"","how_to_check":"- Check the installed OpenEMR version in the admin footer or `version.php`; versions below `8.5.0` are listed as affected.\n- Review who holds Layout Editor access in the admin settings.","plain_action":"","product_name":"OpenEMR","needs_analyst":false,"not_affected_if":["openemr-8.5.0-or-later"],"who_is_affected":"Any OpenEMR deployment before 8.5.0 where users can reach the patient search. The attacker needs Layout Editor access to plant the payload, then any authenticated user can trigger the read. Installations that restrict Layout Editor access to trusted administrators reduce exposure, but the sources do not say that this is a full mitigation.","user_interaction":"no","product_ecosystem":"vendor","needs_special_setup":"unknown","severity_if_unknown":"high"},"cost_usd":0.000741,"input_tokens":4620,"output_tokens":558,"severity_before":"high"},"analyst_status":null,"analyst_note":null,"search":"'-126491':14A,17A '-2026':13A,16A '8.5.0':79C 'access':106C 'allow':113C 'attack':102C 'authent':115C 'claus':101C 'concaten':31B,95C 'contain':80C 'credenti':10A,75B 'cve':12A,15A 'data':11A,68B,122C,125C 'edit':48B 'editor':105C 'electron':27B 'escap':42B 'exfiltr':121C 'extract':67B 'field':33B,55B,91C,111C 'form':49B 'getbypatientdemograph':87C 'health':28B 'healthcar':19B 'host':24B 'id':34B,56B,92C,112C 'inject':4A,84C 'layout':32B,50B,89C,104C 'let':5A,58B 'log':61B 'logged-in':60B 'low':64B,117C 'low-privileg':63B,116C 'malici':54B,110C 'openemr':1A,18A,20B,25B,77C 'option':90C 'patient':8A,37B,71B,98C,124C 'plant':52B,108C 'privileg':65B,118C 'queri':40B 'read':7A 'record':29B 'search':38B,99C 'secur':128C 'self':23B 'self-host':22B 'sql':3A,39B,83C 'store':2A,82C 'system':30B 'tabl':76B,129C 'user':6A,45B,66B,74B,119C,127C 'user-credenti':73B 'valu':93C 'vulner':85C 'without':41B","nicknames":[],"mitigations":[],"who_affected":"Any OpenEMR deployment before 8.5.0 where users can reach the patient search. The attacker needs Layout Editor access to plant the payload, then any authenticated user can trigger the read. Installations that restrict Layout Editor access to trusted administrators reduce exposure, but the sources do not say that this is a full mitigation.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"businesses","plain_action":null,"pkeys":["openemr"],"ptokens":["openemr"],"labels":["healthcare","high","openemr","other","selfhosted","vendor"],"campaign_type":null,"search_a":"'-126491':14A,17A '-2026':13A,16A 'credenti':10A 'cve':12A,15A 'data':11A 'inject':4A 'let':5A 'openemr':1A,18A 'patient':8A 'read':7A 'sql':3A 'store':2A 'user':6A","search_b":"'concaten':31B 'credenti':75B 'data':68B 'edit':48B 'electron':27B 'escap':42B 'extract':67B 'field':33B,55B 'form':49B 'health':28B 'healthcar':19B 'host':24B 'id':34B,56B 'layout':32B,50B 'let':58B 'log':61B 'logged-in':60B 'low':64B 'low-privileg':63B 'malici':54B 'openemr':20B,25B 'patient':37B,71B 'plant':52B 'privileg':65B 'queri':40B 'record':29B 'search':38B 'self':23B 'self-host':22B 'sql':39B 'system':30B 'tabl':76B 'user':45B,66B,74B 'user-credenti':73B 'without':41B","search_c":"'8.5.0':79C 'access':106C 'allow':113C 'attack':102C 'authent':115C 'claus':101C 'concaten':95C 'contain':80C 'data':122C,125C 'editor':105C 'exfiltr':121C 'field':91C,111C 'getbypatientdemograph':87C 'id':92C,112C 'inject':84C 'layout':89C,104C 'low':117C 'low-privileg':116C 'malici':110C 'openemr':77C 'option':90C 'patient':98C,124C 'plant':108C 'privileg':118C 'search':99C 'secur':128C 'sql':83C 'store':82C 'tabl':129C 'user':119C,127C 'valu':93C 'vulner':85C","cause_entry":null,"cause_path":null,"disclosures_checked_at":null,"first_public_at":"2026-10-28T01:33:40+00:00","kev":null,"cvss_vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:L/VA:N/SC:H/SI:L/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","cvss_by":"disclosure@vulncheck.com","poc_count":0,"sources":[{"source":"nvd","external_id":"CVE-2026-126491","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-126491","severity":null,"published_at":"2026-11-13T10:17:59+00:00","modified_at":"2026-11-13T10:17:59+00:00","first_seen_at":"2026-11-13T10:47:26+00:00","fetched_at":"2026-11-13T10:47:26+00:00","note":null}],"documents":[{"id":145225,"url":"https://github.com/openemr/openemr/security/advisories/GHSA-pc2q-9pcw-v899","title":"Vendor advisory: github.com","kind":"vendor","source":"nvd","publisher":"vendor","text":null,"published_at":"2026-10-28T01:33:40+00:00","relation":"advisory","confidence":null,"note":"Vendor advisory: github.com"},{"id":145226,"url":"https://www.vulncheck.com/advisories/openemr-before-8.5.0-sql-injection-via-getbypatientdemographics-in-patient-inc-php","title":"Third-party advisory: www.vulncheck.com","kind":"advisory","source":"nvd","publisher":"research","text":null,"published_at":null,"relation":"advisory","confidence":null,"note":"Third-party advisory: www.vulncheck.com"}],"disclosures":[],"exploit_sources":[],"notice":"Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai"}