PostgreSQL news/PostgreSQL newsen-usThu, 13 Feb 2025 00:00:00 +0000PostgreSQL 17.3, 16.7, 15.11, 14.16, and 13.19 Released! /about/news/postgresql-173-167-1511-1416-and-1319-released-3015/ <p>The PostgreSQL Global Development Group has released an update to all supported versions of PostgreSQL, including 17.3, 16.7, 15.11, 14.16, and 13.19. This release fixes 1 security vulnerability and over 70 bugs reported over the last several months.</p> <p>For the full list of changes, please review the <a href="/docs/release/">release notes</a>.</p> <h2>Security Issues</h2> <h3><a href="/support/security/CVE-2025-1094/">CVE-2025-1094</a>: PostgreSQL quoting APIs miss neutralizing quoting syntax in text that fails encoding validation</h3> <p>CVSS v3.1 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?version=3.1&amp;vector=AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H">8.1</a></p> <p>Supported, Vulnerable Versions: 13 - 17. </p> <p>Improper neutralization of quoting syntax in PostgreSQL <a href="/docs/current/libpq.html"><code>libpq</code></a> functions <code>PQescapeLiteral()</code>, <code>PQescapeIdentifier()</code>, <code>PQescapeString()</code>, and <code>PQescapeStringConn()</code> allows a database input provider to achieve SQL injection in certain usage patterns. Specifically, SQL injection requires the application to use the function result to construct input to psql, the PostgreSQL interactive terminal. Similarly, improper neutralization of quoting syntax in PostgreSQL command line utility programs allows a source of command line arguments to achieve SQL injection when <a href="/docs/current/runtime-config-client.html#GUC-CLIENT-ENCODING"><code>client_encoding</code></a> is <code>BIG5</code> and <a href="/docs/current/runtime-config-preset.html#GUC-SERVER-ENCODING"><code>server_encoding</code></a> is one of <code>EUC_TW</code> or <code>MULE_INTERNAL</code>. Versions before PostgreSQL 17.3, 16.7, 15.11, 14.16, and 13.19 are affected.</p> <p>The PostgreSQL project thanks Stephen Fewer, Principal Security Researcher, Rapid7 for reporting this problem.</p> <h2>Bug Fixes and Improvements</h2> <p>This update fixes over 70 bugs that were reported in the last several months. The issues listed below affect PostgreSQL 17. Some of these issues may also affect other supported versions of PostgreSQL.</p> <ul> <li>Restore pre-v17 truncation behavior for &gt;63-byte database names and usernames in connection requests.</li> <li>Don't perform connection privilege checks and limits on parallel workers, and instead inherit these from the leader process.</li> <li>Remove <code>Lock</code> suffix from <code>LWLock</code> wait event names. </li> <li>Fix possible re-use of stale results in window aggregates, which could lead to incorrect results.</li> <li>Several race condition fixes for <a href="/docs/current/sql-vacuum.html">vacuum</a> that in the worst case could cause corruption to a system catalog.</li> <li>Several fixes for <a href="/docs/current/sql-truncate.html">truncating</a> tables and indexes that prevent potential corruption.</li> <li>Fix for detaching a partition where its own foreign-key constraint references a partitioned table.</li> <li>Fix for the <code>FFn</code> (e.g., <code>FF1</code>) format codes for <code>to_timestamp</code>, where an integer format code before the <code>FFn</code> would consume all available digits.</li> <li>Fixes for SQL/JSON and <code>XMLTABLE()</code> to double-quote specific entries when necessary.</li> <li>Include the <code>ldapscheme</code> option in <a href="/docs/current/view-pg-hba-file-rules.html"><code>pg_hba_file_rules()</code></a>.</li> <li>Several fixes for <a href="/docs/current/queries-union.html"><code>UNION</code></a>, including not merging columns with non-compatible collations.</li> <li>Several fixes that could impact availability or speed of starting a connection to PostgreSQL.</li> <li>Fix multiple memory leaks in logical decoding output.</li> <li>Fix several memory leaks in <a href="/docs/current/plpython.html">PL/Python</a>.</li> <li>Add psql tab completion for <a href="/docs/current/sql-copy.html"><code>COPY (MERGE INTO)</code></a>.</li> <li>Make <a href="/docs/current/app-pgcontroldata.html"><code>pg_controldata</code></a> more resilient when displaying info from corrupted<a href="/docs/current/wal-internals.html">pg_control</a> files.</li> <li>Fix for a memory leak in <a href="/docs/current/app-pgrestore.html"><code>pg_restore</code></a> with zstd-compressed data.</li> <li>Fix <a href="/docs/current/app-pgbasebackup.html"><code>pg_basebackup</code></a> to correctly handle pg_wal.tar files exceeding 2GB on Windows.</li> <li>Modify <a href="/docs/current/earthdistance.html">earthdistance</a> to use SQL-standard function bodies, which fixes possible issues with major version upgrades to v17 when databases use this extension.</li> <li>Fix crash in <a href="/docs/current/pageinspect.html">pageinspect</a> in instances where the <code>brin_page_items()</code> function definition is not updated to the latest version.</li> <li>Fix race condition when trying to cancel a <a href="/docs/current/postgres-fdw.html"><code>postgres_fdw</code></a> remote query.</li> </ul> <p>This release also updates time zone data files to tzdata release 2025a for DST law changes in Paraguay, plus historical corrections for the Philippines.</p> <h2>Updating</h2> <p>All PostgreSQL update releases are cumulative. As with other minor releases, users are not required to dump and reload their database or use <code>pg_upgrade</code> in order to apply this update release; you may simply shutdown PostgreSQL and update its binaries.</p> <p>Users who have skipped one or more update releases may need to run additional post-update steps; please see the release notes from earlier versions for details.</p> <p>For more details, please see the <a href="/docs/release/">release notes</a>.</p> <h2>Links</h2> <ul> <li><a href="/download/">Download</a></li> <li><a href="/docs/release/">Release Notes</a></li> <li><a href="/support/security/">Security</a></li> <li><a href="/support/versioning/">Versioning Policy</a></li> <li><a href="/about/donate/">Donate</a></li> </ul> <p>If you have corrections or suggestions for this release announcement, please send them to the <em>pgsql-www@lists.postgresql.org</em> public <a href="/list/">mailing list</a>.</p> Thu, 13 Feb 2025 00:00:00 +0000/about/news/postgresql-173-167-1511-1416-and-1319-released-3015/PostgreSQL 17.2, 16.6, 15.10, 14.15, 13.18, and 12.22 Released! /about/news/postgresql-172-166-1510-1415-1318-and-1222-released-2965/ <p>The PostgreSQL Global Development Group has released an update to all supported versions of PostgreSQL, including 17.2, 16.6, 15.10, 14.15, and 13.18. Additionally, due to the nature of one of the issues in the <a href="/about/news/out-of-cycle-release-scheduled-for-november-21-2024-2958/">previous update release</a>, the PostgreSQL Global Development Group is also releasing a 12.22 release for PostgreSQL 12. PostgreSQL 12 is now EOL and will not receive more fixes.</p> <p>For the full list of changes, please review the <a href="/docs/release/">release notes</a>.</p> <h2>PostgreSQL 12 EOL Notice</h2> <p><strong>This is the final release of PostgreSQL 12</strong>. PostgreSQL 12 is now end-of-life and will no longer receive security and bug fixes. If you are running PostgreSQL 12 in a production environment, we suggest that you make plans to upgrade to a newer, supported version of PostgreSQL. Please see our <a href="/support/versioning/">versioning policy</a> for more information.</p> <h2>Bug Fixes and Improvements</h2> <p>The issues listed below affect PostgreSQL 17. Some of these issues may also affect other supported versions of PostgreSQL.</p> <ul> <li>Restore functionality of <a href="/docs/current/sql-alterrole.html"><code>ALTER ROLE .. SET ROLE</code></a> and <a href="/docs/current/sql-alterdatabase.html"><code>ALTER DATABASE .. SET ROLE</code></a>. The fix for <a href="/support/security/CVE-2024-10978/">CVE-2024-10978</a> accidentally caused settings for role to not be applied if they came from non-interactive sources, including previous <code>ALTER {ROLE|DATABASE}</code> commands and the <a href="/docs/current/libpq-envars.html"><code>PGOPTIONS</code></a> environment variable.</li> <li>Restore compatibility for the <code>timescaledb</code> and other PostgreSQL extensions built using PostgreSQL prior to the 2024-11-14 release (17.0, 16.4, 15.8, 14.13, 13.16, 12.20, and earlier). This fix restores <code>struct ResultRelInfo</code> to its previous size, so that affected extensions don't need to be rebuilt.</li> <li>Fix cases where a logical replication slot's <code>restart_lsn</code> could go backwards.</li> <li>Avoid deleting still-needed WAL files during <a href="/docs/current/app-pgrewind.html"><code>pg_rewind</code></a>.</li> <li>Fix race conditions associated with dropping shared statistics entries, which could lead to loss of statistics data.</li> <li>Fix crash with <code>ALTER TABLE</code> when checking to see if an index's opclass options have changed if the table has an index with a non-default operator class.</li> </ul> <h2>Updating</h2> <p>All PostgreSQL update releases are cumulative. As with other minor releases, users are not required to dump and reload their database or use <code>pg_upgrade</code> in order to apply this update release; you may simply shutdown PostgreSQL and update its binaries.</p> <p>Users who have skipped one or more update releases may need to run additional post-update steps; please see the release notes from earlier versions for details.</p> <p>For more details, please see the <a href="/docs/release/">release notes</a>.</p> <h2>Links</h2> <ul> <li><a href="/download/">Download</a></li> <li><a href="/docs/release/">Release Notes</a></li> <li><a href="/support/security/">Security</a></li> <li><a href="/support/versioning/">Versioning Policy</a></li> <li><a href="https://twitter.com/postgresql">Follow @postgresql on X/Twitter</a></li> <li><a href="/about/donate/">Donate</a></li> </ul> <p>If you have corrections or suggestions for this release announcement, please send them to the <em>pgsql-www@lists.postgresql.org</em> public <a href="/list/">mailing list</a>.</p> Thu, 21 Nov 2024 00:00:00 +0000/about/news/postgresql-172-166-1510-1415-1318-and-1222-released-2965/PostgreSQL 17.1, 16.5, 15.9, 14.14, 13.17, and 12.21 Released! /about/news/postgresql-171-165-159-1414-1317-and-1221-released-2955/ <p>The PostgreSQL Global Development Group has released an update to all supported versions of PostgreSQL, including 17.1, 16.5, 15.9, 14.14, 13.17, and 12.21. This release fixes 4 security vulnerabilities and over 35 bugs reported over the last several months.</p> <p>For the full list of changes, please review the <a href="/docs/release/">release notes</a>.</p> <h2>PostgreSQL 12 EOL Notice</h2> <p><strong>This is the final release of PostgreSQL 12</strong>. PostgreSQL 12 is now end-of-life and will no longer receive security and bug fixes. If you are running PostgreSQL 12 in a production environment, we suggest that you make plans to upgrade to a newer, supported version of PostgreSQL. Please see our <a href="/support/versioning/">versioning policy</a> for more information.</p> <h2>Security Issues</h2> <h3><a href="/support/security/CVE-2024-10976/">CVE-2024-10976</a>: PostgreSQL row security below e.g. subqueries disregards user ID changes</h3> <p>CVSS v3.1 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?version=3.1&amp;vector=AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:N">4.2</a></p> <p>Supported, Vulnerable Versions: 12 - 17.</p> <p>Incomplete tracking in PostgreSQL of tables with row security allows a reused query to view or change different rows from those intended. <a href="/support/security/CVE-2023-2455/">CVE-2023-2455</a> and <a href="/support/security/CVE-2016-2193/">CVE-2016-2193</a> fixed most interaction between row security and user ID changes. They missed cases where a subquery, WITH query, security invoker view, or SQL-language function references a table with a row-level security policy. This has the same consequences as the two earlier CVEs. That is to say, it leads to potentially incorrect policies being applied in cases where role-specific policies are used and a given query is planned under one role and then executed under other roles. This scenario can happen under security definer functions or when a common user and query is planned initially and then re-used across multiple SET ROLEs.</p> <p>Applying an incorrect policy may permit a user to complete otherwise-forbidden reads and modifications. This affects only databases that have used <a href="/docs/current/sql-createpolicy.html"><code>CREATE POLICY</code></a> to define a row security policy. An attacker must tailor an attack to a particular application's pattern of query plan reuse, user ID changes, and role-specific row security policies. Versions before PostgreSQL 17.1, 16.5, 15.9, 14.14, 13.17, and 12.21 are affected.</p> <p>The PostgreSQL project thanks Wolfgang Walther for reporting this problem.</p> <h3><a href="/support/security/CVE-2024-10977/">CVE-2024-10977</a>: PostgreSQL libpq retains an error message from man-in-the-middle</h3> <p>CVSS v3.1 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?version=3.1&amp;vector=AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N">3.1</a></p> <p>Supported, Vulnerable Versions: 12 - 17.</p> <p>Client use of server error message in PostgreSQL allows a server not trusted under current SSL or GSS settings to furnish arbitrary non-NUL bytes to the libpq application. For example, a man-in-the-middle attacker could send a long error message that a human or screen-scraper user of psql mistakes for valid query results. This is probably not a concern for clients where the user interface unambiguously indicates the boundary between one error message and other text. Versions before PostgreSQL 17.1, 16.5, 15.9, 14.14, 13.17, and 12.21 are affected.</p> <p>The PostgreSQL project thanks Jacob Champion for reporting this problem.</p> <h3><a href="/support/security/CVE-2024-10978/">CVE-2024-10978</a>: PostgreSQL SET ROLE, SET SESSION AUTHORIZATION reset to wrong user ID</h3> <p>CVSS v3.1 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?version=3.1&amp;vector=AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:N">4.2</a></p> <p>Supported, Vulnerable Versions: 12 - 17.</p> <p>Incorrect privilege assignment in PostgreSQL allows a less-privileged application user to view or change different rows from those intended. An attack requires the application to use <a href="/docs/current/sql-set-role.html"><code>SET ROLE</code></a>, <a href="/docs/current/sql-set-session-authorization.html"><code>SET SESSION AUTHORIZATION</code></a>, or an equivalent feature. The problem arises when an application query uses parameters from the attacker or conveys query results to the attacker. If that query reacts to <code>current_setting('role')</code> or the current user ID, it may modify or return data as though the session had not used <code>SET ROLE</code> or <code>SET SESSION AUTHORIZATION</code>. The attacker does not control which incorrect user ID applies. Query text from less-privileged sources is not a concern here, because <code>SET ROLE</code> and <code>SET SESSION AUTHORIZATION</code> are not sandboxes for unvetted queries. Versions before PostgreSQL 17.1, 16.5, 15.9, 14.14, 13.17, and 12.21 are affected.</p> <p>The PostgreSQL project thanks Tom Lane for reporting this problem.</p> <h3><a href="/support/security/CVE-2024-10979/">CVE-2024-10979</a>: PostgreSQL PL/Perl environment variable changes execute arbitrary code</h3> <p>CVSS v3.1 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?version=3.1&amp;vector=AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H">8.8</a></p> <p>Supported, Vulnerable Versions: 12 - 17.</p> <p>Incorrect control of environment variables in PostgreSQL <a href="/docs/current/plperl.html">PL/Perl</a> allows an unprivileged database user to change sensitive process environment variables (e.g. <code>PATH</code>). That often suffices to enable arbitrary code execution, even if the attacker lacks a database server operating system user. Versions before PostgreSQL 17.1, 16.5, 15.9, 14.14, 13.17, and 12.21 are affected.</p> <p>The PostgreSQL project thanks Coby Abrams for reporting this problem.</p> <h2>Bug Fixes and Improvements</h2> <p>This update fixes over 35 bugs that were reported in the last several months. The issues listed below affect PostgreSQL 17. Some of these issues may also affect other supported versions of PostgreSQL.</p> <ul> <li>Fix when attaching or detaching table partitions with foreign key constraints. After upgrade, users impacted by this issue will need to perform manual steps to finish fixing it. Please see the "Upgrading" section and the release notes for more information.</li> <li>Fix when using libc as the default collation provider when <code>LC_CTYPE</code> is <code>C</code> while <code>LC_COLLATE</code> is a different locale. This could lead to incorrect query results. If you have these settings in your database, please reindex any affected indexes after updating to this release. This issue impacted 17.0 only.</li> <li>Several query planner fixes, including disallowing joining partitions (<a href="/docs/current/runtime-config-query.html#GUC-ENABLE-PARTITIONWISE-JOIN">partitionwise join</a>) if the collations of the partitions don't match.</li> <li>Fix possible wrong answers or <code>wrong varnullingrels</code> planner errors for <a href="/docs/current/sql-merge.html"><code>MERGE ... WHEN NOT MATCHED BY SOURCE</code></a> actions.</li> <li>Fix validation of the <a href="/docs/current/sql-copy.html"><code>COPY</code></a> <code>FORCE_NOT_NULL</code> and <code>FORCE_NULL</code>.</li> <li>Fix server crash when a <a href="/docs/current/functions-aggregate.html"><code>json_objectagg()</code></a> call contains a volatile function.</li> <li>Ensure there's a registered dependency between a partitioned table and a non-built-in access method specified in <code>CREATE TABLE ... USING</code>. This fix only prevents problems for partitioned tables created after this update.</li> <li>Fix race condition in committing a serializable transaction.</li> <li>Fix race condition in <a href="/docs/current/sql-commit-prepared.html"><code>COMMIT PREPARED</code></a> that could require manual file removal after a crash-and-recovery.</li> <li>Fix for <a href="/docs/current/view-pg-cursors.html"><code>pg_cursors</code></a> view to prevent errors by excluding cursors that aren't completely set up.</li> <li>Reduce logical decoding memory consumption.</li> <li>Fix to prevent stable functions from receiving stale row values when they're called from a <a href="/docs/current/sql-call.html"><code>CALL</code></a> statement's argument list and the <code>CALL</code> is within a <a href="/docs/current/plpgsql-control-structures.html#PLPGSQL-ERROR-TRAPPING">PL/pgSQL <code>EXCEPTION</code></a> block.</li> <li>Fix for JIT crashes on ARM (aarch64) systems.</li> <li>The <code>psql</code> <code>\watch</code> now treats values that are less than 1ms to be 0 (no wait between executions).</li> <li>Fix failure to use credentials for a replication user in the <a href="/docs/current/libpq-pgpass.html">password file</a> (<a href="/docs/current/libpq-pgpass.html"><code>pgpass</code></a>)</li> <li><a href="/docs/current/app-pgcombinebackup.html"><code>pg_combinebackup</code></a> now throws an error if an incremental backup file is present in a directory that should contain a full backup.</li> <li>Fix to avoid reindexing temporary tables and indexes in <a href="/docs/current/app-vacuumdb.html"><code>vacuumdb</code></a> and parallel <a href="/docs/current/app-reindexdb.html"><code>reindexdb</code></a>.</li> </ul> <p>This release also updates time zone data files to tzdata release 2024b. This tzdata release changes the old System-V-compatibility zone names to duplicate the corresponding geographic zones; for example <code>PST8PDT</code> is now an alias for <code>America/Los_Angeles</code>. The main visible consequence is that for timestamps before the introduction of standardized time zones, the zone is considered to represent local mean solar time for the named location. For example, in <code>PST8PDT</code>, timestamptz input such as 1801-01-01 00:00 would previously have been rendered as <code>1801-01-01 00:00:00-08</code>, but now it is rendered as <code>1801-01-01 00:00:00-07:52:58</code>.</p> <p>Also, historical corrections for Mexico, Mongolia, and Portugal. Notably, Asia/Choibalsan is now an alias for Asia/Ulaanbaatar rather than being a separate zone, mainly because the differences between those zones were found to be based on untrustworthy data. </p> <h2>Updating</h2> <p>All PostgreSQL update releases are cumulative. As with other minor releases, users are not required to dump and reload their database or use <code>pg_upgrade</code> in order to apply this update release; you may simply shutdown PostgreSQL and update its binaries.</p> <p>If you have a partitioned table with foreign key constraints where you've run the <code>ATTACH PARTITION</code>/<code>DETACH PARTITION</code> commands, you will need to take further steps after upgrading. You can fix this by executing an <a href="/docs/current/sql-altertable.html"><code>ALTER TABLE ... DROP CONSTRAINT</code></a> on the now stand-alone table for each faulty constraint, and then re-add the constraint. If re-adding the constraint fails, you will need to manually re-establish consistency between the referencing and referenced tables, then re-add the constraint.</p> <p>This query can be used to identify broken constraints and construct the commands needed to recreate them:</p> <p><code>SELECT conrelid::pg_catalog.regclass AS "constrained table", conname AS constraint, confrelid::pg_catalog.regclass AS "references", pg_catalog.format('ALTER TABLE %s DROP CONSTRAINT %I;', conrelid::pg_catalog.regclass, conname) AS "drop", pg_catalog.format('ALTER TABLE %s ADD CONSTRAINT %I %s;', conrelid::pg_catalog.regclass, conname, pg_catalog.pg_get_constraintdef(oid)) AS "add" FROM pg_catalog.pg_constraint c WHERE contype = 'f' AND conparentid = 0 AND (SELECT count(*) FROM pg_catalog.pg_constraint c2 WHERE c2.conparentid = c.oid) &lt;&gt; (SELECT count(*) FROM pg_catalog.pg_inherits i WHERE (i.inhparent = c.conrelid OR i.inhparent = c.confrelid) AND EXISTS (SELECT 1 FROM pg_catalog.pg_partitioned_table WHERE partrelid = i.inhparent));</code></p> <p>Since it is possible that one or more of the <code>ADD CONSTRAINT</code> steps will fail, you should save the query's output in a file and then attempt to perform each step.</p> <p>Additionally, if you are running PostgreSQL 17.0 and using libc as your default collation provider, and have set <code>LC_CTYPE</code> to be <code>C</code> while <code>LC_COLLATE</code> is a different locale, you will need to rebuild your text-based indexes. You can do this with the <a href="/docs/current/sql-reindex.html"><code>REINDEX INDEX CONCURRENTLY</code></a> command.</p> <p>Users who have skipped one or more update releases may need to run additional post-update steps; please see the release notes from earlier versions for details.</p> <p>For more details, please see the <a href="/docs/release/">release notes</a>.</p> <h2>Links</h2> <ul> <li><a href="/download/">Download</a></li> <li><a href="/docs/release/">Release Notes</a></li> <li><a href="/support/security/">Security</a></li> <li><a href="/support/versioning/">Versioning Policy</a></li> <li><a href="https://twitter.com/postgresql">Follow @postgresql on X/Twitter</a></li> <li><a href="/about/donate/">Donate</a></li> </ul> <p>If you have corrections or suggestions for this release announcement, please send them to the <em>pgsql-www@lists.postgresql.org</em> public <a href="/list/">mailing list</a>.</p> Thu, 14 Nov 2024 00:00:00 +0000/about/news/postgresql-171-165-159-1414-1317-and-1221-released-2955/PostgreSQL 16.4, 15.8, 14.13, 13.16, 12.20, and 17 Beta 3 Released! /about/news/postgresql-164-158-1413-1316-1220-and-17-beta-3-released-2910/ <p>The PostgreSQL Global Development Group has released an update to all supported versions of PostgreSQL, including 16.4, 15.8, 14.13, 13.16, and 12.20, as well as the third beta release of PostgreSQL 17. This release fixes 1 security vulnerability and over 55 bugs reported over the last several months.</p> <p>For the full list of changes, please review the <a href="/docs/release/">release notes</a>.</p> <h2>PostgreSQL 12 EOL Notice</h2> <p>PostgreSQL 12 will stop receiving fixes on November 14, 2024. If you are running PostgreSQL 12 in a production environment, we suggest that you make plans to upgrade to a newer, supported version of PostgreSQL. Please see our <a href="/support/versioning/">versioning policy</a> for more information.</p> <h2>Security Issues</h2> <h3><a href="/support/security/CVE-2024-7348/">CVE-2024-7348</a>: PostgreSQL relation replacement during pg_dump executes arbitrary SQL</h3> <p>CVSS v3.1 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?vector=AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H">8.8</a></p> <p>Supported, Vulnerable Versions: 12 - 16.</p> <p>An attacker able to create and drop non-temporary objects could inject SQL code that would be executed by a concurrent <a href="/docs/current/app-pgdump.html"><code>pg_dump</code></a> session with the privileges of the role running <code>pg_dump</code> (which is often a superuser). The attack involves replacing a sequence or similar object with a view or foreign table that will execute malicious code. To prevent this, introduce a new server parameter <code>restrict_nonsystem_relation_kind</code> that can disable expansion of non-builtin views as well as access to foreign tables, and teach <code>pg_dump</code> to set it when available. Note that the attack is prevented only if both <code>pg_dump</code> and the server it is dumping from are new enough to have this fix.</p> <p>The PostgreSQL project thanks Noah Misch for reporting this problem.</p> <h2>Bug Fixes and Improvements</h2> <p>This update fixes over 55 bugs that were reported in the last several months. The issues listed below affect PostgreSQL 16. Some of these issues may also affect other supported versions of PostgreSQL.</p> <ul> <li>Avoid incorrect results from "Merge Right Anti Join" plans, where if the inner relation is known to have unique join keys, the merge could misbehave when there are duplicated join keys in the outer relation.</li> <li>Prevent infinite loop in <a href="/docs/current/sql-vacuum.html"><code>VACUUM</code></a>.</li> <li>Fix partition pruning setup during <a href="/docs/current/sql-altertable.html"><code>ALTER TABLE DETACH ... PARTITION CONCURRENTLY</code></a>.</li> <li>Fix behavior of stable functions that are used as an argument to a <a href="/docs/current/sql-call.html"><code>CALL</code></a> statement.</li> <li><code>pg_sequence_last_value()</code> now returns <code>NULL</code> instead of throwing an error when called on unlogged sequences on standby servers and on temporary sequences of other sessions.</li> <li>Fix parsing of ignored operators in <code>websearch_to_tsquery()</code>.</li> <li>Correctly check updatability of view columns targeted by <a href="/docs/current/sql-insert.html"><code>INSERT ... DEFAULT</code></a>.</li> <li>Lock owned sequences during <a href="/docs/current/sql-altertable.html"><code>ALTER TABLE ... SET LOGGED|UNLOGGED</code></a>.</li> <li>Don't throw an error if a queued <code>AFTER</code> trigger no longer exists.</li> <li>Fix selection of an arbiter index for <a href="/docs/current/sql-insert.html"><code>INSERT ... ON CONFLICT</code></a> when the desired index has expressions or predicates, for example, through an updatable view.</li> <li>Refuse to modify a temporary table of another session with <a href="/docs/current/sql-altertable.html"><code>ALTER TABLE</code></a>.</li> <li>Fix handling of extended statistics on expressions in <a href="/docs/current/sql-createtable.html"><code>CREATE TABLE ... LIKE STATISTICS</code></a>.</li> <li>Fix failure to recalculate sub-queries generated from <code>MIN()</code> or <code>MAX()</code> aggregates.</li> <li>Disallow underscores in positional parameters.</li> <li>Avoid crashing when a JIT-inlined backend function throws an error.</li> <li>Fix handling of subtransactions of prepared transactions when starting a hot standby server.</li> <li>Prevent incorrect initialization of logical replication slots.</li> <li>Fix memory leak in the logical replication WAL sender when publishing changes to a partitioned table whose partitions have row types that are physically different from the table.</li> <li>Disable creation of stateful TLS session tickets by OpenSSL.</li> <li>Fix how <a href="/docs/current/plpgsql.html">PL/pgSQL</a> handles integer ranges containing underscores (e.g., <code>FOR i IN 1_001..1_002</code>).</li> <li>Fix incompatibility between <a href="/docs/current/plperl.html">PL/Perl</a> and Perl 5.40.</li> <li>Several fixes related to recursive <a href="/docs/current/plpython.html">PL/Python</a> functions and triggers.</li> <li>Ensure that <a href="/docs/current/app-pgrestore.html"><code>pg_restore -l</code></a> reports dependent table of contents entries correctly.</li> <li><a href="/docs/current/pgstatstatements.html"><code>pg_stat_statements</code></a> now passes a query ID for utility (non-<code>SELECT</code>/<code>INSERT</code>/<code>UPDATE</code>) statements that appears in SQL-language functions.</li> <li>Fix for <a href="/docs/current/postgres-fdw.html"><code>postgres_fdw</code></a> when mapping a foreign table to a nontrivial remote view.</li> <li><a href="/docs/current/postgres-fdw.html"><code>postgres_fdw</code></a> no longer sends a <code>FETCH FIRST WITH TIES</code> clause to a remote server.</li> </ul> <h2>Updating</h2> <p>All PostgreSQL update releases are cumulative. As with other minor releases, users are not required to dump and reload their database or use <code>pg_upgrade</code> in order to apply this update release; you may simply shutdown PostgreSQL and update its binaries.</p> <p>Users who have skipped one or more update releases may need to run additional post-update steps; please see the release notes from earlier versions for details.</p> <p>For more details, please see the <a href="/docs/release/">release notes</a>.</p> <h2>A Note on the PostgreSQL 17 Beta</h2> <p>This release marks the third beta release of PostgreSQL 17 and puts the community one step closer to general availability tentatively around the end of the third quarter.</p> <p>In the spirit of the open source PostgreSQL community, we strongly encourage you to test the new features of PostgreSQL 17 on your systems to help us eliminate bugs or other issues that may exist. While we do not advise you to run PostgreSQL 17 Beta 3 in production environments, we encourage you to find ways to run your typical application workloads against this beta release.</p> <p>Your testing and feedback will help the community ensure that the PostgreSQL 17 release upholds our standards of delivering a stable, reliable release of the world's most advanced open source relational database. Please read more about our <a href="/developer/beta/">beta testing process</a> and how you can contribute:</p> <p><a href="/developer/beta/">/developer/beta/</a></p> <h2>Upgrading to PostgreSQL 17 Beta 3</h2> <p>To upgrade to PostgreSQL 17 Beta 3 from an earlier version of PostgreSQL, you will need to use a strategy similar to upgrading between major versions of PostgreSQL (e.g. <code>pg_upgrade</code> or <code>pg_dump</code> / <code>pg_restore</code>). For more information, please visit the documentation section on <a href="/docs/17/static/upgrading.html">upgrading</a>.</p> <h2>Changes Since Beta 2</h2> <p>Fixes and changes in PostgreSQL 17 Beta 3 include:</p> <ul> <li>Rename the <code>standby_slot_names</code> parameter to to <code>synchronized_standby_slots</code>.</li> <li>Several SQL/JSON fixes.</li> <li>Fix <code>pg_combinebackup --clone</code>.</li> <li>Fix <code>pg_createsubscriber</code> to work for database names that contain a space.</li> <li><code>pg_createsubscriber</code> now drops pre-existing subscriptions when run on a target database.</li> <li>Improve efficiency in retrieving subscription information during <code>pg_upgrade</code>.</li> <li>Fix TLS fallback behavior during <code>sslmode=prefer</code> to error when a server sends an error during the startup process.</li> <li>Document an error case with <code>pg_basebackup</code> incremental backup on a standby server when it's executed immediately after the previous backup.</li> <li>Fix issue where <code>pg_upgrade --transaction-size</code> can cause the backend to use an order of magnitude more RAM.</li> </ul> <p>Please see the <a href="/docs/17/release-17.html">release notes</a> for a complete list of new and changed features, and <a href="https://wiki.postgresql.org/wiki/PostgreSQL_17_Open_Items">PostgreSQL 17 open items</a> for more details on fixes and changes.</p> <h2>Testing for Bugs &amp; Compatibility</h2> <p>The stability of each PostgreSQL release greatly depends on you, the community, to test the upcoming version with your workloads and testing tools in order to find bugs and regressions before the general availability of PostgreSQL 17. As this is a Beta, minor changes to database behaviors, feature details, and APIs are still possible. Your feedback and testing will help determine the final tweaks on the new features, so please test in the near future. The quality of user testing helps determine when we can make a final release.</p> <p>A list of <a href="https://wiki.postgresql.org/wiki/PostgreSQL_17_Open_Items">open issues</a> is publicly available in the PostgreSQL wiki. You can <a href="/account/submitbug/">report bugs</a> using this form on the PostgreSQL website:</p> <p><a href="/account/submitbug/">/account/submitbug/</a></p> <h2>Links</h2> <ul> <li><a href="/download/">Download</a></li> <li><a href="/docs/release/">Release Notes</a></li> <li><a href="/support/security/">Security</a></li> <li><a href="/support/versioning/">Versioning Policy</a></li> <li><a href="/developer/beta/">Beta Testing Information</a></li> <li><a href="/docs/17/release-17.html">PostgreSQL 17 Beta Release Notes</a></li> <li><a href="https://wiki.postgresql.org/wiki/PostgreSQL_17_Open_Items">PostgreSQL 17 Open Issues</a></li> <li><a href="/about/featurematrix/">Feature Matrix</a></li> <li><a href="/account/submitbug/">Submit a Bug</a></li> <li><a href="https://twitter.com/postgresql">Follow @postgresql on X/Twitter</a></li> <li><a href="/about/donate/">Donate</a></li> </ul> <p>If you have corrections or suggestions for this release announcement, please send them to the <em>pgsql-www@lists.postgresql.org</em> public <a href="/list/">mailing list</a>.</p> Thu, 08 Aug 2024 00:00:00 +0000/about/news/postgresql-164-158-1413-1316-1220-and-17-beta-3-released-2910/Greenmask v0.2.0b1 Release /about/news/greenmask-v020b1-release-2861/ <h1>Greenmask v0.2.0b1 Release</h1> <h2>PostgreSQL Logical Dump and Anonymization Tool</h2> <p>This major <strong>beta release</strong> introduces new features and refactored transformers, significantly enhancing Greenmask's flexibility to better meet business needs. Help us improve GreenMask and tailor it to meet community needs. We welcome your feedback in the <a href="https://github.com/GreenmaskIO/greenmask/discussions/129">release discussion on GitHub</a>.</p> <h2>Greenmask Overview</h2> <p>Greenmask is a versatile open-source tool for database backup, anonymization, and restoration. Written in pure Go with ported PostgreSQL libraries, it is platform-independent and stateless, requiring no schema modifications. It is customizable and compatible with existing PostgreSQL utilities.</p> <h3>Greenmask is ideally suited for:</h3> <ul> <li>Routine backup and restoration tasks, ensuring data integrity and availability.</li> <li>Anonymization and data masking for staging environments and analytics, <strong>protecting sensitive</strong> information while maintaining data utility.</li> </ul> <h3>Key features</h3> <ul> <li><strong>Deterministic transformers</strong> — deterministic approach to data transformation based on the hash functions. This ensures that the same input data will always produce the same output data. Almost each transformer supports either <code>random</code> or <code>hash</code> engine making it universal for any use case.</li> <li><strong>Dynamic parameters</strong> — almost each transformer supports dynamic parameters, allowing to parametrize the transformer dynamically from the table column value. This is helpful for resolving the functional dependencies between columns and satisfying the constraints.</li> <li><strong>Database type safe</strong> - Ensures data integrity by validating data and utilizing the database driver for encoding and decoding operations. This approach guarantees the preservation of data formats.</li> <li><strong>Transformation validation and easy maintainable</strong> - During obfuscation development, Greenmask provides validation warnings and a transformation diff feature, allowing you to monitor and maintain transformations effectively throughout the software lifecycle.</li> <li><strong>Partitioned tables transformation inheritance</strong> - Define transformation configurations once and apply them to all partitions within partitioned tables, simplifying the obfuscation process.</li> <li><strong>Stateless</strong> - Greenmask operates as a logical dump and does not impact your existing database schema.</li> <li><strong>Backward compatible</strong> - It fully supports the same features and protocols as existing vanilla PostgreSQL utilities. Dumps created by Greenmask can be successfully restored using the pg_restore utility.</li> <li><strong>Extensible</strong> - Users have the flexibility to implement domain-based transformations in any programming language or use predefined templates.</li> <li><strong>Provide a variety of storage</strong> - Greenmask offers a variety of storage options for local and remote data storage, including directories and S3-like storage solutions.</li> </ul> <h2>Playground usage for the beta version</h2> <p>If you want to run a Greenmask <a href="https://greenmask.io/v0.2.0b1/playground/">playground</a> for the beta version execute:</p> <p><code>git checkout tags/v0.2.0b1 -b v0.2.0b1 docker-compose run greenmask-from-source</code></p> <h2>Changes overview</h2> <ul> <li><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/dynamic_parameters/">Introduced dynamic parameters in the transformers</a><ul> <li>Most transformers now support dynamic parameters where applicable.</li> <li>Dynamic parameters are strictly enforced. If you need to cast values to another type, Greenmask provides templates and predefined cast functions accessible via <code>cast_to</code>. These functions cover frequent operations such as <code>UnixTimestampToDate</code> and <code>IntToBool</code>.</li> </ul> </li> <li>The transformation logic has been significantly refactored, making transformers more customizable and flexible than before.</li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/transformation_engines/">Introduced transformation engines</a></p> <ul> <li><code>random</code> - generates transformer values based on pseudo-random algorithms.</li> <li><code>hash</code> - generates transformer values using hash functions. Currently, it utilizes <code>sha3</code> hash functions, which are secure but perform slowly. In the stable release, there will be an option to choose between <code>sha3</code> and <code>SipHash</code>.</li> </ul> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/parameters_templating/">Introduced static parameters value template</a></p> </li> </ul> <h2>Notable changes</h2> <h3>Core</h3> <ul> <li>Introduced the <code>Parametrizer</code> interface, now implemented for both dynamic and static parameters.</li> <li>Renamed most of the toolkit types for enhanced clarity and comprehensive documentation coverage.</li> <li>Refactored the <code>Driver</code> initialization logic.</li> <li>Added validation warnings for overridden types in the <code>Driver</code>.</li> <li>Migrated existing built-in transformers to utilize the new <code>Parametrizer</code> interface.</li> <li>Implemented a new abstraction, <code>TransformationContext</code>, as the first step towards enabling new feature transformation conditions (#34).</li> <li>Optimized most transformers for performance in both dynamic and static modes. While dynamic mode offers flexibility, static mode ensures performance remains high. Using only the necessary transformation features helps keep transformation time predictable.</li> </ul> <h3>Documentation</h3> <p>Documentation has been significantly refactored. New information about features and updates to transformer descriptions have been added.</p> <h3>Transformers</h3> <ul> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_email/">RandomEmail</a> - Introduces a new transformer that supports both random and deterministic engines. It allows for flexible email value generation; you can use column values in the template and choose to keep the original domain or select any from the <code>domains</code> parameter.</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/noise_date/">NoiseDate</a>, <a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/noise_float/">NoiseFloat</a>, <a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/noise_int/">NoiseInt</a> - These transformers support both random and deterministic engines, offering dynamic mode parameters that control the noise thresholds within the <code>min</code> and <code>max</code> range. Unlike previous implementations which used a single <code>ratio</code> parameter, the new release features <code>min_ratio</code> and <code>max_ratio</code> parameters to define noise values more precisely. Utilizing the <code>hash</code> engine in these transformers enhances security by complicating statistical analysis for attackers, especially when the same salt is used consistently over long periods.</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/noise_numeric/">NoiseNumeric</a> - A newly implemented transformer, sharing features with <code>NoiseInt</code> and <code>NoiseFloat</code>, but specifically designed for numeric values (large integers or floats). It provides a <code>decimal</code> parameter to handle values with fractions.</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_choice/">RandomChoice</a> - Now supports the <code>hash</code> engine</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_date/">RandomDate</a>, <a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_float/">RandomFloat</a>, <a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_int/">RandomInt</a> - Now enhanced with hash engine support. Threshold parameters <code>min</code> and <code>max</code> have been updated to support dynamic mode, allowing for more flexible configurations.</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_numeric/">RandomNumeric</a> - A new transformer specifically designed for numeric types (large integers or floats), sharing similar features with <code>RandomInt</code> and <code>RandomFloat</code>, but tailored for handling huge numeric values.</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_string/">RandomString</a> - Now supports hash engine mode</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_unix_timestamp/">RandomUnixTimestamp</a> - This new transformer generates Unix timestamps with selectable units (<code>second</code>, <code>millisecond</code>, <code>microsecond</code>, <code>nanosecond</code>). Similar in function to <code>RandomDate</code>, it supports the hash engine and dynamic parameters for <code>min</code> and <code>max</code> thresholds, with the ability to override these units using <code>min_unit</code> and <code>max_unit</code> parameters.</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_uuid/">RandomUuid</a> - Added hash engine support</p> </li> <li> <p><a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_person/">RandomPerson</a> - Implemented a new transformer that replaces <code>RandomName</code>, <code>RandomLastName</code>, <code>RandomFirstName</code>, <code>RandomFirstNameMale</code>, <code>RandomFirstNameFemale</code>, <code>RandomTitleMale</code>, and <code>RandomTitleFemale</code>. This new transformer offers enhanced customizability while providing similar functionalities as the previous versions. It generates personal data such as <code>FirstName</code>, <code>LastName</code>, and <code>Title</code>, based on the provided <code>gender</code> parameter, which now supports dynamic mode. Future minor versions will allow for overriding the default names database.</p> </li> <li> <p>Added <a href="https://greenmask.io/v0.2.0b1/built_in_transformers/advanced_transformers/custom_functions/core_functions/#tsmodify">tsModify</a> - a new template function for time.Time objects modification</p> </li> <li> <p>Introduced a new <a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_ip/">RandomIp</a> transformer capable of generating a random IP address based on the specified netmask.</p> </li> <li> <p>Added a new <a href="https://greenmask.io/v0.2.0b1/built_in_transformers/standard_transformers/random_mac/">RandomMac</a> transformer for generating random Mac addresses.</p> </li> <li> <p>Deleted transformers include <code>RandomMacAddress</code>, <code>RandomIPv4</code>, <code>RandomIPv6</code>, <code>RandomUnixTime</code>, <code>RandomTitleMale</code>, <code>RandomTitleFemale</code>, <code>RandomFirstName</code>, <code>RandomFirstNameMale</code>, <code>RandomFirstNameFemale</code>, <code>RandomLastName</code>, and <code>RandomName</code> due to the introduction of more flexible and unified options.</p> </li> </ul> <h1>Useful Links</h1> <ul> <li>Public <a href="https://github.com/orgs/GreenmaskIO/projects/6">Roadmap</a></li> <li>Explore detailed <a href="https://greenmask.io/v0.2.0b1/installation/">Documentation</a></li> <li>Access the Latest <a href="https://github.com/GreenmaskIO/greenmask/releases/tag/v0.2.0b1">Release on GitHub</a></li> <li>Contact us for support at <a href="mailto:support@greenmask.io">Email Support</a></li> </ul> Mon, 01 Jul 2024 00:00:00 +0000/about/news/greenmask-v020b1-release-2861/PostgreSQL 16.3, 15.7, 14.12, 13.15, and 12.19 Released! /about/news/postgresql-163-157-1412-1315-and-1219-released-2858/ <p>The PostgreSQL Global Development Group has released an update to all supported versions of PostgreSQL, including 16.3, 15.7, 14.12, 13.15, and 12.19. This release fixes one security vulnerability and over 55 bugs reported over the last several months.</p> <p>A security vulnerability was found in the system views <a href="/docs/current/view-pg-stats-ext.html"><code>pg_stats_ext</code></a> and <a href="/docs/current/view-pg-stats-ext-exprs.html"><code>pg_stats_ext_exprs</code></a>, potentially allowing authenticated database users to see data they don't have sufficient privileges to view. The fix for this vulnerability only fixes fresh PostgreSQL installations, namely those that are created with the <a href="/docs/current/app-initdb.html"><code>initdb</code></a> utility after this fix is applied. If you have a current PostgreSQL installation and are concerned about this issue, please follow the instructions in the "Updating" section for remediation steps.</p> <p>For the full list of changes, please review the <a href="/docs/release/">release notes</a>.</p> <h2>PostgreSQL 12 EOL Notice</h2> <p>PostgreSQL 12 will stop receiving fixes on November 14, 2024. If you are running PostgreSQL 12 in a production environment, we suggest that you make plans to upgrade to a newer, supported version of PostgreSQL. Please see our <a href="/support/versioning/">versioning policy</a> for more information.</p> <h2>Security Issues</h2> <h3><a href="/support/security/CVE-2024-4317/">CVE-2024-4317</a>: Restrict visibility of <code>pg_stats_ext</code> and <code>pg_stats_ext_exprs</code> entries to the table owner</h3> <p>CVSS v3.1 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?vector=AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:N/A:N">3.1</a></p> <p>Supported, Vulnerable Versions: 14 - 16.</p> <p>Missing authorization in PostgreSQL built-in views <a href="/docs/current/view-pg-stats-ext.html"><code>pg_stats_ext</code></a> and <a href="/docs/current/view-pg-stats-ext-exprs.html"><code>pg_stats_ext_exprs</code></a> allows an unprivileged database user to read most common values and other statistics from <a href="/docs/current/sql-createstatistics.html"><code>CREATE STATISTICS</code></a> commands of other users. The most common values may reveal column values the eavesdropper could not otherwise read or results of functions they cannot execute.</p> <p>This fix only fixes fresh PostgreSQL installations, namely those that are created with the <a href="/docs/current/app-initdb.html"><code>initdb</code></a> utility after this fix is applied. If you have a current PostgreSQL installation and are concerned about this issue, please follow the instructions in the "Updating" section for remediation steps.</p> <p>The PostgreSQL project thanks Lukas Fittl for reporting this problem.</p> <h2>Bug Fixes and Improvements</h2> <p>This update fixes over 55 bugs that were reported in the last several months. The issues listed below affect PostgreSQL 16. Some of these issues may also affect other supported versions of PostgreSQL.</p> <ul> <li>Fix issue with <a href="/docs/current/sql-insert.html"><code>INSERT</code></a> with a multi-row <a href="/docs/current/sql-values.html"><code>VALUES</code></a> clause where a target column is a domain over an array or composite type.</li> <li>Require the <a href="/docs/current/sql-grant.html">SELECT privilege</a> on the target table when using <a href="/docs/current/sql-merge.html"><code>MERGE</code></a> when using <code>MERGE ... DO NOTHING</code>.</li> <li>Per the SQL standard, throw an error if a target row in <code>MERGE</code> joins to more than one source row during a modification.</li> <li>Fix incorrect pruning of <code>NULL</code> partition when a table is partitioned on a boolean column and the query has a boolean <code>IS NOT</code> clause.</li> <li>Make <a href="/docs/current/sql-alterforeigntable.html"><code>ALTER FOREIGN TABLE ... SET SCHEMA</code></a> move any owned sequences into the new schema.</li> <li><a href="/docs/current/sql-createdatabase.html"><code>CREATE DATABASE</code></a> now recognizes <code>STRATEGY</code> keywords case-insensitively.</li> <li>Fix how <a href="/docs/current/sql-explain.html">EXPLAIN</a> counts heap pages during bitmap heap scan to show all counted pages, not just ones with visible tuples.</li> <li>Avoid deadlock during removal of orphaned temporary tables.</li> <li>Several fixes for <a href="/docs/current/sql-vacuum.html"><code>VACUUM</code></a>, including one that can reduce unnecessary I/O.</li> <li>Several query planner fixes.</li> <li>Add optimization for certain operations where an installation has thousands of roles.</li> <li>Fix confusion for SQL-language procedures that return a single composite-type column.</li> <li>Fix incorrect rounding and overflow hazards in <a href="/docs/current/functions-datetime.html#FUNCTIONS-DATETIME-BIN"><code>date_bin()</code></a>.</li> <li>Detect integer overflow when adding or subtracting an <a href="/docs/current/datatype-datetime.html#DATATYPE-INTERVAL-INPUT">interval</a> to/from a timestamp.</li> <li>Fix several race conditions with logical replication, including determining if a table sync operation is required.</li> <li>Disconnect if a new server session's client socket cannot be put into non-blocking mode.</li> <li><a href="/docs/current/app-initdb.html"><code>initdb -c</code></a> now matches parameter names case-insensitively.</li> <li>Fix how PL/pgSQL parses of <a href="/docs/current/plpgsql-structure.html">single-line comments</a> (<code>-- style comments</code>) following expression.</li> </ul> <h2>Updating</h2> <p>All PostgreSQL update releases are cumulative. As with other minor releases, users are not required to dump and reload their database or use <code>pg_upgrade</code> in order to apply this update release; you may simply shutdown PostgreSQL and update its binaries.</p> <p>For existing installations that are impacted by CVE-2024-4317 that wish to remediate the issue, you will have to perform the following steps:</p> <ol> <li> <p>Find the SQL script <code>fix-CVE-2024-4317.sql</code> in the <code>share</code> directory of your PostgreSQL installation (e.g. in <code>/usr/share/postgresql/</code>), or download it from the PostgreSQL git repository from one of the URLs below. You will need to use the script that matches your major version:</p> </li> <li> <p><a href="https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_16_STABLE">PostgreSQL 16</a>: <a href="https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_16_STABLE">https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_16_STABLE</a></p> </li> <li><a href="https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_15_STABLE">PostgreSQL 15</a>: <a href="https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_15_STABLE">https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_15_STABLE</a></li> <li><a href="https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_14_STABLE">PostgreSQL 14</a>: <a href="https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_14_STABLE">https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/catalog/fix-CVE-2024-4317.sql;hb=refs/heads/REL_14_STABLE</a></li> </ol> <p>From the above URLs, you can click the URL that says "raw" to download a version that you can copy and paste.</p> <p>Be sure to use the script appropriate to your PostgreSQL major version. If you do not see this file, either your version is not vulnerable (only PostgreSQL 14, 15, and 16 are affected) or your minor version is too old to have the fix.</p> <ol> <li>In each database of the cluster, run the <code>fix-CVE-2024-4317.sql</code> script as a database superuser. For example, in <a href="/docs/current/app-psql.html"><code>psql</code></a>, with the file located in <code>/usr/share/postgresql/</code>, this command would look like:</li> </ol> <p><code>\i /usr/share/postgresql/fix-CVE-2024-4317.sql</code></p> <ol> <li>You must also execute this script in the <code>template0</code> and <code>template1</code> databases, or the vulnerability will still exist in databases you create later. To fix <code>template0</code>, you'll need to temporarily allow it accept connections. You can do this with the following command:</li> </ol> <p><code>ALTER DATABASE template0 WITH ALLOW_CONNECTIONS true;</code></p> <p>After executing the <code>fix-CVE-2024-4317.sql</code> script in <code>template0</code> and <code>template1</code>, you should revoke the ability for <code>template0</code> to accept connections. You can do this with the following command:</p> <p><code>ALTER DATABASE template0 WITH ALLOW_CONNECTIONS false;</code></p> <p>Users who have skipped one or more update releases may need to run additional post-update steps; please see the release notes from earlier versions for details.</p> <p>For more details, please see the <a href="/docs/release/">release notes</a>.</p> <h2>Links</h2> <ul> <li><a href="/download/">Download</a></li> <li><a href="/docs/release/">Release Notes</a></li> <li><a href="/support/security/">Security</a></li> <li><a href="/support/versioning/">Versioning Policy</a></li> <li><a href="/about/press/">PostgreSQL 16 Release Announcement</a></li> <li><a href="https://twitter.com/postgresql">Follow @postgresql on X/Twitter</a></li> <li><a href="/about/donate/">Donate</a></li> </ul> <p>If you have corrections or suggestions for this release announcement, please send them to the <em>pgsql-www@lists.postgresql.org</em> public <a href="/list/">mailing list</a>.</p> Thu, 09 May 2024 00:00:00 +0000/about/news/postgresql-163-157-1412-1315-and-1219-released-2858/pgAdmin 4 v8.6 Released /about/news/pgadmin-4-v86-released-2853/ <p>The pgAdmin Development Team is pleased to announce pgAdmin 4 version 8.6. This release of pgAdmin 4 includes 15 bug fixes and new features. For more details please see the <a href="https://www.pgadmin.org/docs/pgadmin4/8.6/release_notes_8_6.html">release notes</a>.</p> <p>pgAdmin is the leading Open Source graphical management tool for PostgreSQL. For more information, please see <a href="https://www.pgadmin.org/">the website</a>.</p> <p>Notable changes in this release include:</p> <h3>Features:</h3> <ul> <li>Added the new columns "last_seq_scan" and "last_idx_scan" from the pg_stat_all_tables and pg_stat_all_indexes tables respectively to the Statistics tab.</li> <li>Added support for excluding multiple tables while taking Backup.</li> </ul> <h3>Bugs/Housekeeping:</h3> <ul> <li>Fixed an XSS vulnerability in the /settings/store endpoint (CVE-2024-4216).</li> <li>Fixed Multi-Factor Authentication bypass vulnerability (CVE-2024-4215).</li> <li>Update UI library MUI from v4 to v5.</li> <li>Upgraded Flask, Flask-Security-Too, Werkzeug, and other dependencies, ensuring compatibility with Python 3.7.</li> <li>Fixed violates check constraint issue when creating a pgAgent schedule.</li> <li>Fixed an issue where pressing backspace should remove the spaces and not the entire tab width, on enabling 'Use spaces?' in the preferences.</li> <li>Fixed an issue where incorrect select/exec scripts were generated for functions/procedures.</li> <li>Fixed an issue when closing the view data second tab; it raises the error that the 'ViewCommand' object has no attribute 'auto_commit'.</li> <li>Install dbus-python, an in-direct dependency of the Keyring package as a system package for Debian platforms.</li> </ul> <p>Builds for Windows and macOS are available now, along with a Python Wheel, Docker Container, RPM, DEB Package, and source code tarball from the <a href="https://www.pgadmin.org/download/">tarball area</a>.</p> Thu, 02 May 2024 00:00:00 +0000/about/news/pgadmin-4-v86-released-2853/PostgreSQL JDBC 42.7.2, 42.6.1, 42.5.5, 42.4.4, 42.3.9, 42.2.28, and 42.2.28.jre7 Security update for CVE-2024-1597 /about/news/postgresql-jdbc-4272-4261-4255-4244-4239-42228-and-42228jre7-security-update-for-cve-2024-1597-2812/ <p>The PostgreSQL JDBC team have released 42.7.2, 42.6.1, 42.5.5, 42.4.4, 42.3.9, 42.2.28, and 42.2.28.jre7 to address a security issue: <a href="https://www.cve.org/CVERecord?id=CVE-2024-1597">CVE-2024-1597</a>. (Note there is no fix for 42.2.26.jre6 see the advisory for workarounds) </p> <p>SQL injection is possible when using the non-default connection property preferQueryMode=simple in combination with application code that has a vulnerable SQL that negates a parameter value.</p> <p>There is no vulnerability in the driver when using the default query mode. Users that do not override the query mode are not impacted.</p> <p>See the <a href="https://github.com/pgjdbc/pgjdbc/security/advisories/GHSA-24rp-q3w6-vc56">security advisory</a> for the details. Thanks to <a href="https://github.com/paul-gerste-sonarsource">Paul Gerste</a> for finding and reporting the issue.</p> Wed, 21 Feb 2024 00:00:00 +0000/about/news/postgresql-jdbc-4272-4261-4255-4244-4239-42228-and-42228jre7-security-update-for-cve-2024-1597-2812/PostgreSQL 16.2, 15.6, 14.11, 13.14, and 12.18 Released! /about/news/postgresql-162-156-1411-1314-and-1218-released-2807/ <p>The PostgreSQL Global Development Group has released an update to all supported versions of PostgreSQL, including 16.2, 15.6, 14.11, 13.14, and 12.18. This release fixes one security vulnerability and over 65 bugs reported over the last several months.</p> <p>If you use GIN indexes, you may need to reindex after updating to this release. Please see the <a href="/docs/release/">release notes</a> for more information.</p> <p>For the full list of changes, please review the <a href="/docs/release/">release notes</a>.</p> <h2>Security Issues</h2> <h3><a href="/support/security/CVE-2024-0985/">CVE-2024-0985</a>: PostgreSQL non-owner <code>REFRESH MATERIALIZED VIEW CONCURRENTLY</code> executes arbitrary SQL</h3> <p>CVSS v3 Base Score: <a href="https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?vector=AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H">8.0</a></p> <p>Supported, Vulnerable Versions: 12 - 16.</p> <p>One step of a concurrent refresh command was run under weak security restrictions. If a materialized view's owner could persuade a superuser or other high-privileged user to perform a concurrent refresh on that view, the view's owner could control code executed with the privileges of the user running <code>REFRESH</code>. The fix for the vulnerability makes is so that all user-determined code is run as the view's owner, as expected.</p> <p>The PostgreSQL project thanks Pedro Gallegos for reporting this problem.</p> <h2>Bug Fixes and Improvements</h2> <p>This update fixes over 65 bugs that were reported in the last several months. The issues listed below affect PostgreSQL 16. Some of these issues may also affect other supported versions of PostgreSQL.</p> <ul> <li>Fix memory leak when performing JIT inlining that could lead to out-of-memory conditions.</li> <li>Several query planner fixes.</li> <li>Align <code>MERGE</code> behavior with <code>UPDATE</code> when updating a partition key column and skip firing <code>AFTER UPDATE ROW</code> trigger and other post-update actions.</li> <li>Fix problems with duplicate token names in <code>ALTER TEXT SEARCH CONFIGURATION ... MAPPING</code> commands.</li> <li>Fix <code>DROP ROLE</code> with duplicate role names.</li> <li>Properly lock the associated table during DROP STATISTICS to prevent errors if <code>ANALYZE</code> is running concurrently.</li> <li>Fix function volatility checking for <code>GENERATED</code> and <code>DEFAULT</code> expressions.</li> <li>Ensure collation matches when matching an existing index to a new partitioned index.</li> <li>Avoid failure if a child index is dropped concurrently with <code>REINDEX INDEX</code> on a partitioned index.</li> <li>Fix for locking during cleanup of GIN indexes. For this case, if multiple processes tried to clean the same GIN index page, there was a chance of index corruption. If you believe you were affected by this issue, reindex your GIN indexes after installing this update.</li> <li>Avoid failure with partitioned SP-GiST indexes.</li> <li>Several ownership fixes for large objects.</li> <li>In <code>EXPLAIN (BUFFERS)</code>, change name of I/O timing data "shared/local" to "shared".</li> <li>Ensure durability of the <code>CREATE DATABASE</code> command if a system crash occurred during or shortly after execution.</li> <li>Add more logging messages when starting and ending recovery from a backup.</li> <li>Revert a change that made the walreceiver process unresponsive to <code>SIGTERM</code> while waiting for a replication connection to be established.</li> <li>Several fixes for logical replication.</li> <li>Fix incompatibility with OpenSSL 3.2.</li> <li>Fix PL/pgSQL to allow <code>CREATE FUNCTION</code>/<code>CREATE PROCEDURE</code> SQL commands that use SQL-standard function bodies.</li> <li>Fix for error handling in <a href="/docs/current/libpq-pipeline-mode.html">libpq pipeline mode</a>.</li> <li>Ensure <code>initdb</code> always uncomments <code>postgresql.conf</code> entries for the <code>lc_</code> family of parameters.</li> <li>In <code>pg_dump</code>, don't dump RLS policies or security labels for extension member objects.</li> </ul> <p>This release also updates time zone data files to tzdata release 2024a for DST law changes in Greenland, Kazakhstan, and Palestine, plus corrections for the Antarctic stations Casey and Vostok. Also historical corrections for Vietnam, Toronto, and Miquelon.</p> <h2>Updating</h2> <p>All PostgreSQL update releases are cumulative. As with other minor releases, users are not required to dump and reload their database or use <code>pg_upgrade</code> in order to apply this update release; you may simply shutdown PostgreSQL and update its binaries.</p> <p>If you use GIN indexes, you may need to reindex after updating to this release. Please see the <a href="/docs/release/">release notes</a> for more information.</p> <p>Users who have skipped one or more update releases may need to run additional post-update steps; please see the release notes from earlier versions for details.</p> <p>For more details, please see the <a href="/docs/release/">release notes</a>.</p> <h2>Links</h2> <ul> <li><a href="/download/">Download</a></li> <li><a href="/docs/release/">Release Notes</a></li> <li><a href="/support/security/">Security</a></li> <li><a href="/support/versioning/">Versioning Policy</a></li> <li><a href="/about/press/">PostgreSQL 16 Release Announcement</a></li> <li><a href="https://twitter.com/postgresql">Follow @postgresql on Twitter</a></li> <li><a href="/about/donate/">Donate</a></li> </ul> <p>If you have corrections or suggestions for this release announcement, please send them to the <em>pgsql-www@lists.postgresql.org</em> public <a href="/list/">mailing list</a>.</p> Thu, 08 Feb 2024 00:00:00 +0000/about/news/postgresql-162-156-1411-1314-and-1218-released-2807/PostgreSQL is now a CVE Numbering Authority (CNA) /about/news/postgresql-is-now-a-cve-numbering-authority-cna-2790/ <p>The PostgreSQL Security team is pleased to announce that PostgreSQL is now a CVE Numbering Authority (CNA). A CNA has responsibilities for assigning CVE IDs and participating in responsible disclosure with projects within its scope. You can find out more information about the role of PostgreSQL as a CNA on the <a href="/support/security/">PostgreSQL security</a> page:</p> <p><a href="/support/security/">/support/security/</a></p> <p>The process for reporting a security vulnerability in PostgreSQL has not changed. If you believe you have discovered a security vulnerability in PostgreSQL, please send an email to <a href="mailto:security@postgresql.org">security@postgresql.org</a>. For more information on what is considered a vulnerability and the reporting process, please review the <a href="/support/security/">PostgreSQL security</a> page:</p> <p><a href="/support/security/">/support/security/</a></p> <p>You can find the original announcement on PostgreSQL being added as a CNA on the CVE page:</p> <p><a href="https://www.cve.org/Media/News/item/news/2024/01/16/PostgreSQL-Added-as-CNA">https://www.cve.org/Media/News/item/news/2024/01/16/PostgreSQL-Added-as-CNA</a></p> Thu, 18 Jan 2024 00:00:00 +0000/about/news/postgresql-is-now-a-cve-numbering-authority-cna-2790/