CVE-2020-14350: Untrusted Search Path in PostgreSQL

org.postgresql:postgresql Updated 02 Oct 2025

Summary

15/02/2022
MODERATE
Yes i
Moderate
7.3

GHSA-6v9v-3f4c-cjgx: Untrusted Search Path in PostgreSQL. Affects org.postgresql:postgresql versions < 12.4. Fixed in 12.4. How to fix ↓

Free scan

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.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

PostgreSQL is an open-source relational database management system known for its robustness, extensibility, and adherence to SQL standards. It is widely used in various applications and industries. This vulnerability affects versions before 12.4, 11.9, 10.14, 9.6.19, and 9.5.23 of PostgreSQL. The vulnerability arises from certain PostgreSQL extensions not securely using the search_path during their installation script.

Vulnerability Detail

The vulnerability allows an attacker with sufficient privileges to exploit the flawed installation script of certain PostgreSQL extensions. By tricking an administrator into executing a specially crafted script during the installation or update of such extensions, the attacker can execute arbitrary code. This can lead to various consequences, including unauthorized access, data manipulation, privilege escalation, and potential compromise of the entire PostgreSQL instance.

How To Fix

Latest published version: 42.7.14 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

12.4

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a workaround, administrators can manually review and modify the installation scripts of PostgreSQL extensions to ensure the safe usage of search_path. This involves carefully inspecting the scripts and validating the search_path usage to prevent any unauthorized or malicious code execution. However, applying the official updates is strongly recommended to address the vulnerability comprehensively.

Conclusion

The vulnerability in PostgreSQL versions before 12.4, 11.9, 10.14, 9.6.19, and 9.5.23 allows an attacker to execute arbitrary code by exploiting the flawed installation script of certain extensions. To mitigate this risk, it is crucial to update PostgreSQL to the recommended versions. Administrators can also manually review and modify installation scripts as a temporary workaround. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for org.postgresql:postgresql →

Share this vulnerability

FAQ

PostgreSQL is an open-source relational database management system known for its robustness, extensibility, and adherence to SQL standards. It is widely used in various applications and industries.

Versions before 12.4, 11.9, 10.14, 9.6.19, and 9.5.23 of PostgreSQL are affected by this vulnerability.

By exploiting this vulnerability, an attacker with sufficient privileges can execute arbitrary code, leading to unauthorized access, data manipulation, privilege escalation, and potential compromise of the entire PostgreSQL instance.

To fix this vulnerability, it is recommended to update PostgreSQL to version 12.4, 11.9, 10.14, 9.6.19, or 9.5.23, depending on the affected version. Applying the official updates is crucial to mitigate the risk of exploitation.

As a workaround, administrators can manually review and modify the installation scripts of PostgreSQL extensions to ensure the safe usage of search_path. However, applying the official updates is strongly recommended.

Related vulnerabilities

Recent vulnerabilities recorded for org.postgresql:postgresql.

How To Fix

Latest published version: 42.7.14 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

12.4

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback