CVE-2024-36027: btrfs: zoned: do not flag ZEROOUT on non-dirty extent buffer

Published May 30, 2024
·
Updated

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

btrfs: zoned: do not flag ZEROOUT on non-dirty extent buffer

Btrfs clears the content of an extent buffer marked as EXTENTBUFFERZONEDZEROOUT before the bio submission. This mechanism is introduced to prevent a write hole of an extent buffer, which is once allocated, marked dirty, but turns out unnecessary and cleaned up within one transaction operation.

Currently, btrfsclearbufferdirty() marks the extent buffer as EXTENTBUFFERZONEDZEROOUT, and skips the entry function. If this call happens while the buffer is under IO (with the WRITEBACK flag set, without the DIRTY flag), we can add the ZEROOUT flag and clear the buffer's content just before a bio submission. As a result:

1) it can lead to adding faulty delayed reference item which leads to a FS corrupted (EUCLEAN) error, and

2) it writes out cleared tree node on disk

The former issue is previously discussed in [1]. The corruption happens when it runs a delayed reference update. So, on-disk data is safe.

[1] https://lore.kernel.org/linux-btrfs/3f4f2a0ff1a6c818050434288925bdcf3cd719e5.1709124777.git.naohiro.aota@wdc.com/

The latter one can reach on-disk data. But, as that node is already processed by btrfsclearbufferdirty(), that will be invalidated in the next transaction commit anyway. So, the chance of hitting the corruption is relatively small.

Anyway, we should skip flagging ZEROOUT on a non-DIRTY extent buffer, to keep the content under IO intact.

Affected Software

6 affected componentsFixes available
debian/linux
5.10.223-15.10.234-16.1.129-16.1.135-16.12.25-16.12.27-1
Linux Linux kernel>=6.8<6.8.8
Linux Linux kernel=6.9-rc1
Linux Linux kernel=6.9-rc2
Linux Linux kernel=6.9-rc3
Linux Linux kernel=6.9-rc4

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 5.10.223-1Fixed in 5.10.234-1Fixed in 6.1.129-1Fixed in 6.1.135-1Fixed in 6.12.25-1Fixed in 6.12.27-1

Event History

May 30, 2024
CVE Published
via MITRE·03:10 PM
Data Sourced
via MITRE·03:10 PM
DescriptionSeverity
Data Sourced
via NVD·04:15 PM
Description
Data Sourced
via NVD·04:15 PM
RemedySeverityAffected Software
Jul 15, 2024
Data Sourced
via Launchpad·07:50 PM
Description
Dec 6, 2024
Data Sourced
via Ubuntu·08:21 PM
RemedyDescriptionSeverityAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2024-36027?

CVE-2024-36027 has been classified as a vulnerability in the Linux kernel affecting Btrfs that requires attention to prevent potential data integrity issues.

2

How do I fix CVE-2024-36027?

To fix CVE-2024-36027, upgrade your Linux kernel to versions 5.10.223-1, 5.10.226-1, 6.1.119-1, 6.1.123-1, 6.12.11-1, or 6.12.12-1.

3

What systems are affected by CVE-2024-36027?

CVE-2024-36027 affects various Debian Linux distributions utilizing specific kernel versions.

4

What is the impact of CVE-2024-36027?

The impact of CVE-2024-36027 may lead to improper handling of memory buffers, potentially causing data corruption.

5

Is CVE-2024-36027 publicly known?

Yes, CVE-2024-36027 has been publicly disclosed as part of the Linux kernel vulnerabilities.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203