From 85b183d9f171ff7135cfe757a04bff598705884d Mon Sep 17 00:00:00 2001 From: Ammar Askar Date: Mon, 18 Jan 2021 21:41:55 -0800 Subject: [PATCH] Add advisory for data race in toolshed --- crates/toolshed/RUSTSEC-0000-0000.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 crates/toolshed/RUSTSEC-0000-0000.md diff --git a/crates/toolshed/RUSTSEC-0000-0000.md b/crates/toolshed/RUSTSEC-0000-0000.md new file mode 100644 index 000000000..04d1d6c5c --- /dev/null +++ b/crates/toolshed/RUSTSEC-0000-0000.md @@ -0,0 +1,21 @@ +```toml +[advisory] +id = "RUSTSEC-0000-0000" +package = "toolshed" +date = "2020-11-15" +url = "https://github.com/ratel-rust/toolshed/issues/12" +categories = ["memory-corruption"] +keywords = ["concurrency"] + +[versions] +patched = [] +``` + +# CopyCell lacks bounds on its Send trait allowing for data races + +`CopyCell` is a `Cell`-like type that is implemented for any type `T` that +is `Copy`able. It's `Send` trait has no bounds on the contained type. + +As not all `Copy`able types are thread safe, for example non-mutable references +implement the `Copy` trait, it is possible to send references to types with +interior mutability such as `Cell` across threads and cause data races.