7.1high
Tar extraction in moby/go-archive can write outside the destination directory via link following
- Severity
- 7.1high CVSS:4.0 by Docker
- Exploit likelihood
- 0.47% (higher than 42% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- Docker
- Also known as
- GHSA-hfg8-hc9c-6c3hBIT-DOCKER-CLI-2026-17106GO-2026-6253
Description
The tar extraction routines in moby/go-archive (Unpack, UnpackLayer, Untar/UntarUncompressed, and the ApplyLayer helpers) do not confine filesystem operations to the destination directory. The extractor decides where each archive entry lands using lexical string checks and then performs the filesystem operation on a path that is resolved by the OS, so links introduced by the archive can be followed out of the destination directory. An attacker who controls the contents of an archive can create or overwrite files at arbitrary paths writable by the extracting process.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| github.com/moby/go-archive | before 0.3.0 | CVE List |
| Docker Docker Sandboxes | before 0.38.0 | CVE List |
| Docker Docker Desktop | before 4.86.0 | CVE List |
| Docker Docker Engine | before 29.7.0 | CVE List |
| Docker Docker CLI | before 29.7.0 | CVE List |
| Docker Docker Compose | before 5.4.0 | CVE List |
| github.com/moby/go-archive (Go) | before 0.3.0 | GitHub Advisory Database, Go Vulnerability Database |
| docker-cli (Bitnami) | before 29.7.0 | Bitnami Vulnerability Database |
All scores
| Docker | 7.1high CVSS:4.0 | CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N |
| GitHub | high CVSS:4.0 | CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N |
| Bitnami Vulnerability Database | high rating |
Classification
What each source says
CVE List
The tar extraction routines in moby/go-archive (Unpack, UnpackLayer, Untar/UntarUncompressed, and the ApplyLayer helpers) do not confine filesystem operations to the destination directory. The extractor decides where each archive entry lands using lexical string checks and then performs the filesystem operation on a path that is resolved by the OS, so links introduced by the archive can be followed out of the destination directory. An attacker who controls the contents of an archive can create or overwrite files at arbitrary paths writable by the extracting process.
GitHub Advisory Database
Summary
The tar extraction routines in moby/go-archive (Unpack, UnpackLayer, Untar/UntarUncompressed, and the ApplyLayer helpers) do not confine filesystem operations to the destination directory. A crafted archive can create or overwrite files outside the intended destination.
Details
The extractor decides where each archive entry lands using lexical string checks and then performs the filesystem operation on a path that is resolved by the OS, so a links introduced by the archive can be followed out of the destination directory.
Impact
An attacker who controls the contents of archive can create or overwrite files at arbitrary paths writable by the extracting process.
Workarounds
Only extract trusted archives.
Go Vulnerability Database
moby/go-archive: Crafted tar archive can write outside the extraction directory in github.com/moby/go-archive
References
Related
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-17106 changed 2026-08-19 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-hfg8-hc9c-6c3h changed 2026-09-10 | CC-BY-4.0 |
| Go Vulnerability Database | GO-2026-6253 changed 2026-09-01 | CC-BY-4.0 |
| NVD | CVE-2026-17106 changed 2026-08-28 | Public domain |
| Bitnami Vulnerability Database | BIT-DOCKER-CLI-2026-17106 changed 2026-08-24 | Apache-2.0 |