PostgreSQL Vulnerability in Authorization Mechanism - USN-6802-1
Summary
USN-6802-1: postgresql-14, postgresql-15, postgresql-16 vulnerability. Affects postgresql-14 versions < 14.12-0ubuntu0.22.04.1. Fixed in 14.12-0ubuntu0.22.04.1. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
PostgreSQL is a powerful, open-source relational database system that uses and extends the SQL language. It is known for its robustness, extensibility, and support for advanced data types. The vulnerability identified in this report affects PostgreSQL versions 14, 15, and 16, specifically in the built-in pg_stats_ext and pg_stats_ext_exprs views, which are used to gather statistical information about database objects.
Vulnerability Detail
Lukas Fittl discovered that PostgreSQL incorrectly performed authorization in the built-in pg_stats_ext and pg_stats_ext_exprs views. This flaw allows an unprivileged database user to read most common values and other statistics from CREATE STATISTICS commands of other users. The vulnerability is classified under CVE-2024-4317 and poses a significant risk as it can lead to unauthorized access to sensitive statistical data, potentially compromising user privacy and data integrity.
How To Fix
Minimum fixed version
14.12-0ubuntu0.22.04.1
This is the first release that contains the fix.
sudo apt-get install --only-upgrade postgresql-14
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
Currently, there are no specific workarounds mentioned for this vulnerability. Users are advised to apply the patch as soon as possible to mitigate the risk.
Conclusion
The PostgreSQL vulnerability identified as USN-6802-1 poses a significant risk by allowing unauthorized access to sensitive statistical data. Users are strongly encouraged to update their installations to the patched versions to secure their databases and protect user privacy.
See every vulnerability recorded for postgresql-14 →
FAQ
The vulnerability allows unprivileged users to access statistical data from other users' CREATE STATISTICS commands due to improper authorization checks.
PostgreSQL versions 14, 15, and 16 are affected by this vulnerability.
You can use Vulert, which monitors open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without requiring any signup.
While there are no specific workarounds, it is crucial to plan for an update as soon as possible to mitigate the risk associated with this vulnerability.
More information can be found in the PostgreSQL release notes at https://www.postgresql.org/docs/16/release-16-3.html, https://www.postgresql.org/docs/15/release-15-7.html, and https://www.postgresql.org/docs/14/release-14-12.html.
References
Related vulnerabilities
Recent vulnerabilities recorded for postgresql-14.