CVE-2026-107313
pgjdbc stores bytes of earlier messages in place of a large value on GSS-encrypted connections
Mitigation
- Upgrade pgjdbc to 42.7.6 or later.
- Vendor workaround: On 42.7.4 and 42.7.5, turn GSS encryption off with gssEncMode=disable and use TLS for transport encryption instead.
Who should check
- Anyone running pgjdbc >= 42.7.4, < 42.7.6
Vulnerability facts
- Affected
- pgjdbc >= 42.7.4, < 42.7.6
- Fixed in
- pgjdbc 42.7.6
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Remote, login needed
- CVSS
- 4.2 (v3.1, CNA)CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:NOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Network
- Attack complexity: High
- Privileges required: Low
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: Low
- Integrity impact: Low
- Availability impact: None
- EPSS
- 0.18% chance of exploitation in 30 days (percentile 5, 2026-11-26)
- CWE
- CWE-201
- Modified
Description
pgjdbc, the PostgreSQL JDBC Driver, versions 42.7.4 and 42.7.5 can send the previous contents of the GSS send buffer in place of the first part of a value on a connection with GSS encryption (gssEncMode=prefer or require), and the server stores the value without an error. The buffer is 16320 bytes with MIT Kerberos. The stored value then holds bytes of the messages the driver sent just before it on the same connection, such as the statement's SQL text, its other parameters, and earlier rows of the same batch, instead of the bytes the application supplied. Values at least as long as the buffer are affected when the driver writes them from a byte array: bind parameters set with setString, setBytes, or a ByteStreamWriter, CopyIn.writeToCopy, and LargeObject.write. Most such writes fail with an ArrayIndexOutOfBoundsException instead. The default, gssEncMode=allow, does not start GSS encryption, and connections without GSS encryption are not affected. Versions 42.7.3 and earlier are not affected, and 42.7.6 fixes the problem.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| pgjdbc | >= 42.7.4, < 42.7.6 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2026-107313. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-107313.md Affected: pgjdbc >= 42.7.4, < 42.7.6 Fixed in: pgjdbc 42.7.6 Steps: 1. Search this machine and project for pgjdbc: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
FAQ
Is CVE-2026-107313 being exploited?
There is no confirmed exploitation: CVE-2026-107313 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.18% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2026-107313?
Medium: CVSS 4.2 (v3.1, scored by CNA). Remote, login needed. The attack needs conditions outside the attacker's control, which makes it harder.
Which versions are affected by CVE-2026-107313?
pgjdbc >= 42.7.4, < 42.7.6.
Is there a fix for CVE-2026-107313?
Yes. Fixed in pgjdbc 42.7.6. Upgrade pgjdbc to 42.7.6 or later. Vendor workaround: On 42.7.4 and 42.7.5, turn GSS encryption off with gssEncMode=disable and use TLS for transport encryption instead.
How do I check if I'm affected by CVE-2026-107313?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.