CVE-2026-23067
JSON

5.5medium

iommu/io-pgtable-arm: fix size_t signedness bug in unmap path

Severity
5.5medium CVSS:3.1 by NVD
Exploit likelihood
0.13% (higher than 2% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: iommu/io-pgtable-arm: fix size_t signedness bug in unmap path __arm_lpae_unmap() returns size_t but was returning -ENOENT (negative error code) when encountering an unmapped PTE. Since size_t is unsigned, -ENOENT (typically -2) becomes a huge positive value (0xFFFFFFFFFFFFFFFE on 64-bit systems). This corrupted value propagates through the call chain: __arm_lpae_unmap() returns -ENOENT as size_t -> arm_lpae_unmap_pages() returns it -> __iommu_unmap() adds it to iova address -> iommu_pgsize() triggers BUG_ON due to corrupted iova This can cause IOVA address overflow in __iommu_unmap() loop and trigger BUG_ON in iommu_pgsize() from invalid address alignment. Fix by returning 0 instead of -ENOENT. The WARN_ON already signals the error condition, and returning 0 (meaning "nothing unmapped") is the correct semantic for size_t return type. This matches the behavior of other io-pgtable implementations (io-pgtable-arm-v7s, io-pgtable-dart) which return 0 on error conditions.

Affected

Product or packageVersionsReported by
Linux Linuxfrom 3318f7b5cefbff96b1bb49584ac38d2c9997a830 before 41ec6988547819756fb65e94fc24f3e0dddf84ac, from 3318f7b5cefbff96b1bb49584ac38d2c9997a830 before 374e7af67d9d9d6103c2cfc8eb32abfecf3a2fd8, 6.16
Not affected: before 6.16, from 6.18.8 up to 6.18.*, from 6.19 up to *
CVE List
linux linux_kernelfrom 6.16 before 6.18.8, 6.19NVD

Classification

CWE-617

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

What each source says

CVE List

In the Linux kernel, the following vulnerability has been resolved: iommu/io-pgtable-arm: fix size_t signedness bug in unmap path __arm_lpae_unmap() returns size_t but was returning -ENOENT (negative error code) when encountering an unmapped PTE. Since size_t is unsigned, -ENOENT (typically -2) becomes a huge positive value (0xFFFFFFFFFFFFFFFE on 64-bit systems). This corrupted value propagates through the call chain: __arm_lpae_unmap() returns -ENOENT as size_t -> arm_lpae_unmap_pages() returns it -> __iommu_unmap() adds it to iova address -> iommu_pgsize() triggers BUG_ON due to corrupted iova This can cause IOVA address overflow in __iommu_unmap() loop and trigger BUG_ON in iommu_pgsize() from invalid address alignment. Fix by returning 0 instead of -ENOENT. The WARN_ON already signals the error condition, and returning 0 (meaning "nothing unmapped") is the correct semantic for size_t return type. This matches the behavior of other io-pgtable implementations (io-pgtable-arm-v7s, io-pgtable-dart) which return 0 on error conditions.

NVD (es)

En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta: iommu/io-pgtable-arm: corrección de error de signo de size_t en la ruta de desmapeo __arm_lpae_unmap() devuelve size_t pero estaba devolviendo -ENOENT (código de error negativo) al encontrar una PTE no mapeada. Dado que size_t no tiene signo, -ENOENT (típicamente -2) se convierte en un valor positivo enorme (0xFFFFFFFFFFFFFFFE en sistemas de 64 bits). Este valor corrupto se propaga a través de la cadena de llamadas: __arm_lpae_unmap() devuelve -ENOENT como size_t -> arm_lpae_unmap_pages() lo devuelve -> __iommu_unmap() lo añade a la dirección iova -> iommu_pgsize() activa BUG_ON debido a iova corrupta Esto puede causar un desbordamiento de dirección IOVA en el bucle de __iommu_unmap() y activar BUG_ON en iommu_pgsize() por una alineación de dirección inválida. Se corrige devolviendo 0 en lugar de -ENOENT. El WARN_ON ya señala la condición de error, y devolver 0 (que significa 'nada desmapeado') es la semántica correcta para el tipo de retorno size_t. Esto coincide con el comportamiento de otras implementaciones de io-pgtable (io-pgtable-arm-v7s, io-pgtable-dart) que devuelven 0 en condiciones de error.

References

Sources

SourceRecordLicence
CVE ListCVE-2026-23067 changed 2026-11-05CVE Terms of Use
NVDCVE-2026-23067 changed 2026-11-05Public domain