Skip to main content

CVE-2021-47577: Vulnerability in Linux Linux

High
VulnerabilityCVE-2021-47577cvecve-2021-47577
Published: Wed Jun 19 2024 (06/19/2024, 14:53:45 UTC)
Source: CVE
Vendor/Project: Linux
Product: Linux

Description

In the Linux kernel, the following vulnerability has been resolved: io-wq: check for wq exit after adding new worker task_work We check IO_WQ_BIT_EXIT before attempting to create a new worker, and wq exit cancels pending work if we have any. But it's possible to have a race between the two, where creation checks exit finding it not set, but we're in the process of exiting. The exit side will cancel pending creation task_work, but there's a gap where we add task_work after we've canceled existing creations at exit time. Fix this by checking the EXIT bit post adding the creation task_work. If it's set, run the same cancelation that exit does.

AI-Powered Analysis

AILast updated: 06/30/2025, 14:55:09 UTC

Technical Analysis

CVE-2021-47577 is a vulnerability identified in the Linux kernel's IO workqueue (io-wq) subsystem. The issue arises from a race condition during the creation and cancellation of worker tasks when the workqueue is in the process of exiting. Specifically, the kernel checks the IO_WQ_BIT_EXIT flag before creating a new worker task_work to ensure the workqueue is not exiting. However, due to a timing gap, it is possible that the exit process cancels pending work after the check but before the new task_work is fully added, leading to a scenario where task_work is added after cancellation has begun. This race condition can cause inconsistencies in task management, potentially leading to use-after-free conditions or other memory corruption issues. The fix involves an additional check of the EXIT bit immediately after adding the creation task_work; if the EXIT bit is set, the same cancellation routine is executed to prevent the race condition. This vulnerability affects specific Linux kernel versions identified by commit hashes, indicating it is present in certain recent kernel builds prior to the patch. No known exploits are currently reported in the wild, and no CVSS score has been assigned yet.

Potential Impact

For European organizations, the impact of CVE-2021-47577 depends on their reliance on vulnerable Linux kernel versions, particularly in environments where IO workqueues are heavily utilized, such as high-performance computing, servers, and embedded systems. Exploitation of this race condition could lead to kernel memory corruption, potentially allowing local attackers to escalate privileges or cause denial of service by crashing the kernel. This can compromise system integrity and availability, critical for sectors like finance, healthcare, and critical infrastructure. Although remote exploitation is unlikely without local access, the widespread use of Linux in European data centers, cloud providers, and enterprise environments means that vulnerable systems could be targeted by insiders or malware that gains initial foothold. The absence of known exploits reduces immediate risk, but the vulnerability's nature warrants prompt attention to prevent future exploitation attempts.

Mitigation Recommendations

European organizations should prioritize updating Linux kernels to versions that include the patch for CVE-2021-47577. Specifically, kernel maintainers and system administrators must apply the fix that adds the post-addition EXIT bit check and cancellation logic. For environments where immediate patching is not feasible, mitigating risk involves restricting local access to trusted users only, employing strict privilege separation, and monitoring for unusual kernel crashes or system instability indicative of exploitation attempts. Additionally, organizations should audit their Linux kernel versions across all systems, including embedded devices and containers, to identify vulnerable instances. Implementing kernel live patching solutions where available can reduce downtime during remediation. Finally, maintaining robust endpoint detection and response (EDR) capabilities can help detect exploitation attempts targeting kernel vulnerabilities.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
Linux
Date Reserved
2024-05-24T15:11:00.730Z
Cisa Enriched
true
Cvss Version
null
State
PUBLISHED

Threat ID: 682d9833c4522896dcbe94eb

Added to database: 5/21/2025, 9:09:07 AM

Last enriched: 6/30/2025, 2:55:09 PM

Last updated: 8/12/2025, 1:31:56 PM

Views: 12

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats