Read the docs

Incorrect row seen by AFTER triggers in PostgreSQL MERGE

Priority LOW 24CWE-1250Published · Updated

Key facts

Attack vector
Network
Privileges required
Low
User interaction
None
Attack complexity
Low
Impact type
—
Confidentiality · integrity · availability
Low · Low · None
Fix status
Partial Red Hat: 1 fixed, 1 without a fix

Attack profile from CVSS 3.1 · CNA. Fix status from CNA and Red Hat.

Summary

PostgreSQL 18 before 18.7, 17 before 17.12, 16 before 16.16 and 15 before 15.20 are affected, and earlier versions are not. Inconsistent transition-capture state in MERGE (CWE-1250) can make an AFTER trigger process the wrong new row. A user who can modify table data triggers it with a partitioned table MERGE that performs an INSERT before an UPDATE. The attacker needs low privileges over the network, and the impact is low on confidentiality and integrity.

Written with Claude Haiku 5.5 from the sources below · 2026-11-14

Description from the CNA

Inconsistent transition-capture state in PostgreSQL MERGE allows a table data modifier to make an AFTER trigger process the wrong new row, via a partitioned table MERGE that performs an INSERT before an UPDATE. Within major versions 15-18, minor versions before PostgreSQL 18.7, 17.12, 16.16, and 15.20 are affected. Versions before PostgreSQL 15 are unaffected.

Why it matters now

EPSS 0.00251 16th percentileScored 2026-11-16
Fix Partial PostgreSQL: 18.7, 17.12, 16.16 +1Red Hat: 1 advisoryRed Hat: 1 fixed, 1 without a fix

SSVC decision points

Not available: CISA has not published SSVC decision points for this record.

Affected products

VendorProductAffected versionsFixed inStatusSource
—PostgreSQL18 to before 18.7; 17 to before 17.12; 16 to before 16.16; 15 to before 15.2018.7, 17.12, 16.16, 15.20Patch availableCNA
  • PostgreSQL Vendor— Affected 18 to before 18.7; 17 to before 17.12; 16 to before 16.16; 15 to before 15.20 Fixed in 18.7, 17.12, 16.16, 15.20 Patch available CNA

Remediation

Upgrade PostgreSQL to 18.7, 17.12, 16.16 or 15.20, matching the major version in use. Red Hat advisory RHSA-2026:99821 is listed for Red Hat Hardened Images, which Red Hat lists as affected with no fix plan available.

Written with Claude Haiku 5.5 from the sources below · 2026-11-14

  • Fix · CNA PostgreSQL Fixed in 18.7, 17.12, 16.16, 15.20

Red Hat 1 advisory

  • RHSA-2026:99821 Released 2026-11-12 · Red Hat rating Important
    Red Hat Hardened Images RPMs bug fix and enhancement update
    • Red Hat Hardened Images libpq-18.7-0.1.hum1@aarch64, libpq-18.7-0.1.hum1@s390x, libpq-18.7-0.1.hum1@src +4

Vendor assessments

Red Hat

Red Hat rating: Moderate. Red Hat's page for this CVE →

ProductStatusPlan or fix
Red Hat Hardened ImagesAffectedNo fix yet
Red Hat Hardened ImagesFixed RHSA-2026:99821

Timeline

  1. 2026-11-12 Threatist record created from CVE-2026-116312
  2. 2026-11-12 Alias added: GHSA-xqm8-qxc4-qxc9
  3. 2026-11-12 Affected versions changed · Red Hat
  4. 2026-11-12 CVSS score added · Red Hat
  5. 2026-11-13 Fix available: RHSA-2026:99821 · Red Hat
  6. 2026-11-14 Fix available: Red Hat Hardened Images · Red Hat

References

Sources