CVE-2026-134846: 
Java Análisis y mitigación de vulnerabilidades

Vista general

CVE-2026-134846 is a GSS encryption flaw in pgjdbc (the PostgreSQL JDBC Driver) that allows a network-positioned attacker to replay earlier server packets and downgrade encrypted connections to cleartext transmission. The driver fails to check the token state flags reported by GSSContext.unwrap(), and shares a single MessageProp instance between read and write operations, enabling both replay attacks and encryption downgrade. Affected versions are 42.2.15 through 42.7.14; version 42.7.15 resolves the issue. Only connections configured with gssEncMode=prefer or gssEncMode=require that successfully initiate GSS encryption are affected. The vulnerability carries a CVSS v3.1 base score of 6.5 (Medium) (GitHub Advisory).

Detalles técnicos

The root cause is twofold, classified under CWE-294 (Authentication Bypass by Capture-replay) and CWE-319 (Cleartext Transmission of Sensitive Information). First, the driver does not inspect the MessageProp flags set by GSSContext.unwrap() — which can indicate duplicate, old, out-of-sequence, or gap tokens — allowing a network attacker to replay an earlier server packet from the same connection as a valid response to the current query. Second, the driver reuses a single MessageProp object for both reading and writing; when an incoming integrity-only (non-private) server token clears the privacy flag on this shared object, all subsequent outgoing packets from the driver are signed but transmitted without encryption. Exploitation requires the attacker to be positioned on the network path between the client and the PostgreSQL server, and the connection must use gssEncMode=prefer or require with a server that accepts GSS encryption — the default mode since version 42.2.18 is allow, which does not initiate GSS encryption and is therefore not affected (GitHub Advisory).

Impacto

A successful attack allows an unauthenticated network attacker to inject false query responses by replaying earlier encrypted server packets, and to downgrade the connection so that subsequent SQL statements and bind parameters are transmitted in cleartext. This exposes database credentials, query data, and application logic to interception, and allows an attacker to manipulate query results delivered to the application. Integrity impact is rated High due to the ability to substitute arbitrary server replies; confidentiality impact is rated Low as the attacker must already be on the network path to observe the now-unencrypted traffic (GitHub Advisory).

Explotabilidad

A proof-of-concept exploit sequence is publicly documented in the official GitHub Security Advisory, demonstrating that a malicious backend can trigger the replay bug by sending the same sealed GSS token twice ([length][sealed token T] [length][sealed token T]). No runnable exploit code has been published, and there is no evidence of in-the-wild exploitation at this time. The EPSS score is 0.0, and the vulnerability is not listed in the CISA KEV catalog. NVD SSVC classifies exploitation status as "poc" with the attack rated as not automatable (GitHub Advisory).

Pasos de explotación

  1. Prerequisite verification: Confirm the target application uses pgjdbc versions 42.2.15–42.7.14 with gssEncMode=prefer or gssEncMode=require, and that the PostgreSQL server accepts GSS (Kerberos) encryption, establishing an encrypted JDBC connection.
  2. Network positioning: Position as an adversary-in-the-middle on the network path between the Java application and the PostgreSQL server (e.g., via ARP spoofing, rogue network device, or compromised network infrastructure).
  3. Capture a sealed GSS token: Intercept a legitimate server-to-client GSS-encrypted packet containing a sealed token T during an active connection.
  4. Replay attack — inject false response: When the client sends a new query, drop the legitimate server reply and instead deliver the previously captured sealed token T a second time. Because the driver does not check MessageProp duplicate/out-of-sequence flags from GSSContext.unwrap(), it accepts the replayed token as the valid response to the current query.
  5. Encryption downgrade — send integrity-only packet: As a malicious or compromised server, send one integrity-only (non-private) GSS token to the client. This clears the privacy flag on the driver's shared MessageProp object.
  6. Intercept plaintext SQL: All subsequent SQL statements and bind parameters sent by the driver are now signed but not encrypted, allowing the attacker to read database credentials, query content, and parameters in plaintext from the network (GitHub Advisory).

Indicadores de compromiso

  • Network: Duplicate or out-of-order GSS-encrypted packets observed on the wire between the application server and PostgreSQL server on port 5432; unexpected integrity-only (non-private) GSS tokens in the server-to-client stream; SQL traffic appearing in cleartext on the network after an initial GSS-encrypted handshake.
  • Logs: PostgreSQL server logs showing unexpected query results or mismatched query sequences; application-level errors or unexpected data returned from database queries that do not match issued SQL statements.
  • Process/Behavior: Java application receiving unexpected or stale query results inconsistent with the queries it issued; database operations returning data from prior queries rather than current ones.

Mitigación y soluciones alternativas

Upgrade pgjdbc (org.postgresql:postgresql) to version 42.7.15 or later, which fixes both the GSSContext.unwrap() flag-checking omission and the shared MessageProp issue. For systems that cannot patch immediately, set gssEncMode=disable in the JDBC connection configuration to prevent GSS encryption from being initiated — note this removes GSS encryption protections entirely. Additionally, implement network segmentation to restrict access to the network path between the application and PostgreSQL server, reducing the attack surface for adversary-in-the-middle scenarios. Note that the default gssEncMode=allow (the default since version 42.2.18) does not initiate GSS encryption and is not affected (GitHub Advisory).

Reacciones de la comunidad

The vulnerability was disclosed by the pgjdbc maintainer sehrope via a GitHub Security Advisory on November 23, 2026, with a Moderate severity rating. The advisory notes that only a party holding the session key (i.e., the server itself) can craft the integrity-only token required for the encryption downgrade, which limits the practical attacker pool. No significant independent researcher commentary or broad media coverage has been identified at this time (GitHub Advisory).

Recursos adicionales

Estado de corrección de la distribución Linux

Arreglar la disponibilidad en las principales distribuciones de Linux y sus lanzamientos.

Debian

Arreglado

bookworm

libpgjava

Afectados

sid

libpgjava: 42.7.15-1

Arreglado

trixie

libpgjava

Afectados

Ubuntu

Desconocido

bionic (esm-apps)

libpgjava

Desconocido

devel

libpgjava

Desconocido

focal (esm-apps)

libpgjava

Desconocido

jammy

libpgjava

Desconocido

jammy (esm-apps)

libpgjava

Desconocido

noble

libpgjava

Desconocido

noble (esm-apps)

libpgjava

Desconocido

resolute

libpgjava

Desconocido

RHEL / CentOS

Afectados

RHEL 9

No afectado

RHEL 10

No afectado

Fuente: Este informe se generó usando IA

Relacionado Java Vulnerabilidades:

CVE ID

Gravedad

Puntuación

Tecnologías

Nombre del componente

Exploit CISA KEV

Tiene solución

Fecha de publicación

CVE-2026-134844HIGH7.5
  • Java logoJava
  • flyway
NoSíNov 23, 2026
CVE-2026-134848HIGH7.4
  • Java logoJava
  • org.postgresql:postgresql
NoSíNov 23, 2026
CVE-2026-134845HIGH7.4
  • Java logoJava
  • flyway
NoSíNov 23, 2026
CVE-2026-134847MEDIUM6.5
  • Java logoJava
  • flyway
NoSíNov 23, 2026
CVE-2026-134846MEDIUM6.5
  • Java logoJava
  • keycloak-26.8
NoSíNov 23, 2026

Evaluación gratuita de vulnerabilidades

Haz un benchmark de tu postura de seguridad en la nube

Evalúa tus prácticas de seguridad en la nube en 9 dominios de seguridad para evaluar tu nivel de riesgo e identificar brechas en tus defensas.

Evaluación de solicitudes

Recursos adicionales de Wiz

Obtén una demostración personalizada

¿Listo para ver a Wiz en acción?

"La mejor experiencia de usuario que he visto en mi vida, proporciona una visibilidad completa de las cargas de trabajo en la nube."
David EstlickCISO
"Wiz proporciona un panel único para ver lo que ocurre en nuestros entornos en la nube."
Adam FletcherJefe de Seguridad
"Sabemos que si Wiz identifica algo como crítico, en realidad lo es."
Greg PoniatowskiJefe de Gestión de Amenazas y Vulnerabilidades