CVE-2024-10978

NameCVE-2024-10978
DescriptionIncorrect 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 SET ROLE, SET SESSION AUTHORIZATION, 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 current_setting('role') or the current user ID, it may modify or return data as though the session had not used SET ROLE or SET SESSION AUTHORIZATION. The attacker does not control which incorrect user ID applies. Query text from less-privileged sources is not a concern here, because SET ROLE and SET SESSION AUTHORIZATION are not sandboxes for unvetted queries. Versions before PostgreSQL 17.1, 16.5, 15.9, 14.14, 13.17, and 12.21 are affected.
SourceCVE (at NVD; CERT, LWN, oss-sec, fulldisc, Red Hat, Ubuntu, Gentoo, SUSE bugzilla/CVE, GitHub advisories/code/issues, web search, more)
ReferencesDLA-3954-1, DSA-5812-1

Vulnerable and fixed packages

The table below lists information on source packages.

Source PackageReleaseVersionStatus
postgresql-11 (PTS)buster, buster (lts)11.22-0+deb10u3vulnerable
buster (security)11.22-0+deb10u2vulnerable
postgresql-13 (PTS)bullseye13.16-0+deb11u1vulnerable
bullseye (security)13.18-0+deb11u1fixed
postgresql-15 (PTS)bookworm15.8-0+deb12u1vulnerable
bookworm (security)15.10-0+deb12u1fixed
postgresql-16 (PTS)sid, trixie16.4-3vulnerable
postgresql-17 (PTS)trixie17.0-1vulnerable
sid17.2-1fixed
postgresql-9.4 (PTS)jessie, jessie (lts)9.4.26-0+deb8u10vulnerable
postgresql-9.6 (PTS)stretch (security)9.6.24-0+deb9u1vulnerable
stretch (lts), stretch9.6.24-0+deb9u7vulnerable

The information below is based on the following data on fixed versions.

PackageTypeReleaseFixed VersionUrgencyOriginDebian Bugs
postgresql-11source(unstable)(unfixed)
postgresql-13sourcebullseye13.17-0+deb11u1DLA-3954-1
postgresql-13source(unstable)(unfixed)
postgresql-15sourcebookworm15.9-0+deb12u1DSA-5812-1
postgresql-15source(unstable)(unfixed)
postgresql-16source(unstable)(unfixed)
postgresql-17source(unstable)17.1-1
postgresql-9.4source(unstable)(unfixed)
postgresql-9.6source(unstable)(unfixed)

Notes

https://www.postgresql.org/support/security/CVE-2024-10978/
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=cd82afdda5e9d3269706a142e9093ba83f484185 (v17.2, 1 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=f4f5d27d87247da1ec7e5a6e7990a22ffba9f63a (v17.2, 2 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=1c05004a895308da10ec000ba6b92f72f4f5b8e2 (v17.2, regression fix)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=ae340d0318521ae7234ed3b7221a1f65f39a52c0 (v16.6, 1 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=95f5a523729f6814c8757860d9a2264148b7b0df (v16.6, 2 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=b0918c1286d316f6ffa93995452270afd4fc4335 (v16.6, regression fix)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=a5d2e6205f716c79ecfb15eb1aae75bae3f8daa9 (v15.10, 1 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=109a323807d752f66699a9ce0762244f536e784f (v15.10, 2 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=edf80895f6bda824403f843df91cbc83890e4b6c (v15.10, regression fix)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=2a68808e241bf667ff72c31ea9d0c4eb0b893982 (v14.15, 1 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=00b94e8e2f99a8ed1d7f854838234ce37f582da0 (v14.15, 2 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=be062bfa54d780c07a3b36c4123da2c960c8e97d (v14.15, regression fix)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=76123ded6e9b3624e380ac326645bd026aacd2f5 (v13.18, 1 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=dc7378793add3c3d9a40ec2118d92bd719acab97 (v13.18, 2 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=07c6e0f613612ff060572a085c1c24aa44c8b2bb (v13.18, regression fix)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=4c9d96f74ba4e7d01c086ca54f217e242dd65fae (v12.21, 1 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=0edad8654848affe0786c798aea9e1a43dde54bc (v12.21, 2 of 2)
Fixed by: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=c463338656ac47e5210fcf9fbf7d20efccce8de8 (v12.21, regression fix)

Search for package or bug name: Reporting problems