VDB

CVE-2022-2879

CVE-2022-2879 PUBLISHED

Unbounded memory consumption when reading headers in archive/tar

Reported by go · Published October 14, 2022

archive/tar is fixed in 1.19.2 and 1.18.7 (Go Modules)

Reader.Read does not set a limit on the maximum size of file headers. A maliciously crafted archive could cause Read to allocate unbounded amounts of memory, potentially causing resource exhaustion or panics. After fix, Reader.Read limits the maximum size of header blocks to 1 MiB.

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
archive/tarGo Modules1.19.2, 1.18.7
stdlibGo Modules1.19.2, 1.18.7
golang-miscAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golang-sharedAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golang-docsAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golang-srcAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golangAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golang-binAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golistAmazon Linux0.10.1-11.amzn2023.0.3, 0.10.1-10.amzn2.0.2
golang-raceAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golang-testsAmazon Linux1.19.3-2.amzn2023.0.2, 1.18.8-1.amzn2.0.1
golangBitnami1.19.2, 1.18.7

5 more packages have a fixed version. See every fix in Lookup.

Affected products

VendorProductVersions
Go standard libraryarchive/tar0, 1.19.0-0
amazon:2023golang-misc0
amazon:2023golang-shared0
amazon:2023golang-docs0
Go standard libraryarchive/tar1.19.0-0, 0
amazon:2023golang-src0
amazon:2023golang0
amazon:2golang-bin0
amazon:2golang-src0
amazon:2golang0
amazon:2golist0
amazon:2023golang-race0
amazon:2golang-docs0
amazon:2golang-shared0
amazon:2golang-tests0
amazon:2023golist0
amazon:2golang-misc0
amazon:2023golang-tests0
amazon:2023golang-bin0
amazon:2golang-race0

…and 3 more

Timeline

  • Oct 6, 2022 CVE Published
  • Oct 15, 2022 EPSS Score (30 in total, the first dated here)
  • Nov 21, 2024 CVE Updated
  • Mar 10, 2026 Security Advisory (82 in total, the first dated here)
  • Jun 27, 2026 Coalition ESS Score
  • Jul 2, 2026 Distribution Patch (78 in total, the first dated here)

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2022-2879
vulnetix vdb fixes CVE-2022-2879

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2022-2879/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

References

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›