In the Linux kernel, the following vulnerability has been resolved: btrfs: add a sanity check for btrfs root in btrfs_search_slot() Syzbot reports a null-ptr-deref in btrfs_search_slot(). The reproducer is using rescue=ibadroots, and the extent tree root is corrupted thus the extent tree is NULL. When scrub tries to search the extent tree to gather the needed extent info, btrfs_search_slot() doesn't check if the target root is NULL or not, resulting the null-ptr-deref. Add sanity check for btrfs root before using it in btrfs_search_slot().
History

Fri, 10 Jan 2025 01:45:00 +0000


Thu, 09 Jan 2025 21:30:00 +0000

Type Values Removed Values Added
First Time appeared Linux
Linux linux Kernel
Weaknesses CWE-476
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:6.13:rc1:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
Metrics cvssV3_1

{'score': 5.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H'}


Wed, 08 Jan 2025 18:00:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: btrfs: add a sanity check for btrfs root in btrfs_search_slot() Syzbot reports a null-ptr-deref in btrfs_search_slot(). The reproducer is using rescue=ibadroots, and the extent tree root is corrupted thus the extent tree is NULL. When scrub tries to search the extent tree to gather the needed extent info, btrfs_search_slot() doesn't check if the target root is NULL or not, resulting the null-ptr-deref. Add sanity check for btrfs root before using it in btrfs_search_slot().
Title btrfs: add a sanity check for btrfs root in btrfs_search_slot()
References

cve-icon MITRE

Status: PUBLISHED

Assigner: Linux

Published: 2025-01-08T17:49:13.121Z

Updated: 2025-01-08T17:49:13.121Z

Reserved: 2024-12-29T11:26:39.766Z

Link: CVE-2024-56774

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Analyzed

Published: 2025-01-08T18:15:18.213

Modified: 2025-01-09T21:00:24.247

Link: CVE-2024-56774

cve-icon Redhat

Severity : Low

Publid Date: 2025-01-08T00:00:00Z

Links: CVE-2024-56774 - Bugzilla