# CVE-2024-40972: ext4: do not create EA inode under buffer lock

- Severity: Medium 5.5 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.22%, higher than 13% of CVEs (2026-12-01)
- Published: 2024-07-12T12:32:10.102Z
- Modified: 2026-06-17T07:46:59.553Z
- Weaknesses: CWE-667
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: Linux

## Description

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

ext4: do not create EA inode under buffer lock

ext4_xattr_set_entry() creates new EA inodes while holding buffer lock
on the external xattr block. This is problematic as it nests all the
allocation locking (which acquires locks on other buffers) under the
buffer lock. This can even deadlock when the filesystem is corrupted and
e.g. quota file is setup to contain xattr block as data block. Move the
allocation of EA inode out of ext4_xattr_set_entry() into the callers.

(As written by CVE List.)

## Affected

- Linux Linux: from e50e5129f384ae282adebfb561189cdb19b81cee before 0752e7fb549d90c33b4d4186f11cfd25a556d1dd; from e50e5129f384ae282adebfb561189cdb19b81cee before 737fb7853acd5bc8984f6f42e4bfba3334be8ae1; from e50e5129f384ae282adebfb561189cdb19b81cee before 111103907234bffd0a34fba070ad9367de058752; from e50e5129f384ae282adebfb561189cdb19b81cee before 0a46ef234756dca04623b7591e8ebb3440622f0b; 4.13 (not affected: before 4.13; from 6.1.107 up to 6.1.*; from 6.6.47 up to 6.6.*; from 6.9.7 up to 6.9.*; from 6.10 up to *)
- linux linux_kernel: before 6.1.107; from 6.2 before 6.6.47; from 6.7 before 6.9.7

## References

- <https://git.kernel.org/stable/c/0752e7fb549d90c33b4d4186f11cfd25a556d1dd> (patch)
- <https://git.kernel.org/stable/c/737fb7853acd5bc8984f6f42e4bfba3334be8ae1> (patch)
- <https://git.kernel.org/stable/c/111103907234bffd0a34fba070ad9367de058752> (patch)
- <https://git.kernel.org/stable/c/0a46ef234756dca04623b7591e8ebb3440622f0b> (patch)
- <https://lists.debian.org/debian-lts-announce/2025/01/msg00001.html>

## Sources

- CVE List: [CVE-2024-40972](https://www.cve.org/CVERecord?id=CVE-2024-40972), CVE Terms of Use, modified 2026-05-11
- NVD: [CVE-2024-40972](https://nvd.nist.gov/vuln/detail/CVE-2024-40972), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2024-40972 · Whole record: https://cve.day/CVE-2024-40972.json · Rebuilt by cve.day 2026-11-25T22:58:42.868Z
