Race Condition Affecting rustc package, versions <1.59.0+dfsg1~ubuntu1~llvm-1~ubuntu1~20.04.2


Severity

Recommended
medium

Based on Ubuntu security rating.

Threat Intelligence

EPSS
1.23% (68th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-UBUNTU2004-RUSTC-2403933
  • published16 Feb 2022
  • disclosed15 Feb 2022

Introduced: 15 Feb 2022

CVE-2022-23639  (opens in a new tab)
CWE-362  (opens in a new tab)

How to fix?

Upgrade Ubuntu:20.04 rustc to version 1.59.0+dfsg1ubuntu1llvm-1ubuntu120.04.2 or higher.

NVD Description

Note: Versions mentioned in the description apply only to the upstream rustc package and not the rustc package as distributed by Ubuntu. See How to fix? for Ubuntu:20.04 relevant fixed versions and status.

crossbeam-utils provides atomics, synchronization primitives, scoped threads, and other utilities for concurrent programming in Rust. crossbeam-utils prior to version 0.8.7 incorrectly assumed that the alignment of {i,u}64 was always the same as Atomic{I,U}64. However, the alignment of {i,u}64 on a 32-bit target can be smaller than Atomic{I,U}64. This can cause unaligned memory accesses and data race. Crates using fetch_* methods with AtomicCell&lt;{i,u}64&gt; are affected by this issue. 32-bit targets without Atomic{I,U}64 and 64-bit targets are not affected by this issue. This has been fixed in crossbeam-utils 0.8.7. There are currently no known workarounds.

CVSS Base Scores

version 3.1