Out-of-bounds Write Affecting lz4-sys package, versions <1.9.4


Severity

Recommended
0.0
critical
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.3% (69th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-RUST-LZ4SYS-3014215
  • published14 Dec 2021
  • disclosed2 Jun 2021
  • creditUnknown

Introduced: 2 Jun 2021

CVE-2021-3520  (opens in a new tab)
CWE-190  (opens in a new tab)
CWE-787  (opens in a new tab)

How to fix?

Upgrade lz4-sys to version 1.9.4 or higher.

Overview

Affected versions of this package are vulnerable to Out-of-bounds Write. There's a flaw in lz4. An attacker who submits a crafted file to an application linked with lz4 may be able to trigger an integer overflow, leading to calling of memmove() on a negative size argument, causing an out-of-bounds write and/or a crash. The greatest impact of this flaw is to availability, with some potential impact to confidentiality and integrity as well.

Note: lz4-sys versions up to v1.9.3 bundles a vulnerable version of liblz4, therefore those versions are impacted too.

CVSS Scores

version 3.1