CVE-2023-45283Insecure parsing of Windows paths with a \??\ prefix in path/filepath
The filepath package does not recognize paths with a \??\ prefix as special. On Windows, a path beginning with \??\ is a Root Local Device path equivalent to a path beginning with \\?\. Paths with a \??\ prefix may be used to access arbitrary locations on the system. For example, the path \??\c:\x is equivalent to the more common path c:\x. Before fix, Clean could convert a rooted path such as \a\..\??\b into the root local device path \??\b. Clean will now convert this to .\??\b. Similarly, Join(\, ??, b) could convert a seemingly innocent sequence of path elements into the root local device path \??\b. Join will now convert this to \.\??\b. In addition, with fix, IsAbs now correctly reports paths beginning with \??\ as absolute, and VolumeName correctly reports the \??\ prefix as a volume name. UPDATE: Go 1.20.11 and Go 1.21.4 inadvertently changed the definition of the volume name in Windows paths starting with \?, resulting in filepath.Clean(\?\c:) returning \?\c: rather than \?\c:\ (among other effects). The previous behavior has been restored.
What to do
Fixed builds are available from Go: see the table below for the fixed version per release.
Ubuntu has not shipped a fix for every release yet.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 24.04 | golang-1.21 | Not affected vulnerable_code_not_present | ||
| Ubuntu 22.04 | golang-1.13 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 22.04 | golang-1.17 | Under investigation | UBUNTU-CVE-2023-45283 | |
| Ubuntu 22.04 | golang-1.18 | Under investigation | UBUNTU-CVE-2023-45283 | |
| Ubuntu 22.04 | golang-1.20 | Not affected vulnerable_code_not_present | ||
| Ubuntu 22.04 | golang-1.21 | Not affected vulnerable_code_not_present | ||
| Ubuntu 20.04 | golang-1.13 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 20.04 | golang-1.14 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 20.04 | golang-1.16 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 20.04 | golang-1.18 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 20.04 | golang-1.20 | Not affected vulnerable_code_not_present | ||
| Ubuntu 20.04 | golang-1.21 | Not affected vulnerable_code_not_present | ||
| Ubuntu 18.04 | golang-1.10 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 18.04 | golang-1.13 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 18.04 | golang-1.16 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 18.04 | golang-1.18 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 18.04 | golang-1.8 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 18.04 | golang-1.9 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 16.04 | golang | Fix pending | ||
| Ubuntu 16.04 | golang-1.10 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 16.04 | golang-1.13 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 16.04 | golang-1.18 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 16.04 | golang-1.6 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 14.04 | golang | Fix pending | ||
| Ubuntu 14.04 | golang-1.10 | Fix pending | UBUNTU-CVE-2023-45283 | |
| Ubuntu 14.04 | golang-1.6 | Fix pending | ||
| Debian 12 | golang-1.19 | Will not fix Debian rates this unimportant for its packages (a minor issue, or one that doesn't affect Debian's build), so no security update is planned. | DEBIAN-CVE-2023-45283 | |
| Go library | stdlib | Fixed | 1.21.4 | GO-2023-2185 |
What the vendor says
As published in the CVE record by Go, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
- Go standard library path/filepath: affected: before 1.20.11, 1.21.0-0 to before 1.21.4; fixed in
1.20.11,1.21.4 - Go standard library internal/safefilepath: affected: before 1.20.11, 1.21.0-0 to before 1.21.4; fixed in
1.20.11,1.21.4 - Go standard library path/filepath: affected: 1.20.11 to before 1.20.12, 1.21.4 to before 1.21.5; fixed in
1.20.12,1.21.5
References
- https://go.dev/issue/63713
- https://go.dev/cl/540277
- https://groups.google.com/g/golang-announce/c/4tU8LZfBFkY
- https://go.dev/issue/64028
- https://go.dev/cl/541175
- https://groups.google.com/g/golang-dev/c/6ypN5EjibjM/m/KmLVYH_uAgAJ
- https://pkg.go.dev/vuln/GO-2023-2185
- http://www.openwall.com/lists/oss-security/2023/12/05/2
- https://security.netapp.com/advisory/ntap-20231214-0008/
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.