RUSTSEC-2022-0067

Source
https://rustsec.org/advisories/RUSTSEC-2022-0067
Import Source
https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2022-0067.json
JSON Data
https://api.osv.dev/v1/vulns/RUSTSEC-2022-0067
Aliases
Published
2022-10-22T12:00:00Z
Modified
2023-11-08T04:15:48.003089Z
Summary
Invalid use of `mem::uninitialized` causes `use-of-uninitialized-value`
Details

The compression and decompression function used mem:uninitialized to create an array of uninitialized values, to later write values into it. This later leads to reads from uninitialized memory.

The flaw was corrected in commit b633bf265e41c60dfce3be7eac4e4dd5e18d06cf by using a heap-allocated Vec and removing out use of mem::uninitialized. The fix was released in v0.3.2 and v1.0.0

Subsequently the crate was deprecated and its use is discouraged.

Database specific
{
    "license": "CC0-1.0"
}
References

Affected packages

crates.io / lzf

Package

Affected ranges

Type
SEMVER
Events
Introduced
0.0.0-0
Fixed
0.3.2

Ecosystem specific

{
    "affected_functions": null,
    "affects": {
        "os": [],
        "functions": [
            "lzf::compress",
            "lzf::decompress"
        ],
        "arch": []
    }
}

Database specific

{
    "cvss": null,
    "informational": "unsound",
    "categories": []
}