CVE-2021-38191
Task dropped in wrong thread when aborting `LocalSet` task
5.9
MEDIUM
CVSS 3.1
EPSS 0.84%
Description
When aborting a task with `JoinHandle::abort`, the future is dropped in the thread calling abort if the task is not currently being executed. This is incorrect for tasks spawned on a `LocalSet`. This can easily result in race conditions as many projects use `Rc` or `RefCell` in their Tokio tasks for better performance. See [tokio#3929][issue] for more details. [issue]: https://github.com/tokio-rs/tokio/issues/3929
How to fix CVE-2021-38191
To remediate CVE-2021-38191, upgrade the affected package to a fixed version below.
- —upgrade to 1.8.1 or later
- —upgrade to 1.5.1 or later
Is CVE-2021-38191 being exploited?
Low — EPSS is 0.8%, meaning exploitation activity has not been observed at scale.
Affected packages (2)
- >= 1.8.0, < 1.8.1
- >= 0.3.0, < 1.5.1, >= 1.6.0, < 1.6.3, >= 1.7.0, < 1.7.2, >= 1.8.0, < 1.8.1
CVSS scores
| Source | Version | Severity | Vector |
|---|---|---|---|
| osv | CVSS 3.1 | MEDIUM5.9 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H |