CVE-2023-54180
Kernel BUG Trigger in Btrfs Dev-Replace Repair Causes System Crash
Publication date: 2025-12-30
Last updated on: 2025-12-30
Assigner: kernel.org
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| linux | linux_kernel | 6.0 |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-UNKNOWN |
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?
This vulnerability is a bug in the Linux kernel's btrfs filesystem related to handling disk replacement (dev-replace). When replacing an unreliable disk, a BUG_ON() check in the btrfs_repair_io_failure() function could be triggered incorrectly. This happens because the code tries to repair read errors from the replace target device, but due to how the replacement process works, some read failures are expected and should be handled by the replace routine instead of triggering a bug. The fix was to skip the repair step when dealing with the replace target device instead of causing a kernel bug.
How can this vulnerability impact me? :
This vulnerability can cause the Linux kernel to crash (kernel BUG) during disk replacement operations in btrfs, leading to system instability or downtime. It may interrupt the disk replacement process and potentially cause data access issues while the bug is triggered.
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability can be detected by monitoring kernel logs for specific BTRFS warnings and kernel BUG messages related to btrfs_repair_io_failure(). You should look for log entries similar to: 'BTRFS warning (device sda1): csum failed ...' and 'kernel BUG at fs/btrfs/extent_io.c:2380!'. Commands to check these logs include: 'dmesg | grep -i btrfs', 'journalctl -k | grep btrfs', or 'grep btrfs /var/log/kern.log'. These commands help identify if the BUG_ON() in btrfs_repair_io_failure() has been triggered due to disk replace operations.
What immediate steps should I take to mitigate this vulnerability?
Immediate mitigation involves updating the Linux kernel to a version where this bug is fixed, which replaces the BUG_ON() with logic to skip repair when the device replace target is being repaired. Until then, monitor for the described kernel warnings and avoid interrupting ongoing device replace operations on BTRFS filesystems to prevent triggering the BUG_ON().