PostgreSQL The PostgreSQL Database Server
Don't miss out!
Thousands of developers use stack.watch to stay informed.Get an email whenever new security vulnerabilities are reported in PostgreSQL.
Recent PostgreSQL Security Advisories
| Advisory | Title | Published |
|---|---|---|
| 2026-08-14 | PostgreSQL: CVE-2026-6470: PostgreSQL fails to check type USAGE privilege | August 14, 2026 |
| 2026-08-14 | PostgreSQL: CVE-2026-6471: PostgreSQL logical decoding can dlopen arbitrary file | August 14, 2026 |
| 2026-08-14 | PostgreSQL: CVE-2026-14663: PostgreSQL pgcrypto, for OpenSSL-disabled ciphers, silently encrypts to and decrypts from cleartext | August 14, 2026 |
| 2026-08-14 | PostgreSQL: CVE-2026-6469: PostgreSQL ALTER TABLE ALTER TYPE resets extended statistics ownership | August 14, 2026 |
| 2026-08-14 | PostgreSQL: CVE-2026-6464: PostgreSQL psql COPY FROM STDIN early failure processes data lines as psql commands | August 14, 2026 |
| 2026-08-14 | PostgreSQL: CVE-2026-14662: PostgreSQL tsvector and tsquery undersize allocations, via integer wraparound | August 14, 2026 |
| 2026-08-14 | PostgreSQL: CVE-2026-14664: PostgreSQL regexp heap buffer overflow executes arbitrary code | August 14, 2026 |
| 2026-08-13 | PostgreSQL: CVE-2026-14666: PostgreSQL row security caching disregards role modifications | August 13, 2026 |
| 2026-08-13 | PostgreSQL: CVE-2026-14673: PostgreSQL amcheck does not clear untrusted search path | August 13, 2026 |
| 2026-08-13 | PostgreSQL: CVE-2026-14670: PostgreSQL plperl tied object heap buffer overflow executes arbitrary code | August 13, 2026 |
PostgreSQL EOL Dates
Ensure that you are using a supported version of PostgreSQL. Here are some end of life, and end of support dates for PostgreSQL.
| Release | EOL Date | Status |
|---|---|---|
| 18 | November 14, 2030 |
Active
PostgreSQL 18 will become EOL in 4 years (in 2030). |
| 17 | November 8, 2029 |
Active
PostgreSQL 17 will become EOL in 3 years (in 2029). |
| 16 | November 9, 2028 |
Active
PostgreSQL 16 will become EOL in two years (in 2028). |
| 15 | November 11, 2027 |
Active
PostgreSQL 15 will become EOL next year, in November 2027. |
| 14 | November 12, 2026 |
EOL This Year
PostgreSQL 14 will become EOL this year, in November 2026. |
| 13 | November 13, 2025 |
EOL
PostgreSQL 13 became EOL in 2025. |
| 12 | November 21, 2024 |
EOL
PostgreSQL 12 became EOL in 2024. |
| 11 | November 9, 2023 |
EOL
PostgreSQL 11 became EOL in 2023. |
| 10 | November 10, 2022 |
EOL
PostgreSQL 10 became EOL in 2022. |
| 9.6 | November 11, 2021 |
EOL
PostgreSQL 9.6 became EOL in 2021. |
| 9.5 | February 11, 2021 |
EOL
PostgreSQL 9.5 became EOL in 2021. |
| 9.4 | February 13, 2020 |
EOL
PostgreSQL 9.4 became EOL in 2020. |
| 9.3 | November 8, 2018 |
EOL
PostgreSQL 9.3 became EOL in 2018. |
| 9.2 | November 9, 2017 |
EOL
PostgreSQL 9.2 became EOL in 2017. |
| 9.1 | October 27, 2016 |
EOL
PostgreSQL 9.1 became EOL in 2016. |
| 9.0 | October 8, 2015 |
EOL
PostgreSQL 9.0 became EOL in 2015. |
| 8.4 | July 24, 2014 |
EOL
PostgreSQL 8.4 became EOL in 2014. |
| 8.3 | February 7, 2013 |
EOL
PostgreSQL 8.3 became EOL in 2013. |
| 8.2 | December 5, 2011 |
EOL
PostgreSQL 8.2 became EOL in 2011. |
| 8.1 | November 8, 2010 |
EOL
PostgreSQL 8.1 became EOL in 2010. |
By the Year
In 2026 there have been 44 vulnerabilities in PostgreSQL with an average score of 7.1 out of ten. Last year, in 2025 PostgreSQL had 8 security vulnerabilities published. That is, 36 more vulnerabilities have already been reported in 2026 as compared to last year. However, the average CVE base score of the vulnerabilities in 2026 is greater by 2.63.
| Year | Vulnerabilities | Average Score |
|---|---|---|
| 2026 | 44 | 7.13 |
| 2025 | 8 | 4.50 |
| 2024 | 10 | 6.09 |
| 2023 | 9 | 5.18 |
| 2022 | 7 | 7.33 |
| 2021 | 5 | 6.53 |
| 2020 | 7 | 7.55 |
| 2019 | 7 | 6.40 |
| 2018 | 8 | 8.24 |
It may take a day or so for new PostgreSQL vulnerabilities to show up in the stats or in the list of recent security vulnerabilities. Additionally vulnerabilities may be tagged under a different product or component name.
Recent PostgreSQL Security Vulnerabilities
PostgreSQL refint Type Confusion Exec as OS User pre-18.5
CVE-2026-14671
8.8 - High
- August 13, 2026
Type confusion in PostgreSQL module "refint" allows an object creator to execute arbitrary code as the operating system user running the database. The fix for this emerged as a non-security bug report, and the fix appear in the git repository with subject "refint: Remove plan cache.", without a CVE number. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Object Type Confusion
PostgreSQL auth bypass via logical decoding plugin DLopen in 18.x/17.x
CVE-2026-6471
7.2 - High
- August 13, 2026
Missing authorization in PostgreSQL logical decoding allows a non-superuser holding REPLICATION privilege to dlopen any file visible to the operating system account running the server, via the choice of logical decoding plugin. This in turn runs arbitrary code as that account. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
AuthZ
PostgreSQL <18.5: ALTER TYPE Ownership Bug Enables Priv Escalation
CVE-2026-6469
3.8 - Low
- August 13, 2026
Incorrect ownership assignment in PostgreSQL ALTER TABLE ALTER TYPE command reassigns ownership of dependent statistics objects to the current user. This wrongly allows the table owner to run DROP STATISTICS and ALTER STATISTICS via this improper ownership. It wrongly denies those commands to the prior statistics object owner. DROP TABLE remains able to remove statistics objects, so this exploit achieves nothing in many ownership arrangements. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Incorrect Ownership Assignment
PostgreSQL DDL Auth Bypass Enables DoS on ALTER/ DROP Type (pre-18.5)
CVE-2026-6470
4.3 - Medium
- August 13, 2026
Missing authorization in PostgreSQL DDL commands allows an object creator to achieve denial of service against ALTER and DROP of the type, via creating a dependency on the type. Many DDL operations did check the privilege, but assigning a range subtype and referencing the type from an SQL expression did not. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
AuthZ
PostgreSQL Before 18.5: Untrusted Data Inclusion via psql COPY Error
CVE-2026-6464
8.1 - High
- August 13, 2026
Untrusted data inclusion in PostgreSQL psql COPY may allow a server administrator to elicit execution of data lines as psql commands, via error injection. If the "COPY FROM STDIN" or "\copy FROM STDIN" command fails before the server indicates that it awaits input rows, psql processes the in-line data rows as psql commands. "COPY FROM" with a filename is unaffected. The server administrator has no inherent control over the data rows, so a complete attack requires the attacker to separately acquire control of both the server and the data rows. Alternatively, an attacker controlling data rows alone might complete an attack through a coincidental error that they don't control. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Inclusion of Functionality from Untrusted Control Sphere
Untrusted Data Inclusion in pg_dump (PostgreSQL <18.5) Enables Code Exec via psql \restrict
CVE-2026-18408
8.8 - High
- August 13, 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.
Inclusion of Functionality from Untrusted Control Sphere
Heap Buffer Overflow in PostgreSQL pg_dump (v<18.5) Enables OS-Level RCE
CVE-2026-19385
8.8 - High
- August 13, 2026
Heap buffer overflow in PostgreSQL pg_dump of long function transform lists allows an object creator to execute arbitrary code as the operating system user running pg_dump, via a crafted transform list. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Heap-based Buffer Overflow
PostgreSQL ECPG Int Uflow 18.5 allows temp DoS via bytea
CVE-2026-16241
3.8 - Low
- August 13, 2026
Integer underflow in PostgreSQL ECPG allows a database server administrator to achieve temporary denial of service against the ECPG client via sending a bytea value lacking the mandatory prefix. The client overwrites a huge memory region with bytes outside attacker knowledge or control. This typically yields a simple SIGSEGV, but rare cases might achieve client-specific integrity impact via the write. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Integer underflow
PostgreSQL ascii() buffer over-read before 18.5/17.11/16.15/15.19/14.24
CVE-2026-18024
4.3 - Medium
- August 13, 2026
Buffer over-read in PostgreSQL ascii() SQL function allows a user to disclose up to 3 bytes after the end of a specific allocation, via a crafted text value. This is the same class of defect that CVE-2026-2006 fixed, though this instance has less impact. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Buffer Over-read
PostgreSQL <18.5 Type Confusion Enables OS Exec via Cursor Re-Creation
CVE-2026-16239
8.8 - High
- August 13, 2026
Type confusion in PostgreSQL "portal"/cursor lifecycle allows a user to execute arbitrary code as the operating system user running the database, via re-creation of a cursor or other portal with different types. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Object Type Confusion
PostgreSQL fuzzystrmatch Integer Wraparound Enables OS Code Exec (18.5)
CVE-2026-15742
8.8 - High
- August 13, 2026
Integer wraparound in PostgreSQL fuzzystrmatch allows a user to direct writes to a huge range of addresses, executing arbitrary code as the operating system user running the database, via extreme inputs to SQL function levenshtein() or levenshtein_less_equal(). Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Integer Overflow or Wraparound
PostgreSQL <18.5 Type Confusion in pg_restore_attribute_stats() risks OS exec
CVE-2026-16238
8.8 - High
- August 13, 2026
Type confusion in PostgreSQL pg_restore_attribute_stats() allows an object creator to execute arbitrary code as the operating system user running the database, via conflation of range and multirange values. Within major version 18, minor versions before PostgreSQL 18.6 are affected. Versions before PostgreSQL 18 are unaffected.
Object Type Confusion
PostgreSQL GSSAPI Integrity Leak in 17/18 (<=17.10,<=18.4)
CVE-2026-14681
4.2 - Medium
- August 13, 2026
Improper enforcement of message integrity in PostgreSQL GSSAPI support allows a user to negotiate GSSAPI contrary to pg_hba.conf rules, via initial direct TLS connection. Despite a pg_hba.conf that appears to require GSSAPI, the connection may exchange data over TLS encryption alone. If the TLS settings are more permissive than the GSS settings, the connection may continue with lesser protection. Within major versions 17-18, minor versions before PostgreSQL 18.6 and 17.11 are affected. Versions before PostgreSQL 17 are unaffected.
Improper Enforcement of Message Integrity During Transmission in a Communication Channel
SQL Injection via EXTRACT() Deparse in PostgreSQL < 18.5
CVE-2026-15741
8.8 - High
- August 13, 2026
SQL injection in PostgreSQL EXTRACT() deparse allows an object owner to execute arbitrary SQL as a superuser via a hostile object definition. Attacks affect expression deparse consumers broadly, including pg_dump, psql commands like \sf, and any similar usage in non-core tools. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
SQL Injection
PostgreSQL 14-18: internal type confusion can execute OS code
CVE-2026-14680
8.8 - High
- August 13, 2026
Type confusion with PostgreSQL "internal" data type arguments allows any user to execute arbitrary code as the operating system user running the database, via calls to functions with that argument type. Type "internal" represents a class of mutually-incompatible data structures not intended for access from SQL. The system intended to prevent such function calls, but this prevention had gaps. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Object Type Confusion
PostgreSQL Buffer OverRead in pg_trgm Index picksplit (18.5)
CVE-2026-14678
4.3 - Medium
- August 13, 2026
Buffer over-read in PostgreSQL pg_trgm index picksplit function reads past end of a heap buffer. This might allow a table maintainer to infer limited memory values, via the lossy signal of index split choices. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Buffer Over-read
PostgreSQL <18.5 ArgNameMatch Stack Buffer Overflow via OUT Param Count
CVE-2026-14679
8.2 - High
- August 13, 2026
Stack buffer overflow in PostgreSQL argument name matching allows an object creator to achieve unknown impacts via OUT parameter count. The attack can write only 0x0 and 0x1 bytes. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Stack Overflow
PostgreSQL 32-bit pltcl/plperl WRAPAROUND (18.5/17.11/16.15/15.19/14.24)
CVE-2026-14677
8.8 - High
- August 13, 2026
Integer wraparound in PostgreSQL 32-bit builds of pltcl and plperl allows an object creator to cause the server to undersize an allocation and write out-of-bounds via crafted function bodies. This may execute arbitrary code as the operating system user running the database. CVE-2026-6473 had fixed similar problems. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Integer Overflow or Wraparound
PostgreSQL 14-18: Untrusted Search Path in amcheck leads to privilege escalation
CVE-2026-14673
3.8 - Low
- August 13, 2026
Untrusted search path in PostgreSQL amcheck allows a grantee of amcheck function EXECUTE privilege to execute arbitrary functions as the owners of expression indexes that depend on the search path, via setting a hostile search path before calling the amcheck function. Within major versions 18, 16, 15, and 14, minor versions before PostgreSQL 18.6, 16.15, 15.19, and 14.24 are affected. PostgreSQL 17 is unaffected.
Untrusted Path
PostgreSQL 18.x (pre18.5) Heap B.O. in pg_stat_statements Enables OS Exec
CVE-2026-14676
8.8 - High
- August 13, 2026
Heap buffer overflow in PostgreSQL pg_stat_statements allows the query author to execute arbitrary code as the operating system user running the database, via crafted queries containing array constants. Within major version 18, minor versions before PostgreSQL 18.6 are affected. Versions before PostgreSQL 18 are unaffected.
Heap-based Buffer Overflow
Heap buffer overflow in PostgreSQL plperl (pre-18.5) allows OS exec
CVE-2026-14670
8.8 - High
- August 13, 2026
Heap buffer overflow in PostgreSQL plperl return of a tied hash allows the function owner to execute arbitrary code as the operating system user running the database, via a crafted function body. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Heap-based Buffer Overflow
PostgreSQL 1618 SCRAM Iteration Count Disclosure via Auth Challenge
CVE-2026-14672
5.3 - Medium
- August 13, 2026
Observable response discrepancy in PostgreSQL SCRAM authentication allows an unauthenticated user to test the existence of a user via observing the SCRAM iteration count. This requires the probed user to have a non-default scram_iterations count, because the authentication challenge for a nonexistent user reports the default scram_iterations. Within major versions 16-18, minor versions before PostgreSQL 18.6, 17.11, and 16.15 are affected. Versions before PostgreSQL 16 are unaffected.
Observable Response Discrepancy
PostgreSQL to_char(timestamptz) Heap Buffer Overflow via TZ before 18.5
CVE-2026-14669
8.8 - High
- August 13, 2026
Heap buffer overflow in PostgreSQL to_char(timestamptz) allows the party choosing the timezone to execute arbitrary code as the operating system user running the database, via a long POSIX timezone abbreviation. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Heap-based Buffer Overflow
PostgreSQL RLS Policy Cache Stale After Role Changes (<18.5/17.11/16.15)
CVE-2026-14666
4.2 - Medium
- August 13, 2026
Incomplete tracking in PostgreSQL of changes to role membership, role attributes, and database ownership allows a query to continue using cached row-level security policies after those changes require a different policy, via plan reuse. Stale policies continue until some other event invalidates the cache or connection termination ends the session. This permits a user to complete reads and modifications that were recently permitted but now forbidden. An attacker must tailor an attack to a particular application's pattern of privilege removal and role-specific row security policies. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Improper Preservation of Consistency Between Independent Representations of Shared State
PostgreSQL ctid estimator type confusion allows memory leakage (before 18.5)
CVE-2026-14668
8.1 - High
- August 13, 2026
Type confusion regarding input of PostgreSQL ctid data type selectivity estimator allows an object creator to view a calculation derived from the value of an arbitrary 4-byte span of memory, via a chosen non-ctid input. While the calculation loses precision, substantial memory value recovery appears possible. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Object Type Confusion
PostgreSQL <18.5 REGEXP Heap Oflow via pg_wchar
CVE-2026-14664
8.8 - High
- August 13, 2026
Heap buffer overflow in PostgreSQL regexp allows the query author to execute arbitrary code as the operating system user running the database, via text that would not pass encoding validation. This shares heritage with CVE-2026-2006, but this case involved unanticipated data growth when round-tripped through pg_wchar. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Heap-based Buffer Overflow
CVE-2026-14662: PostgreSQL tsvector/tsquery OOB pre-18.5/17.11/16.15/15.19/14.24
CVE-2026-14662
8.8 - High
- August 13, 2026
Integer wraparound in PostgreSQL tsvector and tsquery data type functions allows an unprivileged database user to cause the server to undersize an allocation and write out-of-bounds, via crafted large inputs. This may execute arbitrary code as the operating system user running the database. These types are typically sourced from application logic, not taken from the application's user. Hence, application users attacking the database, through the application as a conduit, are unlikely. CVE-2026-6473 had fixed similar problems. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Integer Overflow or Wraparound
PostgreSQL <18.5 PDE: pgcrypto Cleartext Storage via Disabled Cipher
CVE-2026-14663
6.5 - Medium
- August 13, 2026
Cleartext storage in PostgreSQL pgcrypto disabled ciphers allows a user to recover cleartext, via direct observation of the faulty ciphertext. The OpenSSL version and OpenSSL configuration determine the disabled ciphers. If the application accepts encrypted data as input, decryption will succeed even with the wrong key. This in turn loses the modest protection from the Modification Detection Code (MDC). Affected functions are pgp_sym_encrypt, pgp_sym_decrypt, pgp_pub_encrypt, pgp_pub_decrypt, pgp_sym_encrypt_bytea, pgp_sym_decrypt_bytea, pgp_pub_encrypt_bytea, and pgp_pub_decrypt_bytea. Versions before PostgreSQL 18.6, 17.11, 16.15, 15.19, and 14.24 are affected.
Cleartext Storage in a File or on Disk
PostgreSQL <18.4,<17.10,<16.14: SQLi via ALTER SUBSCRIPTION REFRESH PUBLICATION
CVE-2026-6638
3.7 - Low
- May 14, 2026
SQL injection in PostgreSQL logical replication ALTER SUBSCRIPTION ... REFRESH PUBLICATION allows a subscriber table creator to execute arbitrary SQL with the subscription's publication-side credentials. The attack takes effect at the next REFRESH PUBLICATION. Within major versions 16, 17, and 18, minor versions before PostgreSQL 18.4, 17.10, and 16.14 are affected. Versions before PostgreSQL 16 are unaffected.
SQL Injection
PostgreSQL refint stack buffer overflow, <= 18.4
CVE-2026-6637
8.8 - High
- May 14, 2026
Stack buffer overflow in PostgreSQL module "refint" allows an unprivileged database user to execute arbitrary code as the operating system user running the database. A distinct attack is possible if the application declares a user-controlled column as a "refint" cascade primary key and facilitates user-controlled updates to that column. In that case, a SQL injection allows a primary key update value provider to execute arbitrary SQL as the database user performing the primary key update. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.
Stack Overflow
PostgreSQL 18 Buffer Over-Read in pg_restore_attribute_stats() (18.3)
CVE-2026-6575
4.3 - Medium
- May 14, 2026
Buffer over-read in PostgreSQL function pg_restore_attribute_stats() accepts array values of unmatched length, which causes query planning to read past end of one array. This allows a table maintainer to infer memory values past that array end. Within major version 18, minor versions before PostgreSQL 18.4 are affected. Versions before PostgreSQL 18 are unaffected.
Buffer Over-read
PostgreSQL Recursion CVE-2026-6479: SSL/GSS DoS pre-18.4,17.10,16.14,15.18,14.23
CVE-2026-6479
7.5 - High
- May 14, 2026
Uncontrolled recursion in PostgreSQL SSL and GSS negotiation allows an attacker able to connect to a PostgreSQL AF_UNIX socket to achieve sustained denial of service. If SSL and GSS are both disabled, an attacker can do the same via access to a PostgreSQL TCP socket. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.
Stack Exhaustion
PostgreSQL MD5 Timing Channel CVE-2026-6478 (v<18.4/17.10/16.14/15.18/14.23)
CVE-2026-6478
8.2 - High
- May 14, 2026
Covert timing channel in comparison of MD5-hashed password in PostgreSQL authentication allows an attacker to recover user credentials sufficient to authenticate. This does not affect scram-sha-256 passwords, the default in all supported releases. However, current databases may have MD5-hashed passwords originating in upgrades from PostgreSQL 13 or earlier. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.
Covert Timing Channel
PostgreSQL 17.x/18.x SQLi in pg_createsubscriber (17.9/18.3)
CVE-2026-6476
7.2 - High
- May 14, 2026
SQL injection in PostgreSQL pg_createsubscriber allows an attacker with pg_create_subscription rights to execute arbitrary SQL as a superuser. The attack takes effect when pg_createsubscriber next runs. Within major versions 17 and 18, minor versions before PostgreSQL 18.4 and 17.10 are affected. Versions before PostgreSQL 17 are unaffected.
SQL Injection
PostgreSQL libpq PQfn buffer overflow in lo_* before 18.4, 17.10, 16.14, 15.18
CVE-2026-6477
8.4 - High
- May 14, 2026
Use of inherently dangerous function PQfn(..., result_is_int=0, ...) in PostgreSQL libpq lo_export(), lo_read(), lo_lseek64(), and lo_tell64() functions allows the server superuser to overwrite a client stack buffer with an arbitrarily-large response. Like gets(), PQfn(..., result_is_int=0, ...) stores arbitrary-length, server-determined data into a buffer of unspecified size. Because both the \lo_export command in psql and pg_dump call lo_read(), the server superuser can overwrite pg_dump or psql stack memory. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.
Use of Inherently Dangerous Function
PostgreSQL pg_basebackup/pg_rewind SYMLINK overwrite <=18.4/17.10/16.14/15.18/14.23
CVE-2026-6475
8.8 - High
- May 14, 2026
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.
Symlink following
PostgreSQL timeofday() FS Vulnerability (pre-18.4,17.10,16.14,15.18,14.23)
CVE-2026-6474
4.3 - Medium
- May 14, 2026
Externally-controlled format string in PostgreSQL timeofday() function allows an attacker to retrieve portions of server memory, via crafted timezone zones. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.
Use of Externally-Controlled Format String
PostgreSQL <18.4 OOB Integer Wraparound Undersize Allocation
CVE-2026-6473
8.8 - High
- May 14, 2026
Integer wraparound in multiple PostgreSQL server features allows an unprivileged database user to cause the server to undersize an allocation and write out-of-bounds. This may execute arbitrary code as the operating system user running the database. In applications that pass gigabyte-scale user inputs to the relevant database functions, the application input provider may achieve a segmentation fault. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.
Integer Overflow or Wraparound
PostgreSQL 18.4+ Missing Auth in CREATE TYPE (search_path hijack)
CVE-2026-6472
5.4 - Medium
- May 14, 2026
Missing authorization in PostgreSQL CREATE TYPE allows an object creator to hijack other queries that use search_path to find user-defined types, including extension-defined types. That is to say, the victim will execute arbitrary SQL functions of the attacker's choice. Versions before PostgreSQL 18.4, 17.10, 16.14, 15.18, and 14.23 are affected.
AuthZ
PostgreSQL Heap Buffer Overflow in pg_trgm (18.1,18.0)
CVE-2026-2007
8.2 - High
- February 12, 2026
Heap buffer overflow in PostgreSQL pg_trgm allows a database user to achieve unknown impacts via a crafted input string. The attacker has limited control over the byte patterns to be written, but we have not ruled out the viability of attacks that lead to privilege escalation. PostgreSQL 18.1 and 18.0 are affected.
Heap-based Buffer Overflow
PostgreSQL Buffer Overrun via Char Valid. (18.2/17.8/16.12/15.16/14.21)
CVE-2026-2006
8.8 - High
- February 12, 2026
Missing validation of multibyte character length in PostgreSQL text manipulation allows a database user to issue crafted queries that achieve a buffer overrun. That suffices to execute arbitrary code as the operating system user running the database. Versions before PostgreSQL 18.2, 17.8, 16.12, 15.16, and 14.21 are affected.
out-of-bounds array index
Heap Buffer Overflow in PostgreSQL pgcrypto (pre 18.2/17.8/16.12/15.16/14.21) OS Exploit
CVE-2026-2005
8.8 - High
- February 12, 2026
Heap buffer overflow in PostgreSQL pgcrypto allows a ciphertext provider to execute arbitrary code as the operating system user running the database. Versions before PostgreSQL 18.2, 17.8, 16.12, 15.16, and 14.21 are affected.
Heap-based Buffer Overflow
PostgreSQL intarray RCE before 18.2/17.8/16.12/15.16/14.21
CVE-2026-2004
8.8 - High
- February 12, 2026
Missing validation of type of input in PostgreSQL intarray extension selectivity estimator function allows an object creator to execute arbitrary code as the operating system user running the database. Versions before PostgreSQL 18.2, 17.8, 16.12, 15.16, and 14.21 are affected.
Improper Validation of Specified Type of Input
PostgreSQL <18.2 Improper oidvector Validation Server Memory Disclosure
CVE-2026-2003
4.3 - Medium
- February 12, 2026
Improper validation of type "oidvector" in PostgreSQL allows a database user to disclose a few bytes of server memory. We have not ruled out viability of attacks that arrange for presence of confidential information in disclosed bytes, but they seem unlikely. Versions before PostgreSQL 18.2, 17.8, 16.12, 15.16, and 14.21 are affected.
Improper Validation of Specified Type of Input
PostgreSQL libpq Int Wraparound OOB Allocation 13-17 Pre-18.1
CVE-2025-12818
5.9 - Medium
- November 13, 2025
Integer wraparound in multiple PostgreSQL libpq client library functions allows an application input provider or network peer to cause libpq to undersize an allocation and write out-of-bounds by hundreds of megabytes. This results in a segmentation fault for the application using libpq. Versions before PostgreSQL 18.1, 17.7, 16.11, 15.15, 14.20, and 13.23 are affected.
Integer Overflow or Wraparound
PostgreSQL CREATE STATISTICS Auth Bypass Causing DoS 18.1
CVE-2025-12817
3.1 - Low
- November 13, 2025
Missing authorization in PostgreSQL CREATE STATISTICS command allows a table owner to achieve denial of service against other CREATE STATISTICS users by creating in any schema. A later CREATE STATISTICS for the same name, from a user having the CREATE privilege, would then fail. Versions before PostgreSQL 18.1, 17.7, 16.11, 15.15, 14.20, and 13.23 are affected.
AuthZ
PostgreSQL <=16.10 / <=17.6 Optimizer Stats leak VIEW & RLS
CVE-2025-8713
- August 14, 2025
PostgreSQL optimizer statistics allow a user to read sampled data within a view that the user cannot access. Separately, statistics allow a user to read sampled data that a row security policy intended to hide. PostgreSQL maintains statistics for tables by sampling data available in columns; this data is consulted during the query planning process. Prior to this release, a user could craft a leaky operator that bypassed view access control lists (ACLs) and bypassed row security policies in partitioning or table inheritance hierarchies. Reachable statistics data notably included histograms and most-common-values lists. CVE-2017-7484 and CVE-2019-10130 intended to close this class of vulnerability, but this gap remained. Versions before PostgreSQL 17.6, 16.10, 15.14, 14.19, and 13.22 are affected.
CVE-2025-8715: pg_dump Newline Code Injection (PG <17.6, <16.10, <15.14, <14.19, <13.22)
CVE-2025-8715
- August 14, 2025
Improper neutralization of newlines in pg_dump in PostgreSQL allows a user 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 meta-commands inside a purpose-crafted object name. The same attacks can achieve SQL injection as a superuser of the restore target server. pg_dumpall, pg_restore, and pg_upgrade are also affected. Versions before PostgreSQL 17.6, 16.10, 15.14, 14.19, and 13.22 are affected. Versions before 11.20 are unaffected. CVE-2012-0868 had fixed this class of problem, but version 11.20 reintroduced it.
PostgreSQL < 17.6: pg_dump Untrusted Data Inclusion Exec Vulnerability
CVE-2025-8714
- August 14, 2025
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 meta-commands. pg_dumpall is also affected. pg_restore is affected when used to generate a plain-format dump. This is similar to MySQL CVE-2024-21096. Versions before PostgreSQL 17.6, 16.10, 15.14, 14.19, and 13.22 are affected.
Plain Text Credentials Stored in Local PostgreSQL Database
CVE-2025-1709
- July 03, 2025
Several credentials for the local PostgreSQL database are stored in plain text (partially base64 encoded).
Stay on top of Security Vulnerabilities
Want an email whenever new vulnerabilities are published for PostgreSQL or by PostgreSQL? Click the Watch button to subscribe.