Miggo Logo

CVE-2020-36445: Data races in convec

8.1

CVSS Score
3.1

Basic Information

EPSS Score
0.55836%
Published
8/25/2021
Updated
1/27/2023
KEV Status
No
Technology
TechnologyRust

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
Package NameEcosystemVulnerable VersionsFirst Patched Version
convecrust<= 2.0.1

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability stems from improper trait implementations rather than specific functions. The ConVec<T> type unconditionally implements Send and Sync traits without enforcing that T: Send or T: Sync. This allows non-thread-safe types (e.g., Rc<T>, Cell<T>) to be used in concurrent contexts, leading to data races. The root cause is the unsafe unsafe impl<T> Send for ConVec<T> {} and unsafe impl<T> Sync for ConVec<T> {} blocks in the crate's implementation. These trait implementations violate Rust's safety guarantees by enabling cross-thread sharing of non-Send/Sync types. No specific functions are directly implicated; the flaw lies in the type's trait bounds.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

*****t** v*rsions o* t*is *r*t* un*on*ition*lly impl*m*nt S*n*/Syn* *or `*onV**<T>`. T*is *llows us*rs to ins*rt `T` t**t is not S*n* or not Syn*. T*is *llows us*rs to *r**t* **t* r***s *y usin* non-S*n* typ*s lik* `*r*<**ll<_>>` or `R*<_>` *s `T` i

Reasoning

T** vuln*r**ility st*ms *rom improp*r tr*it impl*m*nt*tions r*t**r t**n sp**i*i* *un*tions. T** `*onV**<T>` typ* un*on*ition*lly impl*m*nts `S*n*` *n* `Syn*` tr*its wit*out *n*or*in* t**t `T: S*n*` or `T: Syn*`. T*is *llows non-t*r***-s*** typ*s (*.*