CVE-2016-0766
High · 8.8CVSS
8.8
EPSS
4.1%
Published
Feb 17, 2016
CISA due date
—
Cloudanix analysis
A problem in certain database software lets people who already have limited access gain much more control, which could allow them to reach or alter important information.
- Exploitation
- Remote Authenticated
- Attacker needs
- Low Privilege
- Complexity
- Low
- Impact
- Privilege Gain
- Component
- Network Service
- Class
- Privilege Escalation
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
The flaw permits low-privileged database users to modify unspecified custom configuration settings (GUCS) exposed to PL/Java, bypassing intended access controls and resulting in privilege escalation to higher database roles.
Why it matters to the business
Organizations running affected PostgreSQL deployments or container images that include them face risk of unauthorized database access escalation, which can lead to data exposure, integrity loss, or full system compromise; the large number of downstream package dependents increases the potential blast radius if unpatched instances remain in production or build pipelines.
How an attack unfolds
An attacker with low-privileged remote database access identifies PL/Java-enabled custom settings, issues crafted configuration changes that exploit the missing restrictions, and escalates to administrative privileges, enabling further actions such as data exfiltration or persistence within the PostgreSQL instance.
How to fix it
Upgrade PostgreSQL to versions 9.1.20, 9.2.15, 9.3.11, 9.4.6, 9.5.1 or later. For affected kaniko packages, update to the versions fixed in 1.21.0-r1 (kaniko, kaniko-compat, kaniko-warmer, and their Chainguard/Wolfi variants). Apply the postgresql.git commit 3dca6f36fcd694c8c49d26e7c4971194dee2754a where applicable and verify PL/Java configuration restrictions post-upgrade.
How to confirm the fix worked
Confirm PostgreSQL version strings match or exceed the fixed releases, review postgresql.conf and PL/Java extension settings to ensure custom GUCS are properly restricted, and test that low-privileged users can no longer modify protected configuration parameters.
Typical attack path
- Obtain low-privileged remote access to a PostgreSQL instance with PL/Java installed
- Identify and target exposed custom configuration settings (GUCS) for PL/Java
- Issue configuration modification commands that bypass access restrictions
- Escalate to higher-privileged database roles
- Leverage elevated access for further compromise or data access
How to detect it
Review PostgreSQL logs for unexpected modifications to custom configuration settings or PL/Java-related parameters by non-administrative users; examine authentication and role-change events around the time of suspected access; correlate with application or container logs from affected kaniko-based builds if present.
What your security team should do
- Prioritize immediate upgrade of all PostgreSQL instances and dependent kaniko images to the listed fixed versions
- Audit current deployments for PL/Java usage and restrict custom configuration settings to trusted roles only
- Monitor for any remaining unpatched instances given the multi-year exposure window
- Include the affected packages in routine container image scanning and update pipelines
The record
PostgreSQL before 9.1.20, 9.2.x before 9.2.15, 9.3.x before 9.3.11, 9.4.x before 9.4.6, and 9.5.x before 9.5.1 does not properly restrict access to unspecified custom configuration settings (GUCS) for PL/Java, which allows attackers to gain privileges via unspecified vectors.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Debian:7 | postgresql-9.1 | 0 | 9.1.20-0+deb7u1 |
| Debian:8 | postgresql-9.4 | 0 | 9.4.6-0+deb8u1 |
| Mageia:5 | postgresql9.3 | 0 | 9.3.11-1.mga5 |
| Mageia:5 | postgresql9.4 | 0 | 9.4.6-1.mga5 |
| SUSE:Linux Enterprise Desktop 11 SP4 | postgresql94 | 0 | 9.4.6-0.14.3 |
| SUSE:Linux Enterprise Desktop 11 SP4 | postgresql94-libs | 0 | 9.4.6-0.14.3 |
| SUSE:Linux Enterprise Desktop 12 | postgresql93 | 0 | 9.3.11-14.2 |
| SUSE:Linux Enterprise Desktop 12 | postgresql94 | 0 | 9.4.6-7.2 |
| SUSE:Linux Enterprise Desktop 12 | postgresql94-libs | 0 | 9.4.6-7.1 |
| SUSE:Linux Enterprise Desktop 12 SP1 | postgresql94 | 0 | 9.4.6-7.2 |
| SUSE:Linux Enterprise Desktop 12 SP1 | postgresql94-libs | 0 | 9.4.6-7.1 |
| SUSE:Linux Enterprise Server 11 SP4 | postgresql94 | 0 | 9.4.6-0.14.3 |
| SUSE:Linux Enterprise Server 11 SP4 | postgresql94-libs | 0 | 9.4.6-0.14.3 |
| SUSE:Linux Enterprise Server 12 | postgresql93 | 0 | 9.3.11-14.2 |
| SUSE:Linux Enterprise Server 12 | postgresql94 | 0 | 9.4.6-7.2 |
| SUSE:Linux Enterprise Server 12 | postgresql94-libs | 0 | 9.4.6-7.1 |
| SUSE:Linux Enterprise Server 12 SP1 | postgresql94 | 0 | 9.4.6-7.2 |
| SUSE:Linux Enterprise Server 12 SP1 | postgresql94-libs | 0 | 9.4.6-7.1 |
| SUSE:Linux Enterprise Server for SAP Applications 11 SP4 | postgresql94 | 0 | 9.4.6-0.14.3 |
| SUSE:Linux Enterprise Server for SAP Applications 11 SP4 | postgresql94-libs | 0 | 9.4.6-0.14.3 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | postgresql93 | 0 | 9.3.11-14.2 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | postgresql94 | 0 | 9.4.6-7.2 |
| SUSE:Linux Enterprise Server for SAP Applications 12 | postgresql94-libs | 0 | 9.4.6-7.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP1 | postgresql94 | 0 | 9.4.6-7.2 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP1 | postgresql94-libs | 0 | 9.4.6-7.1 |
| SUSE:Linux Enterprise Software Development Kit 11 SP4 | postgresql94-libs | 0 | 9.4.6-0.14.3 |
| SUSE:Linux Enterprise Software Development Kit 12 | postgresql93-libs | 0 | 9.3.11-14.1 |
| SUSE:Linux Enterprise Software Development Kit 12 | postgresql94-libs | 0 | 9.4.6-7.1 |
| SUSE:Linux Enterprise Software Development Kit 12 SP1 | postgresql94-libs | 0 | 9.4.6-7.1 |
| Ubuntu:14.04:LTS | postgresql-9.1 | 0 | 9.1.20-0ubuntu0.14.04 |
| Ubuntu:14.04:LTS | postgresql-9.3 | 0 | 9.3.11-0ubuntu0.14.04 |
| Ubuntu:16.04:LTS | postgresql-9.5 | 0 | 9.5.1-1 |
| openSUSE:Tumbleweed | postgresql93 | 0 | 9.3.15-1.1 |
| openSUSE:Tumbleweed | postgresql94 | 0 | 9.4.10-1.1 |
| openSUSE:Tumbleweed | postgresql95 | 0 | 9.5.4-1.2 |
Related vulnerabilities
- CVE-2014-8161 PostgreSQL before 9.0.19, 9.1.x before 9.1.15, 9.2.x before 9.2.10, 9.3.x before 9.3.6… Also affects postgresql-9.1
- CVE-2017-7546 PostgreSQL versions before 9.2.22, 9.3.18, 9.4.13, 9.5.8 and 9.6.4 are vulnerable to… Also affects postgresql-9.1
- CVE-2016-5423 PostgreSQL before 9.1.23, 9.2.x before 9.2.18, 9.3.x before 9.3.14, 9.4.x before 9.4.9… Also affects postgresql-9.1
- CVE-2015-5288 The crypt function in contrib/pgcrypto in PostgreSQL before 9.0.23, 9.1.x before 9.1.19… Also affects postgresql-9.1
- CVE-2015-3165 Double free vulnerability in PostgreSQL before 9.0.20, 9.1.x before 9.1.16, 9.2.x before… Also affects postgresql-9.1
- CVE-2013-1899 Argument injection vulnerability in PostgreSQL 9.2.x before 9.2.4, 9.1.x before 9.1.9… Also affects postgresql-9.1
- CVE-2017-15098 Invalid json_populate_recordset or jsonb_populate_recordset function calls in PostgreSQL… Also affects postgresql-9.4
- CVE-2026-81644 DoS vulnerability in the preview service module. CWE-264