dcrypt-api
Affected
- introduced
0.0.0-0, fixed2.0.0(semver)
Fixed versions
2.0.0
Fix
- Fixed version
2.0.0cargo update -p dcrypt-api --precise 2.0.0
Advisory
Also known as: GHSA-7hc7-h3f2-r4j6
Safe ErrorRegistry APIs can cause undefined behavior
All published versions of dcrypt-api before 2.0.0 exposed safeErrorRegistry operations that could trigger undefined behavior when the
default std feature was enabled.
Stored Box<E> values were erased to raw pointers and later deallocated asBox<()>. The get_error<E> operation also performed an unchecked cast to a
caller-selected type. Finally, concurrent replacement or clearing could free a
value while another thread cloned it. Ordinary safe Rust could therefore cause
mismatched deallocation, type confusion, and use-after-free. Crates that
re-exported this API are affected transitively.
Version 2.0.0 replaces the raw pointers with owned Box<dyn Any + Send> values
behind a mutex, performs checked downcasts, and uses a mutation generation so
concurrent stores and clears win safely. There is no reliable workaround while
calling the affected registry API. Upgrade to 2.0.0 or later and avoid
process-global error state where possible.
Not rated by the source.
0.0.0-0, fixed 2.0.0 (semver)2.0.0
2.0.0cargo update -p dcrypt-api --precise 2.0.0Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: RustSec Advisory Database · CC0-1.0