Skip to content
Fencer Intel
no cvss —

RUSTSEC-2023-0020 json

const-cstr is Unmaintained

published 3y ago modified 3y ago

cvss
—
not scored
cisa kev
Not listed
not in CISA's catalog
epss
—
no score, EPSS covers CVEs only
public exploits
0
none known

Summary

Last release was about five years ago.

The maintainer(s) have been unreachable to respond to any issues that may or may not include security issues.

The repository is now archived and there is no security policy in place to contact the maintainer(s) otherwise.

No direct fork exist.

# const-cstr is Unsound

The crate violates the safety contract of [ffi::CStr::from_bytes_with_nul_unchecked](https://doc.rust-lang.org/std/ffi/struct.CStr.html#method.from_bytes_with_nul_unchecked) used in `ConstCStr::as_cstr`

No interior nul bytes checking is done either by the constructor or the canonical macro to create the `ConstCStr`

# const-cstr Panic

Additionally the crate may cause runtime panics if statically compiled and ran with any untrusted data that is not nul-terminated.

This is however unlikely but the the crate should not be used for untrusted data in context where panic may create a DoS vector.

## Possible Alternatives

The below may or may not provide alternative(s)

- [const_str::cstr!](https://docs.rs/const-str/latest/const_str/macro.cstr.html) - [cstr::cstr!](https://crates.io/crates/cstr)

Is RUSTSEC-2023-0020 in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.

Check with Fencer

Affected packages

ecosystem package affected fixed in
crates.io const-cstr
>=0.0.0-0
no fix listed

References

Sources

Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.