CVE-2026-10665

In Zephyr's WireGuard subsystem (subsys/net/lib/wireguard), wg_process_data_message() in wg_crypto.c linearizes an inbound transport-data payload into a fixed pool buffer of CONFIG_WIREGUARD_BUF_LEN bytes before decryption. The call net_buf_linearize(buf->data, data_len, pkt->buffer, ..., data_len) passed the attacker-derived data_len as both the destination capacity and the copy length, defeating the function's internal len = min(len, dst_len) bound. data_len is derived from the received UDP datagram length and is only lower-bounded by wg_ctrl_recv() (no upper bound). When data_len exceeds CONFIG_WIREGUARD_BUF_LEN — e.g. when the buffer length is lowered below the link MTU, on links with MTU above the buffer size, or via reassembled IPv4/IPv6 fragments that exceed it — the underlying memcpy writes past the end of the pool buffer, an out-of-bounds write (CWE-787). The overflow occurs before the Poly1305 authentication check, so it requires only a valid receiver session index rather than a valid authenticator, and is reachable by a malicious or compromised peer (or an on-path attacker driving an established session) over the network, yielding remote memory corruption and at minimum a reliable denial of service. The defect was present in the WireGuard implementation shipped in Zephyr 4.4.0. The fix adds an explicit data_len > CONFIG_WIREGUARD_BUF_LEN rejection and corrects the linearize call to pass net_buf_max_len(buf) as the destination capacity.
Configurations

Configuration 1 (hide)

OR cpe:2.3:o:zephyrproject:zephyr:4.4.0:rc1:*:*:*:*:*:*
cpe:2.3:o:zephyrproject:zephyr:4.4.0:rc2:*:*:*:*:*:*
cpe:2.3:o:zephyrproject:zephyr:4.4.0:rc3:*:*:*:*:*:*

History

24 Oct 2026, 22:10

Type Values Removed Values Added
Summary
  • (es) En el subsistema WireGuard de Zephyr (subsys/net/lib/wireguard), wg_process_data_message() en wg_crypto.c linealiza una carga útil de datos de transporte entrante en un búfer de grupo fijo de CONFIG_WIREGUARD_BUF_LEN bytes antes del descifrado. La llamada net_buf_linearize(buf -> data, data_len, pkt -> buffer, ..., data_len) pasó el data_len derivado del atacante como la capacidad de destino y la longitud de copia, anulando el límite interno de la función len = min(len, dst_len). data_len se deriva de la longitud del datagrama UDP recibido y solo está limitado inferiormente por wg_ctrl_recv() (sin límite superior). Cuando data_len excede CONFIG_WIREGUARD_BUF_LEN - por ejemplo, cuando la longitud del búfer se reduce por debajo de la MTU del enlace, en enlaces con MTU superior al tamaño del búfer, o a través de fragmentos IPv4/IPv6 reensamblados que lo exceden - el memcpy subyacente escribe más allá del final del búfer de grupo, una escritura fuera de límites (CWE-787). El desbordamiento ocurre antes de la verificación de autenticación Poly1305, por lo que solo requiere un índice de sesión de receptor válido en lugar de un autenticador válido, y es alcanzable por un par malicioso o comprometido (o un atacante en la ruta que controla una sesión establecida) a través de la red, lo que produce corrupción de memoria remota y como mínimo una denegación de servicio confiable. El defecto estaba presente en la implementación de WireGuard distribuida en Zephyr 4.4.0. La solución añade un rechazo explícito de data_len > CONFIG_WIREGUARD_BUF_LEN y corrige la llamada de linealización para pasar net_buf_max_len(buf) como la capacidad de destino.

Information

Published : 2026-07-12 17:16

Updated : 2026-10-24 22:10


NVD link : CVE-2026-10665

Mitre link : CVE-2026-10665

CVE.ORG link : CVE-2026-10665


JSON object : View

Products Affected

zephyrproject

  • zephyr
CWE
CWE-787

Out-of-bounds Write