CVE-2024-26727
published 2024-04-03CVE-2024-26727: In the Linux kernel, the following vulnerability has been resolved: btrfs: do not ASSERT() if the newly created subvolume already got read [BUG] There is a…
PriorityP420medium5.5CVSS 3.1
AVLACLPRLUINSUCNINAH
EPSS
0.23%
13.7th percentile
In the Linux kernel, the following vulnerability has been resolved:
btrfs: do not ASSERT() if the newly created subvolume already got read
[BUG]
There is a syzbot crash, triggered by the ASSERT() during subvolume
creation:
assertion failed: !anon_dev, in fs/btrfs/disk-io.c:1319
------------[ cut here ]------------
kernel BUG at fs/btrfs/disk-io.c:1319!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
RIP: 0010:btrfs_get_root_ref.part.0+0x9aa/0xa60
btrfs_get_new_fs_root+0xd3/0xf0
create_subvol+0xd02/0x1650
btrfs_mksubvol+0xe95/0x12b0
__btrfs_ioctl_snap_create+0x2f9/0x4f0
btrfs_ioctl_snap_create+0x16b/0x200
btrfs_ioctl+0x35f0/0x5cf0
__x64_sys_ioctl+0x19d/0x210
do_syscall_64+0x3f/0xe0
entry_SYSCALL_64_after_hwframe+0x63/0x6b
---[ end trace 0000000000000000 ]---
[CAUSE]
During create_subvol(), after inserting root item for the newly created
subvolume, we would trigger btrfs_get_new_fs_root() to get the
btrfs_root of that subvolume.
The idea here is, we have preallocated an anonymous device number for
the subvolume, thus we can assign it to the new subvolume.
But there is really nothing preventing things like backref walk to read
the new subvolume.
If that happens before we call btrfs_get_new_fs_root(), the subvolume
would be read out, with a new anonymous device number assigned already.
In that case, we would trigger ASSERT(), as we really expect no one to
read out that subvolume (which is not yet accessible from the fs).
But things like backref walk is still possible to trigger the read on
the subvolume.
Thus our assumption on the ASSERT() is not correct in the first place.
[FIX]
Fix it by removing the ASSERT(), and just free the @anon_dev, reset it
to 0, and continue.
If the subvolume tree is read out by something else, it should have
already get a new anon_dev assigned thus we only need to free the
preallocated one.
Affected
21 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| debian | debian_linux | — | — |
| debian | linux | < linux 6.1.82-1 (bookworm) | linux 6.1.82-1 (bookworm) |
| linux | linux | — | — |
| linux | linux | — | — |
| linux | linux | >= 2dfb1e43f57dd3aeaa66f7cf05d068db2d4c8788 < 3f5d47eb163bceb1b9e613c9003bae5fefc0046f | 3f5d47eb163bceb1b9e613c9003bae5fefc0046f |
| linux | linux | >= 2dfb1e43f57dd3aeaa66f7cf05d068db2d4c8788 < e31546b0f34af21738c4ceac47d662c00ee6382f | e31546b0f34af21738c4ceac47d662c00ee6382f |
| linux | linux | >= 2dfb1e43f57dd3aeaa66f7cf05d068db2d4c8788 < 66b317a2fc45b2ef66527ee3f8fa08fb5beab88d | 66b317a2fc45b2ef66527ee3f8fa08fb5beab88d |
| linux | linux | >= 2dfb1e43f57dd3aeaa66f7cf05d068db2d4c8788 < 833775656d447c545133a744a0ed1e189ce61430 | 833775656d447c545133a744a0ed1e189ce61430 |
| linux | linux | >= 2dfb1e43f57dd3aeaa66f7cf05d068db2d4c8788 < 5a172344bfdabb46458e03708735d7b1a918c468 | 5a172344bfdabb46458e03708735d7b1a918c468 |
| linux | linux | >= 2dfb1e43f57dd3aeaa66f7cf05d068db2d4c8788 < e03ee2fe873eb68c1f9ba5112fee70303ebf9dfb | e03ee2fe873eb68c1f9ba5112fee70303ebf9dfb |
| linux | linux | >= 5.8.3 < 5.9 | 5.9 |
| linux | linux_kernel | — | — |
| linux | linux_kernel | >= 0 < 5.10.216-1 | 5.10.216-1 |
| linux | linux_kernel | >= 0 < 6.1.82-1 | 6.1.82-1 |
| linux | linux_kernel | >= 0 < 6.7.7-1 | 6.7.7-1 |
| linux | linux_kernel | >= 0 < 6.7.7-1 | 6.7.7-1 |
| linux | linux_kernel | >= 5.11 < 5.15.149 | 5.15.149 |
| linux | linux_kernel | >= 5.16 < 6.1.79 | 6.1.79 |
| linux | linux_kernel | >= 5.9 < 5.10.210 | 5.10.210 |
| linux | linux_kernel | >= 6.2 < 6.6.18 | 6.6.18 |
| linux | linux_kernel | >= 6.7 < 6.7.6 | 6.7.6 |
CVSS provenance
nvdv3.15.5MEDIUMCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
osv5.5MEDIUM
vendor_debian5.5MEDIUM
vendor_redhat5.5MEDIUM
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
Red Hat
kernel: btrfs: do not ASSERT() if the newly created subvolume already got read
vendor_redhat·2024-04-03·CVSS 5.5
CVE-2024-26727 [MEDIUM] CWE-20 kernel: btrfs: do not ASSERT() if the newly created subvolume already got read
kernel: btrfs: do not ASSERT() if the newly created subvolume already got read
In the Linux kernel, the following vulnerability has been resolved:
btrfs: do not ASSERT() if the newly created subvolume already got read
[BUG]
There is a syzbot crash, triggered by the ASSERT() during subvolume
creation:
assertion failed: !anon_dev, in fs/btrfs/disk-io.c:1319
------------[ cut here ]------------
kernel BUG at fs/btrfs/disk-io.c:1319!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
RIP: 0010:btrfs_get_root_ref.part.0+0x9aa/0xa60
btrfs_get_new_fs_root+0xd3/0xf0
create_subvol+0xd02/0x1650
btrfs_mksubvol+0xe95/0x12b0
__btrfs_ioctl_snap_create+0x2f9/0x4f0
btrfs_ioctl_snap_create+0x16b/0x200
btrfs_ioctl+0x35f0/0x5cf0
__x64_sys_ioctl+0x19d/0x210
do_syscall_64+0x3f/0xe0
entry_SYSCALL_64_after_hwframe+0x
Debian
CVE-2024-26727: linux - In the Linux kernel, the following vulnerability has been resolved: btrfs: do n...
vendor_debian·2024·CVSS 5.5
CVE-2024-26727 [MEDIUM] CVE-2024-26727: linux - In the Linux kernel, the following vulnerability has been resolved: btrfs: do n...
In the Linux kernel, the following vulnerability has been resolved: btrfs: do not ASSERT() if the newly created subvolume already got read [BUG] There is a syzbot crash, triggered by the ASSERT() during subvolume creation: assertion failed: !anon_dev, in fs/btrfs/disk-io.c:1319 ------------[ cut here ]------------ kernel BUG at fs/btrfs/disk-io.c:1319! invalid opcode: 0000 [#1] PREEMPT SMP KASAN RIP: 0010:btrfs_get_root_ref.part.0+0x9aa/0xa60 btrfs_get_new_fs_root+0xd3/0xf0 create_subvol+0xd02/0x1650 btrfs_mksubvol+0xe95/0x12b0 __btrfs_ioctl_snap_create+0x2f9/0x4f0 btrfs_ioctl_snap_create+0x16b/0x200 btrfs_ioctl+0x35f0/0x5cf0 __x64_sys_ioctl+0x19d/0x210 do_syscall_64+0x3f/0xe0 entry_SYSCALL_64_after_hwframe+0x63/0x6b ---[ end trace 0000000000000000 ]--- [CAUSE] During create_subvol(), afte
GHSA
GHSA-w9mj-34hr-82rj: In the Linux kernel, the following vulnerability has been resolved:
btrfs: do not ASSERT() if the newly created subvolume already got read
[BUG]
The
ghsa_unreviewed·2024-04-03
CVE-2024-26727 [MEDIUM] CWE-617 GHSA-w9mj-34hr-82rj: In the Linux kernel, the following vulnerability has been resolved:
btrfs: do not ASSERT() if the newly created subvolume already got read
[BUG]
The
In the Linux kernel, the following vulnerability has been resolved:
btrfs: do not ASSERT() if the newly created subvolume already got read
[BUG]
There is a syzbot crash, triggered by the ASSERT() during subvolume
creation:
assertion failed: !anon_dev, in fs/btrfs/disk-io.c:1319
------------[ cut here ]------------
kernel BUG at fs/btrfs/disk-io.c:1319!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
RIP: 0010:btrfs_get_root_ref.part.0+0x9aa/0xa60
btrfs_get_new_fs_root+0xd3/0xf0
create_subvol+0xd02/0x1650
btrfs_mksubvol+0xe95/0x12b0
__btrfs_ioctl_snap_create+0x2f9/0x4f0
btrfs_ioctl_snap_create+0x16b/0x200
btrfs_ioctl+0x35f0/0x5cf0
__x64_sys_ioctl+0x19d/0x210
do_syscall_64+0x3f/0xe0
entry_SYSCALL_64_after_hwframe+0x63/0x6b
---[ end trace 0000000000000000 ]---
[CAUSE]
During create_subvol(),
OSV
CVE-2024-26727: In the Linux kernel, the following vulnerability has been resolved: btrfs: do not ASSERT() if the newly created subvolume already got read [BUG] There
osv·2024-04-03·CVSS 5.5
CVE-2024-26727 [MEDIUM] CVE-2024-26727: In the Linux kernel, the following vulnerability has been resolved: btrfs: do not ASSERT() if the newly created subvolume already got read [BUG] There
In the Linux kernel, the following vulnerability has been resolved: btrfs: do not ASSERT() if the newly created subvolume already got read [BUG] There is a syzbot crash, triggered by the ASSERT() during subvolume creation: assertion failed: !anon_dev, in fs/btrfs/disk-io.c:1319 ------------[ cut here ]------------ kernel BUG at fs/btrfs/disk-io.c:1319! invalid opcode: 0000 [#1] PREEMPT SMP KASAN RIP: 0010:btrfs_get_root_ref.part.0+0x9aa/0xa60 btrfs_get_new_fs_root+0xd3/0xf0 create_subvol+0xd02/0x1650 btrfs_mksubvol+0xe95/0x12b0 __btrfs_ioctl_snap_create+0x2f9/0x4f0 btrfs_ioctl_snap_create+0x16b/0x200 btrfs_ioctl+0x35f0/0x5cf0 __x64_sys_ioctl+0x19d/0x210 do_syscall_64+0x3f/0xe0 entry_SYSCALL_64_after_hwframe+0x63/0x6b ---[ end trace 0000000000000000 ]--- [CAUSE] During create_subvol(), afte
No detection rules found.
No public exploits indexed.
https://git.kernel.org/stable/c/3f5d47eb163bceb1b9e613c9003bae5fefc0046fhttps://git.kernel.org/stable/c/5a172344bfdabb46458e03708735d7b1a918c468https://git.kernel.org/stable/c/66b317a2fc45b2ef66527ee3f8fa08fb5beab88dhttps://git.kernel.org/stable/c/833775656d447c545133a744a0ed1e189ce61430https://git.kernel.org/stable/c/e03ee2fe873eb68c1f9ba5112fee70303ebf9dfbhttps://git.kernel.org/stable/c/e31546b0f34af21738c4ceac47d662c00ee6382fhttps://git.kernel.org/stable/c/3f5d47eb163bceb1b9e613c9003bae5fefc0046fhttps://git.kernel.org/stable/c/5a172344bfdabb46458e03708735d7b1a918c468https://git.kernel.org/stable/c/66b317a2fc45b2ef66527ee3f8fa08fb5beab88dhttps://git.kernel.org/stable/c/833775656d447c545133a744a0ed1e189ce61430https://git.kernel.org/stable/c/e03ee2fe873eb68c1f9ba5112fee70303ebf9dfbhttps://git.kernel.org/stable/c/e31546b0f34af21738c4ceac47d662c00ee6382fhttps://lists.debian.org/debian-lts-announce/2024/06/msg00017.html
2024-04-03
Published