Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 122739

Summary: dev-db/postgresql: SET ROLE denial of service
Product: Gentoo Security Reporter: David Fetter <dfetter>
Component: VulnerabilitiesAssignee: Gentoo Security <security>
Status: RESOLVED FIXED    
Severity: trivial CC: esigra, pgsql-bugs
Priority: High    
Version: unspecified   
Hardware: All   
OS: All   
URL: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-0553
Whiteboard: ~3 [noglsa]
Package list:
Runtime testing required: ---

Description David Fetter 2006-02-13 15:53:15 UTC
http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-0553 (eventually)

These minor version updates fix a bug in SET SESSION AUTHORIZATION that allows unprivileged users to crash the server, if it has been compiled with Asserts enabled.

Tarballs are available at ftp://ftp.postgresql.org/
Comment 1 Masatomo Nakano (RETIRED) gentoo-dev 2006-02-15 05:08:17 UTC
I added postgresql-8.1.3.ebuild yesterday.
Also, we will not need GLSA since 8.1 branch has never been stable in the portage tree.
Comment 2 Thierry Carrez (RETIRED) gentoo-dev 2006-02-15 10:10:10 UTC
Then we are done here.
Comment 3 Thierry Carrez (RETIRED) gentoo-dev 2006-02-15 10:19:42 UTC
Hm reopening since there is more to it :

=========================================
PostgreSQL versions 8.1.3, 8.0.7, 7.4.12 and 7.3.14 have been released fixing two security issues.

Details of vulnerability 1
--------------------------
Vulnerability type: Escalation of privileges
Remotely exploitable: No (requires valid login)
Affected versions: PostgreSQL 8.1.0-8.1.2
Fixed versions: PostgreSQL 8.1.3
Affected platforms: All
CVE: CVE-2006-0553 (http://cve.mitre.org/cgi-bin/cvename.cgi?name=2006-0553)

Vulnerability description
-------------------------
By issuing SET ROLE with a specially crafted argument, it is possible for any logged-in database user to acquire the privileges of any other database user, including superusers. Database superuser status allows access to the machine's filesystem and hence might be used to mount remote attacks against the rest of the server's operating system.
SET ROLE is not available in PostgreSQL prior to version 8.1.

Details of vulnerability 2
--------------------------
Vulnerability type: Denial of service
Remotely exploitable: No (requires valid login)
Affected versions: PostgreSQL 8.0.0-8.0.6, 7.4.0-7.4.11, 7.3.0-7.3.13
Fixed versions: PostgreSQL 8.0.7, 7.4.12, 7.3.14
Affected platforms: All
CVE: CVE-2006-0678 (http://cve.mitre.org/cgi-bin/cvename.cgi?name=2006-0678)

Vulnerability description
-------------------------
A similar issue exists in SET SESSION AUTHORIZATION. This variant cannot be exploited for privilege escalation, because one must already be superuser to use SET SESSION AUTHORIZATION.
However, if the server has been compiled with Asserts enabled (which is not the default), then it is possible to trigger an Assert failure before the privilege check is reached.  This would cause a momentary denial of service to other database users.

Solution
--------
Upgrade to version 8.1.3, 8.0.7, 7.4.12 or 7.3.14 respectively, available from http://www.postgresql.org/ftp/ in both source and binary formats.

Mitigating factors
------------------
A valid login to the database is required before any of these vulnerabilities can be exploited.

PostgreSQL will not allow execution as "root" on Unix or with administrator permissions on Windows, which limits the exposure of other parts of the system.

Credits
-------
The PostgreSQL Global Development Group thanks Akio Ishida for reporting this vulnerability.
=========================================

So we need stableization for versions 8.0.7, 7.4.12 and 7.3.14. Calling arches.
Comment 4 Thierry Carrez (RETIRED) gentoo-dev 2006-02-15 10:20:56 UTC
Specific configuration is needed... Do we compile with asserts enabled ? If it's not the case, no need to stableize...
Comment 5 Masatomo Nakano (RETIRED) gentoo-dev 2006-02-15 11:06:39 UTC
sorry, I didn't know the Details of vulnerability 2.
Our ebuilds will affect the problem since it doesn't have "Asserts enabled" option.

I have already added 8.0.7, 7.4.12 and 7.3.14 too.
Comment 6 Thierry Carrez (RETIRED) gentoo-dev 2006-02-15 11:23:29 UTC
If our ebuilds do not provide a way of enabling asserts, then we are unaffected. Closing, sorry for the noise.
Comment 7 René Nussbaumer (RETIRED) gentoo-dev 2006-02-15 22:19:08 UTC
Because this bug is fixed I remove hppa from CC.
Comment 8 Joshua Kinard gentoo-dev 2006-02-19 22:51:54 UTC
mips stable on 7.3.14, 7.4.12, & 8.0.7.