Integer Overflow or Wraparound Affecting cpio package, versions [,2.14)


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
4.17% (91st 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 Learn

Learn about Integer Overflow or Wraparound vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-UNMANAGED-CPIO-2319544
  • published14 Dec 2021
  • disclosed8 Aug 2021
  • creditUnknown

Introduced: 8 Aug 2021

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

How to fix?

Upgrade cpio to version 2.14 or higher.

Overview

Affected versions of this package are vulnerable to Integer Overflow or Wraparound. GNU cpio through 2.13 allows attackers to execute arbitrary code via a crafted pattern file, because of a dstring.c ds_fgetstr integer overflow that triggers an out-of-bounds heap write. NOTE: it is unclear whether there are common cases where the pattern file, associated with the -E option, is untrusted data.

CVSS Base Scores

version 3.1