CVE-2024-26791

btrfs: dev-replace: properly validate device names

No CVSS score yet EPSS 0.25%

Published 4 Apr 2024 Updated 11 May 2026 CNA: Linux

Check your servers for CVE-2024-26791

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2024-26791 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

In the Linux kernel, the following vulnerability has been resolved:

btrfs: dev-replace: properly validate device names

There's a syzbot report that device name buffers passed to device replace are not properly checked for string termination which could lead to a read out of bounds in getname_kernel().

Add a helper that validates both source and target device name buffers. For devid as the source initialize the buffer to empty string in case something tries to read it later.

This was originally analyzed and fixed in a different way by Edward Adam Davis (see links).

Exploitation

EPSS 0.25%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 17.1% of all scored CVEs. Scores of 1 Dec 2026.

The assessment of CISA (SSVC, 10 Sep 2024):

Exploitation
none: CISA did not find evidence of exploitation or a public proof of concept
Automatable
no: each attack takes manual steps
Technical impact
partial: limited control or limited data

Affected products

As the CNA lists them.

ProductVersions
Linux
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before 11d7a2e429c02d51e2dc90713823ea8b8d3d3a84
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before c6652e20d7d783d060fe5f987eac7b5cabe31311
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before 2886fe308a83968dde252302884a1e63351cf16d
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before ab2d68655d0f04650bef09fee948ff80597c5fb9
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before f590040ce2b712177306b03c2a63b16f7d48d3c8
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before b1690ced4d2d8b28868811fb81cd33eee5aefee1
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before 343eecb4ff49a7b1cc1dfe86958a805cf2341cfb
affected from e93c89c1aaaaaec3487c4c18dd02360371790722, before 9845664b9ee47ce7ee7ea93caf47d39a9d4552c4
Other versions: unaffected
Linux
affected 3.8
unaffected before 3.8
unaffected from 4.19.309 up to and including 4.19.*
unaffected from 5.4.271 up to and including 5.4.*
unaffected from 5.10.212 up to and including 5.10.*
unaffected from 5.15.151 up to and including 5.15.*
unaffected from 6.1.81 up to and including 6.1.*
unaffected from 6.6.21 up to and including 6.6.*
unaffected from 6.7.9 up to and including 6.7.*
unaffected 6.8 and later
Other versions: affected

Is my server affected?

This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:

uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2024-26791 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2024-26791

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2024-26791
trivy image --scanners vuln IMAGE | grep CVE-2024-26791

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Other references

Source: the record CVE-2024-26791 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.