Back to Newsroom
Threat Intel

PostgreSQL fixes 52 flaws, including code execution in all supported versions

PostgreSQL 18.7, 17.12, 16.16, 15.20 and 14.25 close 52 CVEs. The worst, CVE-2026-6460 (CVSS 8.8), lets a user who can create objects run code on the server. C extensions must be rebuilt.

PostgreSQL fixes 52 flaws, including code execution in all supported versions

PostgreSQL fixes 52 security flaws, including a code execution bug in every supported version

The PostgreSQL project shipped versions 18.7, 17.12, 16.16, 15.20 and 14.25 on 12 November 2026. The update closes 52 CVEs and more than 140 ordinary bugs. The most serious issue, CVE-2026-6460, lets a database user who can create objects run code on the server as the operating system account that runs PostgreSQL.

What happened

CVE-2026-6460 is a type confusion flaw rated 8.8 under CVSS 3.1. PostgreSQL did not track typed values well enough, and values did not carry their own type. When a column's type changed through ALTER ... SET DATA TYPE, old values could survive in the data dictionary, in PL/pgSQL variables and elsewhere, and the server would later read them as if they had the new type. Other DDL sequences reach the same state, for example adding a column, rolling back, and adding it again.

The fix adds version checks so the server can spot a composite value that no longer matches the structure it expects. It also adds locking around some of these changes and refuses certain column type changes that functions depend on.

The flaw is one of 32 issues in this release scored at 8.8, which is also the highest score in the batch. Most are memory safety and type confusion bugs in the core server, the procedural languages (PL/Perl, PL/Tcl, PL/pgSQL) and dblink.

Who is affected

Every PostgreSQL server older than 18.7, 17.12, 16.16, 15.20 or 14.25 is affected by CVE-2026-6460. An attacker needs a valid login with the right to create or alter database objects, so the bug cannot be triggered by an anonymous client. That still covers a lot of real setups: shared databases, multi-tenant platforms, development servers where application accounts own their schema, and any service that lets customers run their own DDL.

At the time of writing there are no reports of exploitation. CISA's assessment in the CVE record lists exploitation as "none", and the flaw is not in the CISA Known Exploited Vulnerabilities catalog.

A few other fixes deserve attention:

  • CVE-2026-116322 (PostgreSQL 18 only, CVSS 5.3): a client that has not logged in can time a cancel request so the server restarts, interrupting every session.
  • Client tools. A crafted archive can make pg_restore run code as the user running it (CVE-2026-116314), and a tar-format dump can inject psql commands through its restore script (CVE-2026-116330). Further flaws affect pg_dump, reindexdb and vacuumdb.

PostgreSQL 14 reached end of life with this release. 14.25 is its last update, and older major versions get nothing.

What to do now

  1. Update the server to 18.7, 17.12, 16.16, 15.20 or 14.25, matching your major version. No dump and reload is needed: stop the service, replace the binaries, start it again.
  2. Rebuild your C extensions. The project says full protection requires rebuilding C-language extensions against the new release, and some will need source changes. Pull updated extension packages from the same repository as the server.
  3. Leave the new checks on. The release adds a composite_type_mismatch parameter that can switch the checks off. The project warns that doing so carries security risks; use it only as a short-term fallback.
  4. Update client tools everywhere, including on admin laptops and backup hosts that run pg_dump, pg_restore, reindexdb or vacuumdb. Don't restore archives from sources you don't trust until they are patched.
  5. Review who can run DDL. Untrusted roles should not hold CREATE on schemas or ownership of tables. That narrows the CVE-2026-6460 attack surface even after patching.
  6. Do the post-update steps. Reindex GIN indexes you suspect, pg_trgm GiST indexes and B-tree indexes on bpchar columns, and take a fresh full backup if you use incremental backups.
  7. Plan the move off PostgreSQL 14 if you still run it.

There is no workaround for CVE-2026-6460 short of updating. Details are in the PostgreSQL advisory and the NVD entry.

Outdated database servers are easy to lose track of, especially on internal networks and in forgotten test environments. Our vulnerability scanning service finds PostgreSQL instances across your estate, flags the ones still below the fixed versions, and tracks them until they are patched.

SHARE