Skip to content
OpenAdvisories
Medium CVE-2022-26520 BIT-postgresql-jdbc-driver-2022-26520EUVD-2022-1351GHSA-673j-qm5f-xpv8GHSA-727h-hrw8-jg8q

pgjdbc Arbitrary File Write Vulnerability

Published Mar 7, 2022 · Updated Aug 3, 2024 · Assigned by mitre

Description

In pgjdbc before 42.3.3, an attacker (who controls the jdbc URL or properties) can call java.util.logging.FileHandler to write to arbitrary files through the loggerFile and loggerLevel connection properties. An example situation is that an attacker could create an executable JSP file under a Tomcat web root. NOTE: the vendor's position is that there is no pgjdbc vulnerability; instead, it is a vulnerability for any application to use the pgjdbc driver with untrusted connection properties

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 libpgjava 42.3.3-1 —
Debian 13 libpgjava 42.3.3-1 —
Debian 12 libpgjava 42.3.3-1 —
Debian 11 libpgjava 42.2.15-1+deb11u1 DSA-5196-1
Debian 10 libpgjava 42.2.5-2+deb10u1 DSA-5196-1
ReleasePackageFixed inAdvisory
SLES 15 SP4 postgresql-jdbc 42.2.25-150400.3.3.2 SUSE-SU-2022:2655-1
SLES 15 SP3 ongres-scram 2.1-150300.3.3.4 SUSE-FU-2022:2794-1
SLES 15 SP3 ongres-stringprep 1.1-150300.7.3.4 SUSE-FU-2022:2794-1
SLES 15 SP3 postgresql-jdbc 42.2.25-150300.3.5.2 SUSE-FU-2022:2794-1
Show 5 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SUSE Manager Server Module 4.2 ongres-scram 2.1-150300.3.3.4 SUSE-FU-2022:2794-1
SUSE Manager Server Module 4.2 ongres-stringprep 1.1-150300.7.3.4 SUSE-FU-2022:2794-1
SUSE Manager Server Module 4.2 postgresql-jdbc 42.2.25-150300.3.5.2 SUSE-FU-2022:2794-1
SUSE Manager Server Module 4.1 golang-github-QubitProducts-exporter_exporter 0.4.0-150200.6.12.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 golang-github-lusitaniae-apache_exporter 0.7.0-150200.2.6.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 golang-github-prometheus-node_exporter 1.3.0-150200.3.9.3 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 patterns-suse-manager 4.1-150200.6.12.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 postgresql-jdbc 42.2.10-150200.3.8.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 prometheus-exporters-formula 0.9.5-150200.3.31.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 prometheus-formula 0.3.7-150200.3.21.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 py27-compat-salt 3000.3-150200.6.24.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 spacecmd 4.1.18-150200.4.39.3 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 spacewalk-backend 4.1.31-150200.4.50.4 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 spacewalk-java 4.1.46-150200.3.71.5 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 spacewalk-setup 4.1.11-150200.3.18.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 spacewalk-utils 4.1.20-150200.3.30.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 spacewalk-web 4.1.34-150200.3.47.6 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 subscription-matcher 0.28-150200.3.15.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 susemanager 4.1.36-150200.3.52.1 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 susemanager-doc-indexes 4.1-150200.11.55.4 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 susemanager-docs_en 4.1-150200.11.55.2 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 susemanager-schema 4.1.26-150200.3.45.4 SUSE-SU-2022:2145-1
SUSE Manager Server Module 4.1 susemanager-sls 4.1.36-150200.3.64.2 SUSE-SU-2022:2145-1
SUSE Manager Server 4.1 release-notes-susemanager 4.1.15-150200.3.80.1 SUSE-SU-2022:2143-1
SUSE Manager Retail Branch Server 4.1 release-notes-susemanager-proxy 4.1.15-150200.3.56.1 SUSE-SU-2022:2143-1
SUSE Manager Proxy 4.1 release-notes-susemanager-proxy 4.1.15-150200.3.56.1 SUSE-SU-2022:2143-1
ReleasePackageFixed inAdvisory
openSUSE Leap 15.4 postgresql-jdbc 42.2.25-150400.3.3.2 SUSE-SU-2022:2655-1
openSUSE Leap 15.3 ongres-scram 2.1-150300.3.3.4 SUSE-FU-2022:2794-1
openSUSE Leap 15.3 ongres-stringprep 1.1-150300.7.3.4 SUSE-FU-2022:2794-1
openSUSE Leap 15.3 postgresql-jdbc 42.2.25-150300.3.5.2 SUSE-FU-2022:2794-1

Affected packages

EcosystemPackageAffectedFixedRecord
Maven org.postgresql:postgresql >= 42.1.0, < 42.3.3 42.3.3 GHSA-673j-qm5f-xpv8

Advisories 6

References