Read the docs
TI-2021-15862 Aliases CVE-2021-38185GHSA-pp74-ghrg-jwfh

GNU cpio through 2.13 allows attackers to execute arbitrary code via a crafted pattern…

Priority MEDIUM 43CWE-190Published · Updated

Key facts

Attack vector
Local
Privileges required
None
User interaction
Required
Attack complexity
Low
Impact type
Code execution
Confidentiality · integrity · availability
High · High · High
Fix status
Partial Red Hat: 1 fixed, 2 without a fix

Attack profile from CVSS 3.1 · CISA ADP. Fix status from CNA and Red Hat. Impact type from CWE-190 and the CVSS impact.

Summary

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.

Why it matters now

Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.04165 90th percentileScored 2026-11-07
Public exploit Yes 3 exploit referencesTagged by NVD
Fix Partial Red Hat: 1 advisoryRed Hat: 1 fixed, 2 without a fix

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
None
Automatable
No
Technical impact
Total

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
——all versions—No fix listedCNA
  • — Vendor— Affected all versions Fixed in — No fix listed CNA

CPE configurations NVD · 1

CPEVersionsRoleVendor
cpe:2.3:a:gnu:cpio:*:*:*:*:*:*:*:*up to 2.13VulnerableGNU
  • cpe:2.3:a:gnu:cpio:*:*:*:*:*:*:*:* Versions up to 2.13 Vulnerable ·GNU

Remediation

Red Hat 1 advisory

  • RHSA-2022:1991 Released 2022-05-10 · Red Hat rating Moderate
    cpio security update
    • Red Hat Enterprise Linux BaseOS (v. 8) cpio-2.12-11.el8

Vendor assessments

Red Hat

Red Hat rating: Moderate. Red Hat's page for this CVE →

ProductStatusPlan or fix
Red Hat Enterprise Linux 6AffectedNo fix planned: Out of support scope
Red Hat Enterprise Linux 7AffectedNo fix planned: Out of support scope
Red Hat Enterprise Linux BaseOS (v. 8)Fixed RHSA-2022:1991
Not affected: 1 product
  • Red Hat Enterprise Linux 9

Timeline

  1. 2026-10-02 Threatist record created from CVE-2021-38185
  2. 2026-10-03 Alias added: GHSA-pp74-ghrg-jwfh

References

  • TI-2023-06601 Cpio: extraction allows symlinks which enables remote command execution CVSS 3.1MEDIUM 5.3
  • TI-2010-03976 cpio, as used in build 2007.05.10, 2010.07.28, and possibly other versions, allows remote… CVSS 3.1HIGH 7.2
  • TI-2010-00595 Heap-based buffer overflow in the rmt_read__ function in lib/rtapelib.c in the rmt client… CVSS 2.0MEDIUM 6.8
  • TI-2016-01868 The cpio_safer_name_suffix function in util.c in cpio 2.11 allows remote attackers to… CVSS 3.0MEDIUM 6.5
  • TI-2019-11070 Improper input validation in Red Hat cpio CVSS 3.1HIGH 7.3
  • TI-2014-07398 Heap-based buffer overflow in the process_copy_in function in GNU Cpio 2.11 allows remote… CVSS 2.0MEDIUM 5.0
See all 11 →

Sources