Skip to main content
VulnerabilityPublished Updated

CVE-2024-1597: Libpgjava · pgjdbc, the PostgreSQL JDBC Driver, allows attacker to inject SQL if using

Affects libpgjavaSource GCVE Database

0
Compare
Authoritative record:CVE-2024-1597· Critical 10.0

Not known to be exploited · CVSS 10.0 Critical.

Data as of 5 Nov 2026, 00:01 UTC

CVSS 3.1 base score
10.0Critical
How severe the flaw is on the 0–10 CVSS scale.

Thin evidence

One scorer or none
CVSS scores by source
CNA (PostgreSQL)CVSS 3.110.0
EPSS
4.8% chance of exploitation in 30 days – higher than 91% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H

Exploitation evidence

  1. Disclosed: evidence found.

    CVE published 19 Feb 2024

  2. Detectable: no evidence on record.

    No public nuclei template indexed

  3. Weaponized: no evidence on record.

    No public exploit code indexed in Metasploit or Exploit-DB

  4. Exploited in the wild: no evidence on record.

    Not in CISA KEV and no source reports exploitation

  5. Observed by OffSeq Mirage: no evidence on record.

    No attack traffic recorded by OffSeq Mirage sensors

A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 4 Nov 2026.

What to do

Affected software

ProductAffectedFixed in
Ubuntu 22.04 LTSlibpgjavapkg:deb/ubuntu/libpgjava?arch=source&distro=jammyOther threatsAffected
  • 42.2.23-1 – 42.3.3-1
5 affected builds
Fixed in–
Ubuntu Pro 20.04 LTSlibpgjavapkg:deb/ubuntu/libpgjava?arch=source&distro=esm-apps/focalOther threatsAffected
  • 42.2.6-1 – 42.2.10-1ubuntu0.1~esm1
5 affected builds
Fixed in–
Ubuntu Pro 18.04 LTSlibpgjavapkg:deb/ubuntu/libpgjava?arch=source&distro=esm-apps/bionicOther threatsAffected
  • =9.4.1212-1
  • =9.4.1212-1ubuntu0.1~esm1
Fixed in–
Ubuntu 14.04 LTSlibpgjavapkg:deb/ubuntu/libpgjava?arch=source&distro=trustyOther threatsAffected
  • =9.2-1002-1
Fixed in–

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

AI-suggested

Users should upgrade to fixed versions 42.7.2, 42.6.1, 42.5.5, 42.4.4, 42.3.9, or 42.2.28 or later. Avoid using the PreferQueryMode=SIMPLE setting if possible, as the default mode is not vulnerable. Patch status is confirmed by the presence of fixed versions. No other mitigations are indicated.

Description

CVE-2024-1597 is a critical SQL injection vulnerability in the PostgreSQL JDBC Driver (pgjdbc) when using the non-default PreferQueryMode=SIMPLE setting. An attacker can craft a specific payload with numeric and string placeholders on the same line to inject SQL, bypassing parameterized query protections. This affects multiple versions of the driver prior to 42.7.2, 42.6.1, 42.5.5, 42.4.4, 42.3.9, and 42.2.28.

References

Community reviews

Loading reviews…