Undefined Behavior in bounded Crossbeam channel
Description
Crossbeam is a set of tools for concurrent programming. In crossbeam-channel before version 0.4.4, the bounded channel incorrectly assumes that Vec::from_iter has allocated capacity that same as the number of iterator elements. Vec::from_iter does not actually guarantee that and may allocate extra memory. The destructor of the bounded channel reconstructs Vec from the raw pointer based on the incorrect assumes described above. This is unsound and causing deallocation with the incorrect capacity when Vec::from_iter has allocated different sizes with the number of iterator elements. This has been fixed in crossbeam-channel 0.4.4.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
crossbeam-channelcrates.io | >= 0.4.3, < 0.4.4 | 0.4.4 |
Affected products
4- ghsa-coords3 versionspkg:cargo/crossbeam-channelpkg:rpm/opensuse/firefox-esr&distro=openSUSE%20Tumbleweedpkg:rpm/opensuse/MozillaFirefox&distro=openSUSE%20Tumbleweed
>= 0.4.3, < 0.4.4+ 2 more
- (no CPE)range: >= 0.4.3, < 0.4.4
- (no CPE)range: < 128.5.1-1.1
- (no CPE)range: < 92.0-1.2
- Range: < 0.4.4
Patches
Vulnerability mechanics
References
7- github.com/advisories/GHSA-v5m7-53cv-f3hxghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2020-15254ghsaADVISORY
- github.com/RustSec/advisory-db/pull/425ghsax_refsource_MISCWEB
- github.com/crossbeam-rs/crossbeam/issues/539ghsax_refsource_MISCWEB
- github.com/crossbeam-rs/crossbeam/pull/533ghsax_refsource_MISCWEB
- github.com/crossbeam-rs/crossbeam/security/advisories/GHSA-v5m7-53cv-f3hxghsax_refsource_CONFIRMWEB
- rustsec.org/advisories/RUSTSEC-2020-0052.htmlghsaWEB
News mentions
0No linked articles in our index yet.