CVE-2018-16873
Improper Input Validation
CVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H
Description
In Go before 1.10.6 and 1.11.x before 1.11.3, the "go get" command is vulnerable to remote code execution when executed with the -u flag and the import path of a malicious Go package, or a package that imports it directly or indirectly. Specifically, it is only vulnerable in GOPATH mode, but not in module mode (the distinction is documented at https://golang.org/cmd/go/#hdr-Module_aware_go_get). Using custom domains, it's possible to arrange things so that a Git repository is cloned to a folder named ".git" by using a vanity import path that ends with "/.git". If the Git repository root contains a "HEAD" file, a "config" file, an "objects" directory, a "refs" directory, with some work to ensure the proper ordering of operations, "go get -u" can be tricked into considering the parent directory as a repository root, and running Git commands on it. That will use the "config" file in the original Git repository root for its configuration, and if that config file contains malicious commands, they will execute on the system running "go get -u".
Official description from the CVE record, published by redhat. Copyright © 1999-2026 The MITRE Corporation. See /security/cve/legal for the CVE license. View the record on cve.org
Key data
CVSS 3.0 High 7.5
CVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H
Attack vector: Network
The vulnerable component can be reached over a network, possibly from the Internet.
Attack complexity: High
The attack depends on conditions outside the attacker's control, so it takes preparation.
Privileges required: None
No account or privileges are needed.
User interaction: Required
A user has to do something first, such as opening a file or following a link.
Scope: Unchanged
The impact stays within the vulnerable component.
Confidentiality impact: High
Serious or total effect on the secrecy of data.
Integrity impact: High
Serious or total effect on the trustworthiness of data.
Availability impact: High
Serious or total effect on availability.
| Metric | Value | What it means |
|---|---|---|
| Attack vector | Network | The vulnerable component can be reached over a network, possibly from the Internet. |
| Attack complexity | High | The attack depends on conditions outside the attacker's control, so it takes preparation. |
| Privileges required | None | No account or privileges are needed. |
| User interaction | Required | A user has to do something first, such as opening a file or following a link. |
| Scope | Unchanged | The impact stays within the vulnerable component. |
| Confidentiality impact | High | Serious or total effect on the secrecy of data. |
| Integrity impact | High | Serious or total effect on the trustworthiness of data. |
| Availability impact | High | Serious or total effect on availability. |
CVSS is owned and managed by FIRST.Org, Inc. (FIRST) and is used by permission. Each CVSS score on this site is shown together with its vector string, as published in the CVE record by the source named next to it. Learn more at first.org/cvss.
EPSS
- Score
- 0.66252 (66.3% probability)
- Percentile
- 99.3%
- Scores of
- Nov 10, 2026
- Model
- v2026.06.15
Weakness (CWE)
- CWE-20Improper Input Validation
Affected products
[UNKNOWN] golang
- affected: 1.10.6
- affected: 1.11.3
References
- 106226 (securityfocus.com)vdb-entry
- GLSA-201812-09 (security.gentoo.org)vendor-advisory
- bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-16873
- groups.google.com/forum/?pli=1
- openSUSE-SU-2019:1079 (lists.opensuse.org)vendor-advisory
- openSUSE-SU-2019:1444 (lists.opensuse.org)vendor-advisory
- openSUSE-SU-2019:1499 (lists.opensuse.org)vendor-advisory
- openSUSE-SU-2019:1506 (lists.opensuse.org)vendor-advisory
- openSUSE-SU-2019:1703 (lists.opensuse.org)vendor-advisory
- openSUSE-SU-2020:0554 (lists.opensuse.org)vendor-advisory
- [debian-lts-announce] 20210313 [SECURITY] [DLA 2591-1] golang-1.7 security update (lists.debian.org)mailing-list
- [debian-lts-announce] 20210313 [SECURITY] [DLA 2592-1] golang-1.8 security update (lists.debian.org)mailing-list
Timeline
- ID reserved
- Record published
- Record last updated
Look up another CVE
About CubePath
Data from the CVE Program (MITRE), CISA KEV and FIRST EPSS. CVSS is owned by FIRST and used by permission. Not affiliated with or endorsed by MITRE, CISA or FIRST. Data as of Nov 10, 2026, 19:48 UTC. Sources and licenses