CVE-2021-47066: Vulnerability in Linux Linux
In the Linux kernel, the following vulnerability has been resolved: async_xor: increase src_offs when dropping destination page Now we support sharing one page if PAGE_SIZE is not equal stripe size. To support this, it needs to support calculating xor value with different offsets for each r5dev. One offset array is used to record those offsets. In RMW mode, parity page is used as a source page. It sets ASYNC_TX_XOR_DROP_DST before calculating xor value in ops_run_prexor5. So it needs to add src_list and src_offs at the same time. Now it only needs src_list. So the xor value which is calculated is wrong. It can cause data corruption problem. I can reproduce this problem 100% on a POWER8 machine. The steps are: mdadm -CR /dev/md0 -l5 -n3 /dev/sdb1 /dev/sdc1 /dev/sdd1 --size=3G mkfs.xfs /dev/md0 mount /dev/md0 /mnt/test mount: /mnt/test: mount(2) system call failed: Structure needs cleaning.
AI Analysis
Technical Summary
CVE-2021-47066 is a vulnerability found in the Linux kernel's implementation of the async_xor function, which is part of the RAID 5/6 parity calculation mechanism. Specifically, the flaw arises when the PAGE_SIZE is not equal to the stripe size used in RAID 5 configurations. The vulnerability is due to incorrect handling of source offsets during XOR calculations in the Read-Modify-Write (RMW) mode. In this mode, the parity page is used as a source page, and the kernel sets the ASYNC_TX_XOR_DROP_DST flag before computing the XOR value. However, the implementation only adds the source list without correctly adding the source offsets simultaneously, leading to incorrect XOR calculations. This results in data corruption during RAID 5 operations. The issue has been reproducibly demonstrated on POWER8 architecture machines by creating a RAID 5 array with mdadm, formatting it with XFS, and attempting to mount it, which fails with a 'Structure needs cleaning' error, indicating filesystem corruption. This vulnerability affects Linux kernel versions identified by the commit hash 29bcff787a2593b2126cfaff612c0b4e560022e9 and likely other versions containing the same flawed code. Although no known exploits are currently reported in the wild, the vulnerability can cause silent data corruption, which is particularly dangerous as it may go unnoticed until data loss or system instability occurs. The root cause is a logic error in the parity calculation algorithm for RAID 5 arrays, which can compromise data integrity on affected systems.
Potential Impact
For European organizations relying on Linux-based systems with software RAID 5 configurations, this vulnerability poses a significant risk to data integrity and availability. Data corruption in RAID 5 arrays can lead to loss of critical business data, disruption of services, and potential downtime while recovering or rebuilding affected storage arrays. Industries such as finance, healthcare, telecommunications, and government sectors in Europe that depend on reliable storage systems could face operational impacts and compliance issues related to data integrity. Since the vulnerability can cause filesystem corruption, it may also trigger cascading failures in applications relying on the affected storage volumes. The fact that exploitation does not require user interaction or authentication increases the risk, especially in environments where RAID 5 is used without additional safeguards. Although no active exploits are reported, the potential for silent data corruption makes this vulnerability a serious concern for data centers and enterprises using Linux RAID 5 configurations.
Mitigation Recommendations
European organizations should prioritize updating their Linux kernels to versions where this vulnerability is patched. Since the vulnerability is related to the async_xor function in the RAID 5 implementation, applying the latest stable kernel updates from trusted Linux distributions is critical. Organizations should audit their systems to identify any use of software RAID 5 arrays, especially those using PAGE_SIZE values differing from stripe sizes. Until patches are applied, consider migrating critical data from RAID 5 arrays to more resilient RAID levels such as RAID 6 or RAID 10, which are less susceptible to parity calculation errors. Implement rigorous data integrity checks and monitoring on RAID arrays to detect early signs of corruption. Regular backups and verification of backup integrity are essential to recover from potential data loss. Additionally, testing RAID configurations on non-production systems after kernel updates can help ensure stability before deployment. For environments using POWER8 or similar architectures, extra caution is advised given the reproducible nature of the issue on such hardware.
Affected Countries
Germany, France, United Kingdom, Netherlands, Italy, Spain, Sweden, Poland, Belgium, Finland
CVE-2021-47066: Vulnerability in Linux Linux
Description
In the Linux kernel, the following vulnerability has been resolved: async_xor: increase src_offs when dropping destination page Now we support sharing one page if PAGE_SIZE is not equal stripe size. To support this, it needs to support calculating xor value with different offsets for each r5dev. One offset array is used to record those offsets. In RMW mode, parity page is used as a source page. It sets ASYNC_TX_XOR_DROP_DST before calculating xor value in ops_run_prexor5. So it needs to add src_list and src_offs at the same time. Now it only needs src_list. So the xor value which is calculated is wrong. It can cause data corruption problem. I can reproduce this problem 100% on a POWER8 machine. The steps are: mdadm -CR /dev/md0 -l5 -n3 /dev/sdb1 /dev/sdc1 /dev/sdd1 --size=3G mkfs.xfs /dev/md0 mount /dev/md0 /mnt/test mount: /mnt/test: mount(2) system call failed: Structure needs cleaning.
AI-Powered Analysis
Technical Analysis
CVE-2021-47066 is a vulnerability found in the Linux kernel's implementation of the async_xor function, which is part of the RAID 5/6 parity calculation mechanism. Specifically, the flaw arises when the PAGE_SIZE is not equal to the stripe size used in RAID 5 configurations. The vulnerability is due to incorrect handling of source offsets during XOR calculations in the Read-Modify-Write (RMW) mode. In this mode, the parity page is used as a source page, and the kernel sets the ASYNC_TX_XOR_DROP_DST flag before computing the XOR value. However, the implementation only adds the source list without correctly adding the source offsets simultaneously, leading to incorrect XOR calculations. This results in data corruption during RAID 5 operations. The issue has been reproducibly demonstrated on POWER8 architecture machines by creating a RAID 5 array with mdadm, formatting it with XFS, and attempting to mount it, which fails with a 'Structure needs cleaning' error, indicating filesystem corruption. This vulnerability affects Linux kernel versions identified by the commit hash 29bcff787a2593b2126cfaff612c0b4e560022e9 and likely other versions containing the same flawed code. Although no known exploits are currently reported in the wild, the vulnerability can cause silent data corruption, which is particularly dangerous as it may go unnoticed until data loss or system instability occurs. The root cause is a logic error in the parity calculation algorithm for RAID 5 arrays, which can compromise data integrity on affected systems.
Potential Impact
For European organizations relying on Linux-based systems with software RAID 5 configurations, this vulnerability poses a significant risk to data integrity and availability. Data corruption in RAID 5 arrays can lead to loss of critical business data, disruption of services, and potential downtime while recovering or rebuilding affected storage arrays. Industries such as finance, healthcare, telecommunications, and government sectors in Europe that depend on reliable storage systems could face operational impacts and compliance issues related to data integrity. Since the vulnerability can cause filesystem corruption, it may also trigger cascading failures in applications relying on the affected storage volumes. The fact that exploitation does not require user interaction or authentication increases the risk, especially in environments where RAID 5 is used without additional safeguards. Although no active exploits are reported, the potential for silent data corruption makes this vulnerability a serious concern for data centers and enterprises using Linux RAID 5 configurations.
Mitigation Recommendations
European organizations should prioritize updating their Linux kernels to versions where this vulnerability is patched. Since the vulnerability is related to the async_xor function in the RAID 5 implementation, applying the latest stable kernel updates from trusted Linux distributions is critical. Organizations should audit their systems to identify any use of software RAID 5 arrays, especially those using PAGE_SIZE values differing from stripe sizes. Until patches are applied, consider migrating critical data from RAID 5 arrays to more resilient RAID levels such as RAID 6 or RAID 10, which are less susceptible to parity calculation errors. Implement rigorous data integrity checks and monitoring on RAID arrays to detect early signs of corruption. Regular backups and verification of backup integrity are essential to recover from potential data loss. Additionally, testing RAID configurations on non-production systems after kernel updates can help ensure stability before deployment. For environments using POWER8 or similar architectures, extra caution is advised given the reproducible nature of the issue on such hardware.
For access to advanced analysis and higher rate limits, contact root@offseq.com
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- Linux
- Date Reserved
- 2024-02-29T22:33:44.296Z
- Cisa Enriched
- true
- Cvss Version
- null
- State
- PUBLISHED
Threat ID: 682d9834c4522896dcbe9c06
Added to database: 5/21/2025, 9:09:08 AM
Last enriched: 6/30/2025, 8:42:11 PM
Last updated: 8/8/2025, 7:02:50 PM
Views: 15
Related Threats
CVE-2025-9096: Cross Site Scripting in ExpressGateway express-gateway
MediumCVE-2025-9095: Cross Site Scripting in ExpressGateway express-gateway
MediumCVE-2025-7342: CWE-798 Use of Hard-coded Credentials in Kubernetes Image Builder
HighCVE-2025-9094: Improper Neutralization of Special Elements Used in a Template Engine in ThingsBoard
MediumCVE-2025-9093: Improper Export of Android Application Components in BuzzFeed App
MediumActions
Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.
External Links
Need enhanced features?
Contact root@offseq.com for Pro access with improved analysis and higher rate limits.