CVE-2026-43233
JSON

8.2high

netfilter: nf_conntrack_h323: fix OOB read in decode_choice()

Severity
8.2high CVSS:3.1 by Linux
Exploit likelihood
0.46% (higher than 41% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: netfilter: nf_conntrack_h323: fix OOB read in decode_choice() In decode_choice(), the boundary check before get_len() uses the variable `len`, which is still 0 from its initialization at the top of the function: unsigned int type, ext, len = 0; ... if (ext || (son->attr & OPEN)) { BYTE_ALIGN(bs); if (nf_h323_error_boundary(bs, len, 0)) /* len is 0 here */ return H323_ERROR_BOUND; len = get_len(bs); /* OOB read */ When the bitstream is exactly consumed (bs->cur == bs->end), the check nf_h323_error_boundary(bs, 0, 0) evaluates to (bs->cur + 0 > bs->end), which is false. The subsequent get_len() call then dereferences *bs->cur++, reading 1 byte past the end of the buffer. If that byte has bit 7 set, get_len() reads a second byte as well. This can be triggered remotely by sending a crafted Q.931 SETUP message with a User-User Information Element containing exactly 2 bytes of PER-encoded data ({0x08, 0x00}) to port 1720 through a firewall with the nf_conntrack_h323 helper active. The decoder fully consumes the PER buffer before reaching this code path, resulting in a 1-2 byte heap-buffer-overflow read confirmed by AddressSanitizer. Fix this by checking for 2 bytes (the maximum that get_len() may read) instead of the uninitialized `len`. This matches the pattern used at every other get_len() call site in the same file, where the caller checks for 2 bytes of available data before calling get_len().

Affected

Product or packageVersionsReported by
Linux Linuxfrom ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before bcb50aa0b8f2b74a9fe5a1c7bee6f2657a288041, from ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before 2a3aac4205e7d2f1aca2e3827de8cdd517d36c4a, from ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before 81f2fc5b0d0cf4696146f00f837596d10b92dead, from ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before 7ef82863d42261817a6394c6c881bd6757a70f16, from ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before 53d32735d77ab56cc3fc7bd53a7d099418f19be1, from ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before f0a83d0a4b7c127d32ac06d607a9214937716129, from ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before 35f1943d242e1b9f0b6e91c0c93bfb293a9f8224, from ec8a8f3c31ddef0a7d9626c4b8a4baa30f3b80aa before baed0d9ba91d4f390da12d5039128ee897253d60 and 1 more
Not affected: before 4.15, from 5.10.252 up to 5.10.*, from 5.15.202 up to 5.15.*, from 6.1.165 up to 6.1.*, from 6.6.128 up to 6.6.*, from 6.12.75 up to 6.12.*
CVE List
linux linux_kernelfrom 4.15.1 before 5.10.252, from 5.11 before 5.15.202, from 5.16 before 6.1.165, from 6.2 before 6.6.128, from 6.7 before 6.12.75, from 6.13 before 6.18.16, from 6.19 before 6.19.6, 4.15 and 1 moreNVD

Classification

CWE-125

SSVC (CISA-ADP): exploitation none, automatable yes, technical impact partial.

What each source says

CVE List

In the Linux kernel, the following vulnerability has been resolved: netfilter: nf_conntrack_h323: fix OOB read in decode_choice() In decode_choice(), the boundary check before get_len() uses the variable `len`, which is still 0 from its initialization at the top of the function: unsigned int type, ext, len = 0; ... if (ext || (son->attr & OPEN)) { BYTE_ALIGN(bs); if (nf_h323_error_boundary(bs, len, 0)) /* len is 0 here */ return H323_ERROR_BOUND; len = get_len(bs); /* OOB read */ When the bitstream is exactly consumed (bs->cur == bs->end), the check nf_h323_error_boundary(bs, 0, 0) evaluates to (bs->cur + 0 > bs->end), which is false. The subsequent get_len() call then dereferences *bs->cur++, reading 1 byte past the end of the buffer. If that byte has bit 7 set, get_len() reads a second byte as well. This can be triggered remotely by sending a crafted Q.931 SETUP message with a User-User Information Element containing exactly 2 bytes of PER-encoded data ({0x08, 0x00}) to port 1720 through a firewall with the nf_conntrack_h323 helper active. The decoder fully consumes the PER buffer before reaching this code path, resulting in a 1-2 byte heap-buffer-overflow read confirmed by AddressSanitizer. Fix this by checking for 2 bytes (the maximum that get_len() may read) instead of the uninitialized `len`. This matches the pattern used at every other get_len() call site in the same file, where the caller checks for 2 bytes of available data before calling get_len().

NVD (es)

En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta: netfilter: nf_conntrack_h323: corrección de lectura OOB en decode_choice() En decode_choice(), la comprobación de límites antes de get_len() utiliza la variable ’len’, que sigue siendo 0 desde su inicialización al principio de la función: unsigned int type, ext, len = 0; ... if (ext || (son -> attr & OPEN)) { BYTE_ALIGN(bs); if (nf_h323_error_boundary(bs, len, 0)) /* len es 0 aquí */ return H323_ERROR_BOUND; len = get_len(bs); /* Lectura OOB */ Cuando el flujo de bits se consume exactamente (bs -> cur == bs -> end), la comprobación nf_h323_error_boundary(bs, 0, 0) se evalúa como (bs -> cur + 0 > bs -> end), lo cual es falso. La llamada subsiguiente a get_len() luego desreferencia bs -> cur++, leyendo 1 byte más allá del final del búfer. Si ese byte tiene el bit 7 activado, get_len() lee un segundo byte también. Esto puede ser activado remotamente enviando un mensaje Q.931 SETUP manipulado con un Elemento de Información de Usuario-Usuario que contiene exactamente 2 bytes de datos codificados en PER ({0x08, 0x00}) al puerto 1720 a través de un cortafuegos con el ayudante nf_conntrack_h323 activo. El decodificador consume completamente el búfer PER antes de alcanzar esta ruta de código, lo que resulta en una lectura de desbordamiento de búfer de pila (heap-buffer-overflow) de 1-2 bytes confirmada por AddressSanitizer. Solucione esto comprobando 2 bytes (el máximo que get_len() puede leer) en lugar de la variable ’len’ no inicializada. Esto coincide con el patrón utilizado en cada otro sitio de llamada a get_len() en el mismo archivo, donde el llamador comprueba si hay 2 bytes de datos disponibles antes de llamar a get_len().

References

Sources

SourceRecordLicence
CVE ListCVE-2026-43233 changed 2026-10-19CVE Terms of Use
NVDCVE-2026-43233 changed 2026-11-11Public domain