btrfs: fix abort logic in btrfs_replace_file_extents
Published May 22, 2024
8.1
HIGHCVSS 3.1
EPSS 0.58%
Description
Error injection testing uncovered a case where we'd end up with a corrupt file system with a missing extent in the middle of a file. This occurs because the if statement to decide if we should abort is wrong.
The only way we would abort in this case is if we got a ret != -EOPNOTSUPP and we called from the file clone code. However the prealloc code uses this path too. Instead we need to abort if there is an error, and the only error we _don't_ abort on is -EOPNOTSUPP and only if we came from the clone file code.
Affected products
-
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version
-
- Version 5.10StatusaffectedConstraints-
- Version 0StatusunaffectedConstraints<5.10
- Version 5.10.75StatusunaffectedConstraints<=5.10.*
- Version 5.14.14StatusunaffectedConstraints<=5.14.*
- Version 5.15StatusunaffectedConstraints<=*
- Version
Default status is the baseline for the product, each version can override it (e.g. patched versions marked unaffected).
- < 5.10.75
- ≥ 5.11 · < 5.14.14
- 5.15
- 5.15
- 5.15
- 5.15
- 5.15
No data.
Red Hat Enterprise Linux 6
kernel
Out of support scope
Red Hat Enterprise Linux 7
kernel
Out of support scope
Red Hat Enterprise Linux 7
kernel-rt
Out of support scope
Red Hat Enterprise Linux 8
kernel
Not affected
Red Hat Enterprise Linux 8
kernel-rt
Not affected
Red Hat Enterprise Linux 9
kernel
Not affected
Red Hat Enterprise Linux 9
kernel-rt
Not affected
| Product | Package | State | Advisory |
|---|---|---|---|
| Red Hat Enterprise Linux 6 | kernel | Out of support scope | n/a |
| Red Hat Enterprise Linux 7 | kernel | Out of support scope | n/a |
| Red Hat Enterprise Linux 7 | kernel-rt | Out of support scope | n/a |
| Red Hat Enterprise Linux 8 | kernel | Not affected | n/a |
| Red Hat Enterprise Linux 8 | kernel-rt | Not affected | n/a |
| Red Hat Enterprise Linux 9 | kernel | Not affected | n/a |
| Red Hat Enterprise Linux 9 | kernel-rt | Not affected | n/a |
No package ranges for this CVE.
Remediation
No remediation recorded yet.
References (8)
- https://access.redhat.com/security/cve/CVE-2021-47433 Vendor Advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=2282881 Issue Tracking
- https://euvd.enisa.europa.eu/vulnerability/EUVD-2021-34438 Advisory
- https://git.kernel.org/stable/c/0e309e1152fc34ef75991d9d69b165dbf75bf26c Patch
- https://git.kernel.org/stable/c/0e32a2b85c7d92ece86c17dfef390c5ed79c6378 Patch
- https://git.kernel.org/stable/c/4afb912f439c4bc4e6a4f3e7547f2e69e354108f Patch
- https://nvd.nist.gov/vuln/detail/CVE-2021-47433
- https://www.cve.org/CVERecord?id=CVE-2021-47433
Change history (0)
No recorded changes yet.