CVE-2026-18408
Published:August 13, 2026
Updated:September 01, 2026
Untrusted data inclusion in pg_dump in PostgreSQL allows a malicious superuser of the origin server to inject arbitrary code for restore-time execution as the client operating system account running psql to restore the dump, via psql \restrict meta-command input expansion. The fix for CVE-2025-8714 introduced \restrict and \unrestrict to block this attack, but \unrestrict itself was sufficient for an attack. pg_dumpall is also affected. pg_restore is affected when used to generate a plain-format dump. Non-core use of \restrict would be affected, but we've not identified non-core use. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Affected Packages
https://github.com/postgres/postgres.git (GITHUB):
Affected version(s) >=REL_16_0 <REL_16_15Fix Suggestion:
Update to version REL_16_15https://github.com/postgres/postgres.git (GITHUB):
Affected version(s) >=REL_18_0 <REL_18_6Fix Suggestion:
Update to version REL_18_6https://github.com/postgres/postgres.git (GITHUB):
Affected version(s) >=REL_15_0 <REL_15_19Fix Suggestion:
Update to version REL_15_19https://github.com/postgres/postgres.git (GITHUB):
Affected version(s) >=REL_14_0 <REL_14_24Fix Suggestion:
Update to version REL_14_24https://github.com/postgres/postgres.git (GITHUB):
Affected version(s) >=REL_17_0 <REL_17_11Fix Suggestion:
Update to version REL_17_11Related Resources (1)
Do you need more information?
Contact UsCVSS v4
Base Score:
8.7
Attack Vector
NETWORK
Attack Complexity
LOW
Attack Requirements
NONE
Privileges Required
NONE
User Interaction
PASSIVE
Vulnerable System Confidentiality
HIGH
Vulnerable System Integrity
HIGH
Vulnerable System Availability
HIGH
Subsequent System Confidentiality
NONE
Subsequent System Integrity
NONE
Subsequent System Availability
NONE
CVSS v3
Base Score:
8.8
Attack Vector
NETWORK
Attack Complexity
LOW
Privileges Required
NONE
User Interaction
REQUIRED
Scope
UNCHANGED
Confidentiality
HIGH
Integrity
HIGH
Availability
HIGH
Weakness Type (CWE)
Inclusion of Functionality from Untrusted Control Sphere
EPSS
Base Score:
0.36