CVE-2026-107315

pgjdbc pads a value shorter than its declared length with bytes of earlier statements (rather than zeros)

5.3 medium EPSS 0.20%

Published 7 Oct 2026 Updated 8 Oct 2026 CNA: PostgreSQL

Check your servers for CVE-2026-107315

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2026-107315 affects pgjdbc, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

pgjdbc, the PostgreSQL JDBC Driver, versions 42.7.4 through 42.7.13 pads a value that is shorter than its declared length with bytes left in its send buffer instead of zeros, and the server stores those bytes as part of the value. The bytes are messages the driver sent earlier on the same connection: SQL text and parameter values of recent statements, which on a pooled connection can come from other requests. Each padded value can carry up to 8192 bytes of this traffic, or 16320 bytes on a connection with GSS encryption. The padding happens when an application declares a length larger than the data it supplies, through PreparedStatement.setObject with a ByteStreamWriter, CopyIn.writeToCopy, PGCopyOutputStream.write, LargeObject.write, or Blob.setBytes. The driver accepts these calls without an error. An attacker who can make the application store such a value and read it back can collect earlier traffic. Applications whose declared lengths always match their data are not affected. Versions 42.7.3 and earlier pad with zeros.

Severity (CVSS)

5.3 medium CVSS 3.1 from PostgreSQL (CNA)
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N
Attack vector
network: an attacker can reach the vulnerable part over the network, often from the internet
Attack complexity
high: an attack depends on conditions outside the control of the attacker, such as a race
Privileges required
low: the attacker needs an ordinary user account
User interaction
none: nobody has to click or open anything
Scope
unchanged: the damage stays inside the vulnerable component
Impact
confidentiality high, integrity none, availability none: what an attacker can read (confidentiality), change (integrity) or stop (availability)

Exploitation

EPSS 0.20%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 10.8% of all scored CVEs. Scores of 1 Dec 2026.

The assessment of CISA (SSVC, 8 Oct 2026):

Exploitation
poc: a proof of concept is public
Automatable
no: each attack takes manual steps
Technical impact
partial: limited control or limited data

Weakness

  • CWE-201 Insertion of Sensitive Information Into Sent Data
  • CWE-226 Sensitive Information in Resource Not Removed Before Reuse

Affected products

As the CNA lists them.

ProductVersions
pgjdbc
package org.postgresql:postgresql
affected from 42.7.4 up to and including 42.7.13
Other versions: unaffected

Is my server affected?

Find the installed version of pgjdbc and compare it with the fixed version of your distribution. Distributions often fix a CVE in a package version of their own, so the version number of the upstream project can mislead.

Debian, Ubuntu

dpkg -l | grep -i pgjdbc
# packages whose changelog names the CVE (fixed in the installed version)
zgrep -l CVE-2026-107315 /usr/share/doc/*/changelog.Debian.gz
# Ubuntu
pro fix CVE-2026-107315

RHEL, Rocky, Alma, Fedora

rpm -q pgjdbc
# lists the advisory while the fix is not installed
dnf updateinfo list --cve CVE-2026-107315

Alpine

apk list --installed | grep -i pgjdbc

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2026-107315
trivy image --scanners vuln IMAGE | grep CVE-2026-107315

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Exploits and proof of concept

Source: the record CVE-2026-107315 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.