HashiCorp go-slug Vulnerable to Zip Slip Attack
cve-program · CVE-2025-0377
PublishedHashiCorp’s go-slug library is vulnerable to a zip-slip style attack when a non-existing user-provided path is extracted from the tar entry.
Read the publisher's advisoryeuvd · EUVD-2025-0202
PublishedHashiCorp’s go-slug library is vulnerable to a zip-slip style attack when a non-existing user-provided path is extracted from the tar entry.
Read the publisher's advisorynvd · CVE-2025-0377
PublishedHashiCorp’s go-slug library is vulnerable to a zip-slip style attack when a non-existing user-provided path is extracted from the tar entry.
Read the publisher's advisoryosv · GHSA-wpfp-cm49-9m9q
Published## Summary HashiCorp’s go-slug library is vulnerable to a zip-slip style attack when a non-existing user-provided path is extracted from the tar entry. This vulnerability, identified as CVE-2025-0377, is fixed in go-slug 0.16.3. ## Background HashiCorp’s go-slug shared library offers functions for packing and unpacking Terraform Enterprise compatible slugs. Slugs are gzip compressed tar files containing Terraform configuration files. ## Details When go-slug performs an extraction, the filename/extraction path is taken from the tar entry via the header.Name. It was discovered that the unpacking step improperly validated paths, potentially leading to path traversal, allowing an attacker to write an arbitrary file during extraction. ## Remediation Consumers of the go-slug shared library should evaluate the risk associated with this issue in the context of their go-slug usage and upgrade go-slug to 0.16.3 or later.
Read the publisher's advisoryosv · GO-2025-3413
PublishedHashiCorp go-slug Vulnerable to Zip Slip Attack in github.com/hashicorp/go-slug
Read the publisher's advisoryAffected versions, risk and source history
Related advisories and sources
Publishers link these advisories through the identifiers shown below. A shared identifier or date alone does not tell you whether your software is affected or whether the advisories describe the same cause.
CVE-2025-0377 · CVE overview and exploitation status
cve-program · CVE-2025-0377
euvd · EUVD-2025-0202
nvd · CVE-2025-0377
osv · GHSA-wpfp-cm49-9m9q
- https://nvd.nist.gov/vuln/detail/CVE-2025-0377
- https://discuss.hashicorp.com/t/hcsec-2025-01-hashicorp-go-slug-vulnerable-to-zip-slip-attack
osv · GO-2025-3413
Related changes
Linked by CVE identifierNo related changes are available here.