CVE-2026-16238

8.8

PostgreSQL · PostgreSQL

A type confusion vulnerability in the pg_restore_attribute_stats function allows an authenticated object creator to execute arbitrary code on the PostgreSQL server.

Executive summary

A high-severity type confusion vulnerability in PostgreSQL allows an authenticated user to perform arbitrary code execution by conflating range and multirange values.

Vulnerability

The flaw resides in the pg_restore_attribute_stats function. An authenticated user with permissions to create objects can exploit a type confusion between range and multirange values to execute arbitrary code with the privileges of the database service account.

Business impact

The CVSS score of 8.8 reflects the high risk of this vulnerability. Successful exploitation permits an attacker to gain control over the underlying operating system user, which may lead to unauthorized data access, privilege escalation, and persistent threats to the database infrastructure. Maintaining the integrity of the database host is essential for overall business continuity.

Remediation

Immediate Action: Upgrade PostgreSQL instances running version 18 to version 18.5 or higher to resolve the vulnerability.

Proactive Monitoring: Audit logs for unusual object creation activities or unexpected calls to statistics-related functions.

Compensating Controls: Limit the ability of standard database users to create objects or perform administrative tasks that involve statistics restoration.

Exploitation status

Public Exploit Available: No

Analyst recommendation

Security teams should treat this vulnerability as a priority for all PostgreSQL 18 deployments. Upgrading to the patched version is the necessary step to prevent potential exploitation and ensure the security of the database environment.

More PostgreSQL CVEs