CVE-2024-47703
JSON

7.8high

bpf, lsm: Add check for BPF LSM return value

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

Description

In the Linux kernel, the following vulnerability has been resolved: bpf, lsm: Add check for BPF LSM return value A bpf prog returning a positive number attached to file_alloc_security hook makes kernel panic. This happens because file system can not filter out the positive number returned by the LSM prog using IS_ERR, and misinterprets this positive number as a file pointer. Given that hook file_alloc_security never returned positive number before the introduction of BPF LSM, and other BPF LSM hooks may encounter similar issues, this patch adds LSM return value check in verifier, to ensure no unexpected value is returned.

Affected

Product or packageVersionsReported by
Linux Linuxfrom 520b7aa00d8cd8e411ecc09f63a2acd90feb6d29 before 1050727d83e70449991c29dd1cf29fe936a63da3, from 520b7aa00d8cd8e411ecc09f63a2acd90feb6d29 before 27ca3e20fe80be85a92b10064dfeb56cb2564b1c, from 520b7aa00d8cd8e411ecc09f63a2acd90feb6d29 before 5d99e198be279045e6ecefe220f5c52f8ce9bfd5, 5.7
Not affected: before 5.7, from 6.10.13 up to 6.10.*, from 6.11.2 up to 6.11.*, from 6.12 up to *
CVE List
linux linux_kernelfrom 5.7 before 6.10.13, from 6.11 before 6.11.2NVD

All scores

Linux7.8high CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
NVD5.5medium CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Classification

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: bpf, lsm: Add check for BPF LSM return value A bpf prog returning a positive number attached to file_alloc_security hook makes kernel panic. This happens because file system can not filter out the positive number returned by the LSM prog using IS_ERR, and misinterprets this positive number as a file pointer. Given that hook file_alloc_security never returned positive number before the introduction of BPF LSM, and other BPF LSM hooks may encounter similar issues, this patch adds LSM return value check in verifier, to ensure no unexpected value is returned.

NVD (es)

En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: bpf, lsm: Agregar comprobación para el valor de retorno de BPF LSM Un programa bpf que devuelve un número positivo adjunto al gancho file_alloc_security hace que el kernel entre en pánico. Esto sucede porque el sistema de archivos no puede filtrar el número positivo devuelto por el programa LSM usando IS_ERR y malinterpreta este número positivo como un puntero de archivo. Dado que el gancho file_alloc_security nunca devolvió un número positivo antes de la introducción de BPF LSM, y otros ganchos BPF LSM pueden encontrar problemas similares, este parche agrega la comprobación del valor de retorno de LSM en el verificador, para garantizar que no se devuelva ningún valor inesperado.

References

Sources

SourceRecordLicence
CVE ListCVE-2024-47703 changed 2026-08-05CVE Terms of Use
NVDCVE-2024-47703 changed 2026-08-04Public domain