Skip to main content

PostgreSQL CVE-2026-6475

| EUVDEUVD-2026-30286 HIGH
UNIX Symbolic Link (Symlink) Following (CWE-61)
2026-05-14 PostgreSQL GHSA-7h2q-899j-9636
8.8
CVSS 3.1 · Vendor: PostgreSQL
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Compromise origin database
  2. Delivery
    Gain superuser privileges
  3. Exploit
    Plant symlinks in data directory
  4. Install
    Administrator runs pg_basebackup/pg_rewind
  5. C2
    Symlinks overwrite destination OS files
  6. Execute
    Files transferred across trust boundary
  7. Impact
    Postgres user login triggers payload
  8. Step 8
    OS account takeover

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling UNIX symlink resolution
Exploitation Conditions

Requires database superuser privileges on the origin PostgreSQL instance to create malicious symlinks in the database directory. Requires administrator to execute pg_basebackup in plain format mode (not tar format) or pg_rewind against the compromised origin database during routine backup or replication operations. Exploitation window exists only if backup files are transferred to a different system (VM migration, snapshot restore) or file permissions are modified before PostgreSQL server restart-standard backup-and-immediate-start workflows are not vulnerable because server start already grants origin superuser implicit OS-level control via shared_preload_libraries. Target destination system must use predictable filesystem paths for postgres user files (e.g., standard /var/lib/postgres/.bashrc location). Limited by the narrow operational scenario where trust boundaries change between backup execution and server initialization.

Impact

Real-world risk is significantly lower than CVSS 8.8 suggests due to multiple limiting factors confirmed in vendor description. Attack vector is marked AV:N (network) but requires PR:N (no authentication), which conflicts with the superuser prerequisite-this indicates CVSS scoring reflects the network-accessible nature of PostgreSQL protocol, not actual exploitation barriers. The UI:R (user interaction required) is critical: a legitimate administrator must execute pg_basebackup or pg_rewind against a compromised origin database, which typically occurs only during planned backup or replication operations. PostgreSQL vendor advisory explicitly states 'practical implications only if one takes relevant action between these commands and server start' such as VM migration or snapshotting, meaning standard backup-and-immediate-restore workflows are NOT vulnerable. No KEV listing or public POC exists, and EPSS data not provided but likely low given the narrow operational window. Primary risk is in multi-tenant hosting environments or managed database services where backup files cross trust boundaries. For single-instance deployments, existing trust model already assumes origin superuser can compromise the system via shared_preload_libraries, making this a marginal escalation.

Exploit ScenarioDerived

An attacker compromises a PostgreSQL database and gains superuser privileges on the origin server (e.g., through SQL injection or credential theft). The attacker creates malicious symlinks in the origin database directory pointing to /var/lib/postgres/.bashrc on the destination system. When a database administrator performs a scheduled backup using pg_basebackup in plain format or runs pg_rewind for replication recovery, the tool follows the symlinks and overwrites .bashrc with attacker-controlled code. If the administrator then moves these backup files to a production VM or creates a VM snapshot before restarting PostgreSQL, the attacker's code executes when the postgres user next logs in or starts the database, achieving OS-level account takeover.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – May 14, 2026

Symlink following vulnerabilities in PostgreSQL pg_basebackup and pg_rewind enable database superusers to overwrite arbitrary files on the destination server's filesystem, leading to local OS account takeover. Exploitation requires a malicious origin database superuser convincing an administrator to run these backup/replication tools (UI:R in CVSS), with practical impact limited to scenarios where database files are transferred between systems or snapshotted before server restart. No public exploit identified at time of analysis. CVSS 8.8 reflects theoretical severity, but real-world risk depends on specific operational workflows involving backup file transfers across trust boundaries.

RemediationAI

Upgrade to PostgreSQL 14.23, 15.18, 16.14, 17.10, or 18.4 depending on your major version branch. Patches available through standard PostgreSQL distribution channels and official vendor advisory at https://www.postgresql.org/support/security/CVE-2026-6475/. If immediate patching is not feasible, implement these mitigations: (1) avoid using pg_basebackup plain format-use tar format instead, which is not vulnerable; (2) inspect and sanitize origin database file permissions before running pg_basebackup or pg_rewind, specifically checking for symlinks in the origin data directory; (3) run these utilities only against trusted origin databases under your administrative control; (4) implement mandatory file integrity monitoring on destination postgres OS account home directory files (.bashrc, .bash_profile, .ssh/authorized_keys) with alerts before server restart. Note that switching to tar format may impact existing backup automation scripts. Sandboxing pg_basebackup/pg_rewind with restricted filesystem access using AppArmor or SELinux provides defense-in-depth but may interfere with legitimate backup operations requiring broad filesystem access.

Affected VersionsENISA

PostgreSQL 15 <15.18
PostgreSQL 18 <18.4
PostgreSQL 16 <16.14
PostgreSQL 0 <14.23
PostgreSQL 17 <17.10

Affected Packages

euvd postgresql fix: 14.23, 15.18, 16.14, 17.10, 18.4

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The vulnerability exploits symlink following (CWE-61) in two PostgreSQL administrative utilities: pg_basebackup in plain format mode and pg_rewind. These tools copy database files from an origin server to a destination. When processing symlinks in the origin database directory, the utilities fail to properly validate file paths, allowing a malicious origin superuser to craft symlinks that resolve to sensitive files on the destination filesystem (e.g., /var/lib/postgres/.bashrc). When the tool follows these symlinks during file copy operations, it overwrites the target files with attacker-controlled content. This represents a confused deputy attack where legitimate administrative tools are tricked into performing unauthorized file operations. The CPE identifier cpe:2.3:a:n/a:postgresql applies to all vulnerable PostgreSQL server installations prior to patched versions.

Know when PostgreSQL gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (PostgreSQL) PRIMARY 8.8 HIGH
AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
SUSE HIGH
Red Hat 6.7 MEDIUM

Primary rating from Vendor (PostgreSQL).

CVSS VectorVendor: PostgreSQL

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

2
Patch available
May 14, 2026 - 15:01 EUVD
CVE Published
May 14, 2026 - 13:00 nvd
HIGH 8.8

DescriptionCVE.org

Symlink following in PostgreSQL pg_basebackup plain format and in pg_rewind allows an origin superuser to overwrite local files, e.g. /var/lib/postgres/.bashrc, that hijack the operating system account. It will remain the case that starting the server after these commands implicitly trusts the origin superuser, due to features like shared_preload_libraries. Hence, the attack has practical implications only if one takes relevant action between these commands and server start, like moving the files to a different VM or snapshotting the VM. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.

Executive ViewAI

Why It Matters

PostgreSQL pg_basebackup and pg_rewind contain symlink-following vulnerabilities (CVE-2026-6475, CVSS 8.8) that allow malicious database superusers to overwrite arbitrary files on destination servers, potentially leading to operating system account compromise. This risk is limited to environments where administrators manually execute backup or replication operations between PostgreSQL instances, particularly when backup files are transferred across organizational trust boundaries or processed before system restart. Organizations using these tools for cross-system database replication or disaster recovery should treat this as a privilege-escalation pathway requiring immediate procedural review.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: (1) Restrict pg_basebackup and pg_rewind execution to dedicated non-privileged OS accounts; (2) Perform backup operations only from trusted, isolated source systems; (3) Scan backup file destinations with file integrity tools before replication or deployment; (4) Isolate backup destinations in network segments with strict outbound access controls; (5) Require multi-person authorization for cross-system database backup operations.

Threat Intelligence Overview

EPSS Score
0.0%
Top 86% exploitable
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment MSRC Vendor VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

44
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

CVE-2025-1094 HIGH POC
8.1 Feb 13

PostgreSQL libpq functions PQescapeLiteral(), PQescapeIdentifier(), PQescapeString(), and PQescapeStringConn() improperl

CVE-2024-55964 CRITICAL POC
9.8 Mar 26

An issue was discovered in Appsmith before 1.52. Rated critical severity (CVSS 9.8), this vulnerability is remotely expl

CVE-2013-1899 MEDIUM POC
6.5 Apr 04

Argument injection vulnerability in PostgreSQL 9.2.x before 9.2.4, 9.1.x before 9.1.9, and 9.0.x before 9.0.13 allows re

CVE-2026-20253 CRITICAL POC
9.8 Jun 10

Unauthenticated arbitrary file write in Splunk Enterprise (below 10.2.4 and 10.0.7) and Splunk Cloud Platform (below 10.

CVE-2026-9586 CRITICAL POC
9.3 Jul 17

Unauthenticated SQL injection in Sangoma Switchvox SMB Edition 8.3 (build 104997) lets remote attackers execute arbitrar

CVE-2017-7546 CRITICAL
9.8 Aug 16

PostgreSQL versions before 9.2.22, 9.3.18, 9.4.13, 9.5.8 and 9.6.4 are vulnerable to incorrect authentication flaw allow

CVE-2015-1352 MEDIUM POC
5.0 Mar 30

The build_tablename function in pgsql.c in the PostgreSQL (aka pgsql) extension in PHP through 5.6.7 does not validate t

CVE-2024-10553 CRITICAL POC
9.8 Mar 20

A vulnerability in the h2oai/h2o-3 REST API versions 3.46.0.4 allows unauthenticated remote attackers to execute arbitra

CVE-2019-9193 HIGH POC
7.2 Apr 01

In PostgreSQL 9.3 through 11.2, the "COPY TO/FROM PROGRAM" function allows superusers and users in the 'pg_execute_serve

CVE-2026-40887 CRITICAL POC
9.1 Apr 14

Unauthenticated SQL injection in Vendure Shop API allows remote attackers to execute arbitrary SQL commands against the

CVE-2022-24760 CRITICAL POC
10.0 Mar 12

Parse Server is an open source http web server backend. Rated critical severity (CVSS 10.0), this vulnerability is remot

CVE-2025-56157 CRITICAL POC
9.8 Dec 18

Hard-coded default PostgreSQL credentials shipped in the docker-compose.yaml of langgenius Dify through version 1.5.1 al

Vendor StatusVendor

SUSE

Severity: High
Product Status
SUSE Linux Enterprise Desktop 15 SP7 SUSE Linux Enterprise Module for Basesystem 15 SP7 Fixed
SUSE Linux Enterprise High Performance Computing 15 SP4-ESPOS Fixed
SUSE Linux Enterprise High Performance Computing 15 SP4-LTSS Fixed
SUSE Linux Enterprise High Performance Computing 15 SP5-ESPOS Fixed
SUSE Linux Enterprise High Performance Computing 15 SP5-LTSS Fixed

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy