← Vulnerability feed

Vulnerability record · CVE-2020-25695 · published 16 November 2020

CVE-2020-25695: PostgreSQL privilege escalation via object creation in schema

Postgresql · Postgresql

PostgreSQL before 13.1, 12.5, 11.10, 10.15, 9.6.20 and 9.5.24 allows a user with permission to create non-temporary objects in at least one schema to execute arbitrary SQL functions as a superuser. This is a privilege escalation that undermines the database's role separation and exposes all data and functions the superuser can reach.

8.8 CVSS 3.1 High EPSS 46% · top 1.2% CWE-89 · SQL injection
8.8CVSS 3.1 base score, v2 6.5
46%EPSS exploitation probability, 30 days
NoNot in CISA KEV
2Affected product versions listed by NVD
10References
17 Jun 2026Last modified by NVD

Description

A flaw was found in PostgreSQL versions before 13.1, before 12.5, before 11.10, before 10.15, before 9.6.20 and before 9.5.24. An attacker having permission to create non-temporary objects in at least one schema can execute arbitrary SQL functions under the identity of a superuser. The highest threat from this vulnerability is to data confidentiality and integrity as well as system availability.

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Automated analysis

Generated by VULONE's analysis model from the NVD record, CISA KEV and EPSS data on 20 September 2026. Confidence: high.

high priorityCVSS 8.8 with high confidentiality, integrity and availability impact and a very high EPSS percentile, though exploitation requires an authenticated account with schema creation rights.

What it is

PostgreSQL before 13.1, 12.5, 11.10, 10.15, 9.6.20 and 9.5.24 allows a user with permission to create non-temporary objects in at least one schema to execute arbitrary SQL functions as a superuser. This is a privilege escalation that undermines the database's role separation and exposes all data and functions the superuser can reach.

Impact

An attacker with a low-privileged database account gains superuser-level execution, compromising confidentiality, integrity and availability of the entire database instance.

Attack surface

Reachable over the network via normal database connections (CVSS AV:N) by an authenticated user holding CREATE rights on any schema; no user interaction is required.

Exploitation

Not listed in CISA KEV and no public exploit references are tagged in the record, but EPSS is 0.4644 (98.8th percentile), indicating elevated predicted exploitation activity.

What to do

  • Upgrade PostgreSQL to 13.1, 12.5, 11.10, 10.15, 9.6.20, 9.5.24 or later as applicable.
  • Audit and revoke CREATE privileges on schemas from roles that do not require them.
  • Apply the vendor and distribution advisories (Debian, Gentoo, NetApp) for packaged deployments.
  • Restrict database network exposure and enforce least-privilege role design.
  • Monitor for unexpected creation of functions or objects in schemas by non-administrative roles.

Detection

  • Alert on CREATE FUNCTION or CREATE object events in schemas by roles that normally lack such rights.
  • Review PostgreSQL logs for privilege changes or superuser-context execution originating from low-privileged sessions.
  • Baseline schema object inventories and flag new non-temporary objects in unexpected schemas.
  • Correlate database audit logs with authentication events for unusual role-to-superuser activity.

This assessment is produced automatically and is not human-reviewed. Verify against the vendor advisory before acting on it.

Affected products

2 vulnerable configurations from NVD's CPE data, grouped by vendor and product.

References

Track CVE-2020-25695 inside VULONE

Watch it alongside the ransomware crews, C2 infrastructure and forum chatter that reference it, query it through the API and pull it into your SIEM over TAXII.

Start free Open in platform

Related vulnerabilities

Same products first, then exploited flaws of the same weakness class.

10.0CVE-2025-32433Erlang/OTP SSH server missing authentication allows remote code executionErlang/OTP SSH servers before OTP-27.3.3, OTP-26.2.5.11 and OTP-25.3.2.20 mishandle SSH protocol messages, letting an unauthenticated attacker execut…KEVEPSS 99%analysed10.0CVE-2025-24201Apple WebKit out-of-bounds write allows sandbox escapeCVE-2025-24201 is an out-of-bounds write in Apple's WebKit that was addressed with improved checks. Maliciously crafted web content may break out of …KEVEPSS 3.8%analysed10.0CVE-2021-44228Apache Log4j2 JNDI lookup remote code executionApache Log4j2 versions 2.0-beta9 through 2.15.0 (excluding 2.12.2, 2.12.3, and 2.3.1) do not protect against attacker-controlled LDAP and other JNDI …KEVEPSS 100%analysed9.8CVE-2026-24061GNU Inetutils telnetd argument injection allows remote auth bypasstelnetd in GNU Inetutils through 2.7 fails to sanitize the USER environment variable, so a value such as "-f root" is passed as an argument to login …KEVEPSS 99%analysed9.8CVE-2025-39682Linux kernel TLS zero-length record handling flaw on rx_listThe Linux kernel TLS receive path mishandles zero-length records that arrive from the rx_list, breaking the assumption that a record type change cann…KEVEPSS 2.9%analysed9.8CVE-2025-24813Apache Tomcat Default Servlet path equivalence enables RCE and file disclosureApache Tomcat mishandles path equivalence for names containing an internal dot, letting a remote unauthenticated attacker write files through the Def…KEVEPSS 100%analysed9.8CVE-2024-9680Mozilla Firefox and Thunderbird use-after-free in Animation timelinesA use-after-free flaw in Animation timelines allows an attacker to execute code in the content process of Firefox and Thunderbird. Mozilla reports ex…KEVEPSS 23%analysed9.8CVE-2023-46604Apache ActiveMQ OpenWire deserialization remote code executionThe Java OpenWire protocol marshaller in Apache ActiveMQ deserializes untrusted data, letting an attacker manipulate serialized class types so the br…KEVEPSS 100%analysed

Source: NIST National Vulnerability Database (record CVE-2020-25695), CISA KEV, FIRST EPSS (scores of 2026-09-26). This page is refreshed as NVD updates the record.