Invoking "go tool pack" does not sanitize output paths in cmd/go
Summary
| CVE | CVE-2026-39817 |
|---|---|
| State | PUBLISHED |
| Assigner | Go |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-05-07 20:16:42 UTC |
| Updated | 2026-05-08 22:16:29 UTC |
| Description | The "go tool pack" subcommand (usually used only by the compiler as an internal tool with known-good inputs) does not sanitize output filenames. Extracting a malicious archive file with the "pack" subcommand can write files to arbitrary locations on the filesystem. |
Risk And Classification
Primary CVSS: v3.1 5.9 MEDIUM from ADP
CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:N/I:H/A:N
EPSS: 0.000180000 probability, percentile 0.050070000 (date 2026-05-12)
Problem Types: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | ADP | DECLARED | 5.9 | MEDIUM | CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:N/I:H/A:N |
| 3.1 | 134c704f-9b21-4f2e-91b3-4a467353bcc0 | Secondary | 5.9 | MEDIUM | CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:N/I:H/A:N |
CVSS v3.1 Breakdown
Attack Vector
LocalAttack Complexity
LowPrivileges Required
LowUser Interaction
RequiredScope
ChangedConfidentiality
NoneIntegrity
HighAvailability
NoneCVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:N/I:H/A:N
Vendor Declared Affected Products
| Source | Vendor | Product | Version | Platforms |
|---|---|---|---|---|
| CNA | Go Toolchain | Cmd/go | affected 1.25.10 semver | Not specified |
| CNA | Go Toolchain | Cmd/go | affected 1.26.0-0 1.26.3 semver | Not specified |
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| pkg.go.dev/vuln/GO-2026-4979 | [email protected] | pkg.go.dev | |
| go.dev/issue/78778 | [email protected] | go.dev | |
| go.dev/cl/767520 | [email protected] | go.dev | |
| groups.google.com/g/golang-announce/c/qcCIEXso47M | [email protected] | groups.google.com | |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
Vendor Comments And Credit
Discovery Credit
CNA: Harshit Gupta (Mr HAX) (en)
There are currently no legacy QID mappings associated with this CVE.