CVE-2022-0959 pgAdmin 4 Path Traversal vulnerability

Medium 6.5 Published Updated

Authenticated users can exploit path traversal to upload files to arbitrary locations, potentially leading to code execution.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2022-0959?

CVE-2022-0959 is a medium-severity path traversal vulnerability in pgadmin, published on 16 Mar 2022. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

A malicious, but authorised and authenticated user can construct an HTTP request using their existing CSRF token and session cookie to manually upload files to any location that the operating system user account under which pgAdmin is running has permission to write.

Weakness: CWE-22, CWE-434

Which versions are affected by CVE-2022-0959?

3 open source packages ship an affected version, including pgadmin4. It affects 1 product.

PackageAffectedFixed in
pgadmin4 PyPIAll versions6.7
pgadmin4 PyPIAll versions6.7
pgadmin4 PyPIAll versions6.7
Linux distribution packages (3)
pgadmin4 SUSE:Linux Enterprise Module for Server Applications 15 SP3All versions4.30-150300.3.3.1
pgadmin4 openSUSE:Leap 15.3All versions4.30-150300.3.3.1
pgadmin4 openSUSE:Leap 15.4All versions4.30-150300.3.3.1

Products include Pgadmin Pgadmin 4.

How do I fix CVE-2022-0959?

Upgrade pgadmin4 to 6.7 or later.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2022-0959 being exploited?

There is no known exploitation of CVE-2022-0959 in the wild and no public exploit code.

Sources

Also known as GHSA-cr8c-972v-rmp3, MGASA-2022-0257, PYSEC-2026-729, SUSE-SU-2022:1541-1.

Is CVE-2022-0959 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free