Vulnerability CriticalRUSTSEC-2022-0051 · lz4-sys
RUSTSEC-2022-0051: Memory corruption in liblz4
Short answerA security vulnerability in the lz4-sys crate: Memory corruption in liblz4. Critical severity (CVSS 9.8). Fixed in 1.9.4: update to a fixed version.
| Crate | lz4-sys |
|---|---|
| Type | Vulnerability (memory-corruption) |
| Affected versions | Before 1.9.4. |
| Fixed in | 1.9.4 |
| Severity | Critical, CVSS 9.8 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| Published | 2022-08-25 |
| Last changed | 2026-02-04 |
| Also known as | GHSA-9q5j-jm53-v7vr |
What to do
- See which version you have:
cargo tree -i lz4-sys(it also shows which of your dependencies pulls it in). - Update within your version requirement:
cargo update -p lz4-sys. If the fix is a newer major or minor than your requirement allows, raise it in Cargo.toml (for examplelz4-sys = "1.9.4") or update the dependency that pulls it in. - Check again with
cargo audit, or paste your Cargo.lock into our Cargo.toml checker.
Details from the advisory
lz4-sys up to v1.9.3 bundles a version of liblz4 that is vulnerable to CVE-2021-3520.
Attackers could craft a payload that triggers an integer overflow upon decompression, causing an out-of-bounds write.
The flaw has been corrected in version v1.9.4 of liblz4, which is included in lz4-sys 1.9.4.
References
- Package: crates.io/crates/lz4-sys
- Advisory: rustsec.org/advisories/RUSTSEC-2022-0051.html
- Web: github.com/lz4/lz4/pull/972
From the RustSec Advisory Database (CC0-1.0) via the OSV export, downloaded Oct 24, 2026. Severity score computed from the published CVSS vector.
Up next
Same cratelz4-sys: security historyEvery advisory for this crate, and whether it is safe to use today.Read it next →Did this answer your question?