Skip to content

vec-const attempts to construct a Vec from a pointer to a const slice

Moderate severity GitHub Reviewed Published Jun 17, 2022 to the GitHub Advisory Database • Updated Jan 12, 2023

Package

cargo vec-const (Rust)

Affected versions

< 2.0.0

Patched versions

2.0.0

Description

Affected versions of this crate claimed to construct a const Vec with nonzero length and capacity, but that cannot be done because such a Vec requires a pointer from an allocator.

The implementation was later changed to just construct a std::borrow::Cow.

References

Published to the GitHub Advisory Database Jun 17, 2022
Reviewed Jun 17, 2022
Last updated Jan 12, 2023

Severity

Moderate

Weaknesses

No CWEs

CVE ID

No known CVE

GHSA ID

GHSA-jmwx-r3gq-qq3p

Source code

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.