Undefined Behavior in bounded Crossbeam channel
cve-program · CVE-2020-15254
PublishedCrossbeam 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.
Read the publisher's advisorycve-program · CVE-2020-35904
PublishedAn issue was discovered in the crossbeam-channel crate before 0.4.4 for Rust. It has incorrect expectations about the relationship between the memory allocation and how many iterator elements there are.
Read the publisher's advisoryeuvd · EUVD-2021-1794
PublishedAn issue was discovered in the crossbeam-channel crate before 0.4.4 for Rust. It has incorrect expectations about the relationship between the memory allocation and how many iterator elements there are.
Read the publisher's advisoryeuvd · EUVD-2021-1883
PublishedCrossbeam 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.
Read the publisher's advisorynvd · CVE-2020-15254
PublishedCrossbeam 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.
Read the publisher's advisorynvd · CVE-2020-35904
PublishedAn issue was discovered in the crossbeam-channel crate before 0.4.4 for Rust. It has incorrect expectations about the relationship between the memory allocation and how many iterator elements there are.
Read the publisher's advisoryosv · GHSA-m8h8-v6jh-c762
PublishedThe affected version of this crate's 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.
Read the publisher's advisoryosv · GHSA-v5m7-53cv-f3hx
Published### Impact The affected version of this crate's 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. ### Patches This has been fixed in crossbeam-channel 0.4.4. We recommend users to upgrade to 0.4.4. ### References See https://github.com/crossbeam-rs/crossbeam/pull/533, https://github.com/crossbeam-rs/crossbeam/issues/539, and https://github.com/RustSec/advisory-db/pull/425 for more details. ### License This advisory is in the public domain.
Read the publisher's advisoryosv · RUSTSEC-2020-0052
PublishedThe affected version of this crate's 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.
Read the publisher's advisoryAffected versions, risk and source history
Related advisories and sources
Publishers link these advisories through the identifiers shown below. A shared identifier or date alone does not tell you whether your software is affected or whether the advisories describe the same cause.
CVE-2020-15254 · CVE overview and exploitation status
CVE-2020-35904 · CVE overview and exploitation status
cve-program · CVE-2020-15254
- https://github.com/crossbeam-rs/crossbeam/security/advisories/GHSA-v5m7-53cv-f3hx
- https://github.com/crossbeam-rs/crossbeam/issues/539
- https://github.com/crossbeam-rs/crossbeam/pull/533
- https://github.com/RustSec/advisory-db/pull/425
cve-program · CVE-2020-35904
euvd · EUVD-2021-1794
euvd · EUVD-2021-1883
- https://github.com/crossbeam-rs/crossbeam/security/advisories/GHSA-v5m7-53cv-f3hx
- https://github.com/crossbeam-rs/crossbeam/issues/539
- https://github.com/crossbeam-rs/crossbeam/pull/533
- https://github.com/RustSec/advisory-db/pull/425
nvd · CVE-2020-15254
- https://github.com/RustSec/advisory-db/pull/425
- https://github.com/crossbeam-rs/crossbeam/issues/539
- https://github.com/crossbeam-rs/crossbeam/pull/533
- https://github.com/crossbeam-rs/crossbeam/security/advisories/GHSA-v5m7-53cv-f3hx
nvd · CVE-2020-35904
osv · GHSA-m8h8-v6jh-c762
- https://nvd.nist.gov/vuln/detail/CVE-2020-35904
- https://github.com/crossbeam-rs/crossbeam/pull/533
- https://github.com/crossbeam-rs/crossbeam
- https://rustsec.org/advisories/RUSTSEC-2020-0052.html
osv · GHSA-v5m7-53cv-f3hx
- https://github.com/crossbeam-rs/crossbeam/security/advisories/GHSA-v5m7-53cv-f3hx
- https://nvd.nist.gov/vuln/detail/CVE-2020-15254
- https://github.com/crossbeam-rs/crossbeam/issues/539
- https://github.com/RustSec/advisory-db/pull/425
- https://github.com/crossbeam-rs/crossbeam/pull/533
- https://github.com/crossbeam-rs/crossbeam
- https://rustsec.org/advisories/RUSTSEC-2020-0052.html
osv · RUSTSEC-2020-0052
Related changes
Linked by CVE identifierNo related changes are available here.