CVE-2023-53339
btrfs: fix BUG_ON condition in btrfs_cancel_balance
Mitigation
- Upgrade Linux to 29eefa6d0d07e185f7bfe9576f91e6dba98189c2 or later.
- Upgrade Linux to 6.4.12 or later.
Who should check
- Anyone running Linux >= ddf7e8984c83aee9122552529f4e77291903f8d9, < ceb9ba8e30833a4823e2dc73f80ebcdf2498d01a; >= 72efe5d44821e38540888a5fe3ff3d0faab6acad, < ae81329f7de3aa6f34ecdfa5412e72161a30e9ce; >= b19c98f237cd76981aaded52c258ce93f7daa8cb, < 29eefa6d0d07e185f7bfe9576f91e6dba98189c2
- Anyone running Linux >= 6.1.42, < 6.1.47; >= 6.4.7, < 6.4.12
Vulnerability facts
- Affected
- Linux >= ddf7e8984c83aee9122552529f4e77291903f8d9, < ceb9ba8e30833a4823e2dc73f80ebcdf2498d01a; >= 72efe5d44821e38540888a5fe3ff3d0faab6acad, < ae81329f7de3aa6f34ecdfa5412e72161a30e9ce; >= b19c98f237cd76981aaded52c258ce93f7daa8cb, < 29eefa6d0d07e185f7bfe9576f91e6dba98189c2; Linux >= 6.1.42, < 6.1.47; >= 6.4.7, < 6.4.12
- Fixed in
- Linux 29eefa6d0d07e185f7bfe9576f91e6dba98189c2, Linux 6.1.47, Linux 6.4.12
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 5.5 (v3.1, NVD)CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:HOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Local
- Attack complexity: Low
- Privileges required: Low
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: None
- Integrity impact: None
- Availability impact: High
- EPSS
- 0.23% chance of exploitation in 30 days (percentile 8, 2026-11-26)
- CWE
- CWE-617
- Modified
Description
In the Linux kernel, the following vulnerability has been resolved: btrfs: fix BUG_ON condition in btrfs_cancel_balance Pausing and canceling balance can race to interrupt balance lead to BUG_ON panic in btrfs_cancel_balance. The BUG_ON condition in btrfs_cancel_balance does not take this race scenario into account. However, the race condition has no other side effects. We can fix that. Reproducing it with panic trace like this: kernel BUG at fs/btrfs/volumes.c:4618! RIP: 0010:btrfs_cancel_balance+0x5cf/0x6a0 Call Trace: <TASK> ? do_nanosleep+0x60/0x120 ? hrtimer_nanosleep+0xb7/0x1a0 ? sched_core_clone_cookie+0x70/0x70 btrfs_ioctl_balance_ctl+0x55/0x70 btrfs_ioctl+0xa46/0xd20 __x64_sys_ioctl+0x7d/0xa0 do_syscall_64+0x38/0x80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Race scenario as follows: > mutex_unlock(&fs_info->balance_mutex); > -------------------- > .......issue pause and cancel req in another thread > -------------------- > ret = __btrfs_balance(fs_info); > > mutex_lock(&fs_info->balance_mutex); > if (ret == -ECANCELED && atomic_read(&fs_info->balance_pause_req)) { > btrfs_info(fs_info, "balance: paused"); > btrfs_exclop_balance(fs_info, BTRFS_EXCLOP_BALANCE_PAUSED); > }
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Linux | >= ddf7e8984c83aee9122552529f4e77291903f8d9, < ceb9ba8e30833a4823e2dc73f80ebcdf2498d01a; >= 72efe5d44821e38540888a5fe3ff3d0faab6acad, < ae81329f7de3aa6f34ecdfa5412e72161a30e9ce; >= b19c98f237cd76981aaded52c258ce93f7daa8cb, < 29eefa6d0d07e185f7bfe9576f91e6dba98189c2 | — | cvelist |
| Linux | >= 6.1.42, < 6.1.47; >= 6.4.7, < 6.4.12 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2023-53339. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2023-53339.md Affected: Linux >= ddf7e8984c83aee9122552529f4e77291903f8d9, < ceb9ba8e30833a4823e2dc73f80ebcdf2498d01a; >= 72efe5d44821e38540888a5fe3ff3d0faab6acad, < ae81329f7de3aa6f34ecdfa5412e72161a30e9ce; >= b19c98f237cd76981aaded52c258ce93f7daa8cb, < 29eefa6d0d07e185f7bfe9576f91e6dba98189c2; Linux >= 6.1.42, < 6.1.47;… Fixed in: Linux 29eefa6d0d07e185f7bfe9576f91e6dba98189c2, Linux 6.1.47, Linux 6.4.12 Steps: 1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
FAQ
Is CVE-2023-53339 being exploited?
There is no confirmed exploitation: CVE-2023-53339 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.23% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2023-53339?
Medium: CVSS 5.5 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).
Which versions are affected by CVE-2023-53339?
Linux >= ddf7e8984c83aee9122552529f4e77291903f8d9, < ceb9ba8e30833a4823e2dc73f80ebcdf2498d01a; >= 72efe5d44821e38540888a5fe3ff3d0faab6acad, < ae81329f7de3aa6f34ecdfa5412e72161a30e9ce; >= b19c98f237cd76981aaded52c258ce93f7daa8cb, < 29eefa6d0d07e185f7bfe9576f91e6dba98189c2; Linux >= 6.1.42, < 6.1.47; >= 6.4.7, < 6.4.12.
Is there a fix for CVE-2023-53339?
Yes. Fixed in Linux 29eefa6d0d07e185f7bfe9576f91e6dba98189c2, Linux 6.1.47, Linux 6.4.12. Upgrade Linux to 29eefa6d0d07e185f7bfe9576f91e6dba98189c2 or later. Upgrade Linux to 6.4.12 or later.
How do I check if I'm affected by CVE-2023-53339?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.