From ac5a6f9239e8cb8568ba336bf004b126dc52df20 Mon Sep 17 00:00:00 2001 From: JOE1994 Date: Thu, 4 Mar 2021 10:07:34 -0500 Subject: [PATCH] Report 0162-internment to RustSec --- crates/internment/RUSTSEC-0000-0000.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 crates/internment/RUSTSEC-0000-0000.md diff --git a/crates/internment/RUSTSEC-0000-0000.md b/crates/internment/RUSTSEC-0000-0000.md new file mode 100644 index 0000000000..9a0ad66f7c --- /dev/null +++ b/crates/internment/RUSTSEC-0000-0000.md @@ -0,0 +1,19 @@ +```toml +[advisory] +id = "RUSTSEC-0000-0000" +package = "internment" +date = "2021-03-03" +url = "https://github.com/droundy/internment/issues/20" +categories = ["thread-safety"] + +[versions] +patched = [">= 0.4.2"] +``` + +# Intern: Data race allowed on T + +Affected versions of this crate unconditionally implements `Sync` for `Intern`. +This allows users to create data race on `T: !Sync`, which may lead to undefined behavior +(for example, memory corruption). + +The flaw was corrected in commit 2928a87 by adding the trait bound `T: Sync` in the `Sync` impl of `Intern`.