Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…
EPSS 0.3%top 75%

CVE-2026-12050: CWE-89 Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') in pgadmin.org pgAdmin 4

0
Medium
VulnerabilityCVE-2026-12050cvecve-2026-12050cwe-89
Published: 06/18/2026 (06/18/2026, 23:37:19 UTC)
Source: CVE Database V5
Vendor/Project: pgadmin.org
Product: pgAdmin 4

Description

SQL injection in pgAdmin 4's named restore point endpoint (POST /browser/server/restore_point/{gid}/{sid}). The user-supplied 'value' field was interpolated directly into the SQL string with str.format() instead of being passed as a bound parameter, allowing an authenticated pgAdmin user with a connected PostgreSQL session to inject additional statements through that endpoint. The injected SQL executes under the database role the user is already authenticated as. The defect does not cross a privilege boundary -- the user already has direct SQL access to that role through the Query Tool -- so the attacker gains no capability beyond what their database role already grants them. The marginal impact accounts for the fact that the injection path is not the documented SQL-execution interface, so a deployment that gates the Query Tool at the application layer could see SQL executed through a path it did not anticipate. Fix passes the restore point name as a bound parameter and schema-qualifies the function call as pg_catalog.pg_create_restore_point so a non-default search_path on the connection cannot redirect the call to a shadow definition. A regression test asserts the value arrives as a bound parameter and not spliced into the SQL string. This issue affects pgAdmin 4: from 1.0 before 9.16.

CVSS v3.1

Score 4.3medium

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
Low
Availability
None
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N

Affected software

GitHub Actionsmore threats →cve
pgAdmin 4
pkg:github/pgAdmin 4
Affected versions
>=1.0 <9.16

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 06/26/2026, 19:15:20 UTC

Technical Analysis

This vulnerability in pgAdmin 4's POST /browser/server/restore_point/{gid}/{sid} endpoint arises from improper neutralization of special elements in an SQL command (CWE-89). The 'value' field is interpolated directly into an SQL string using str.format() instead of being passed as a bound parameter, enabling SQL injection by authenticated users with an active PostgreSQL session. The injected SQL executes under the user's existing database role, which already has direct SQL access, so the impact is limited to the user's existing privileges. The fix involves passing the restore point name as a bound parameter and schema-qualifying the function call to pg_catalog.pg_create_restore_point to avoid function call hijacking via search_path manipulation. A regression test ensures the parameter is bound correctly. The vulnerability affects pgAdmin 4 versions from 1.0 before 9.16. No official patch or remediation level is stated in the vendor advisory.

Potential Impact

An authenticated pgAdmin user with a connected PostgreSQL session can inject additional SQL statements via the named restore point endpoint. The injected SQL executes with the same privileges as the user's database role, which already has direct SQL execution capabilities through the Query Tool. Therefore, there is no privilege escalation or impact beyond the user's existing permissions. The vulnerability could allow SQL execution through an unexpected application path, potentially bypassing application-layer restrictions that gate the Query Tool.

Mitigation Recommendations

Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. The described fix involves passing user input as bound parameters and schema-qualifying function calls to prevent SQL injection and function hijacking. Until an official fix is released, restrict access to authenticated users and monitor for unusual activity. Deployments that gate the Query Tool at the application layer should verify that this endpoint is similarly protected.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
PostgreSQL
Date Reserved
2026-06-11T20:40:09.826Z
Cvss Version
3.1
State
PUBLISHED
Remediation Level
null

Threat ID: 6a357432f198dc38c1bc0d45

Added to database: 06/19/2026, 16:54:10 UTC

Last enriched: 06/26/2026, 19:15:20 UTC

Last updated: 08/01/2026, 19:17:58 UTC

Views: 97

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses