CVE-2022-32190: Failure to strip relative path components in net/url

Published Sep 6, 2022
·
Updated

A flaw was found in the golang package. The JoinPath doesn't remove the ../ path components appended to a domain that is not terminated by a slash, possibly leading to a directory traversal attack.

Other sources

Golang Go could allow a remote attacker to traverse directories on the system, caused by not remove ../ path elements appended to a relative path in JoinPath and URL.JoinPath. An attacker could send a specially-crafted URL request containing "dot dot" sequences (/../) to view arbitrary files on the system.

— IBM

JoinPath and URL.JoinPath do not remove ../ path elements appended to a relative path. For example, JoinPath("https://go.dev", "../go") returns the URL "https://go.dev/../go", despite the JoinPath documentation stating that ../ path elements are removed from the result.

JoinPath and URL.JoinPath would not remove ../ path components appended to a relative path. For example, JoinPath("https://go.dev", "../go") returned the URL https://go.dev/../go, despite the JoinPath documentation stating that ../ path elements are cleaned from the result.

References: https://go.dev/issue/54385 https://groups.google.com/g/golang-announce/c/x49AQzIVX-s/m/0tgO0pjiBQAJ

Upstream Commits: Master : https://github.com/golang/go/commit/0765da5884adcc8b744979303a36a27092d8fc51 Branch.go1.19 : https://github.com/golang/go/commit/28335508913a46e05ef0c04a18e8a1a6beb775ec

— Red Hat

Affected Software

28 affected componentsFixes available
redhat/openshift-clients<0:4.12.0-202301042257.p0.g854f807.assembly.stream.el8
0:4.12.0-202301042257.p0.g854f807.assembly.stream.el8
redhat/podman<3:4.2.0-7.rhaos4.12.el9
3:4.2.0-7.rhaos4.12.el9
redhat/runc<3:1.1.6-4.rhaos4.12.el8
3:1.1.6-4.rhaos4.12.el8
redhat/kubevirt<0:4.13.0-1469.el7
0:4.13.0-1469.el7
redhat/kubevirt<0:4.13.0-1469.el8
0:4.13.0-1469.el8
redhat/kubevirt<0:4.13.0-1469.el9
0:4.13.0-1469.el9
Golang Go=1.19.0
Golang Go=1.19.0-beta1
Golang Go=1.19.0-rc1
Golang Go=1.19.0-rc2
IBM Data Virtualization on Cloud Pak for Data<=3.0
IBM Watson Query on Cloud Pak for Data<=2.2
IBM Watson Query on Cloud Pak for Data<=2.1
IBM Watson Query on Cloud Pak for Data<=2.0
IBM Data Virtualization on Cloud Pak for Data<=1.8
IBM Data Virtualization on Cloud Pak for Data<=1.7
redhat/golang<1.19.1
1.19.1
debian/golang-1.19<1.19.1-1
1.19.1-1
debian/golang-1.19
1.19.8-2
alpine/go<1.18.6-r0
1.18.6-r0
alpine/go<1.19.1-r0
1.19.1-r0
alpine/go<1.19.1-r0
1.19.1-r0
alpine/go<1.19.1-r0
1.19.1-r0
alpine/go<1.19.1-r0
1.19.1-r0
alpine/go<1.19.1-r0
1.19.1-r0
alpine/go<1.19.1-r0
1.19.1-r0
alpine/go<1.19.1-r0
1.19.1-r0
alpine/go<1.19.1-r0
1.19.1-r0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade redhat/openshift-clients to a version that resolves this vulnerability.

    Fixed in 0:4.12.0-202301042257.p0.g854f807.assembly.stream.el8
  2. Upgrade

    Upgrade redhat/podman to a version that resolves this vulnerability.

    Fixed in 3:4.2.0-7.rhaos4.12.el9
  3. Upgrade

    Upgrade redhat/runc to a version that resolves this vulnerability.

    Fixed in 3:1.1.6-4.rhaos4.12.el8
  4. Upgrade

    Upgrade redhat/kubevirt to a version that resolves this vulnerability.

    Fixed in 0:4.13.0-1469.el7
  5. Upgrade

    Upgrade redhat/kubevirt to a version that resolves this vulnerability.

    Fixed in 0:4.13.0-1469.el8
  6. Upgrade

    Upgrade redhat/kubevirt to a version that resolves this vulnerability.

    Fixed in 0:4.13.0-1469.el9
  7. Upgrade

    Upgrade redhat/golang to a version that resolves this vulnerability.

    Fixed in 1.19.1
  8. Upgrade

    Upgrade debian/golang-1.19 to a version that resolves this vulnerability.

    Fixed in 1.19.8-2
  9. Upgrade

    Upgrade alpine/go to a version that resolves this vulnerability.

    Fixed in 1.18.6-r0
  10. Upgrade

    Upgrade alpine/go to a version that resolves this vulnerability.

    Fixed in 1.19.1-r0
  11. Upgrade

    Upgrade debian/golang-1.19 to a version that resolves this vulnerability.

    Fixed in 1.19.1-1
  12. Upgrade

    Upgrade golang to a version that resolves this vulnerability.

    Patch 28335508913a46e05ef0c04a18e8a1a6beb775ec
  13. Upgrade

    Upgrade golang to a version that resolves this vulnerability.

    Patch 0765da5884adcc8b744979303a36a27092d8fc51

Event History

Sep 6, 2022
CVE Published
12:00 AM
Data Sourced
via Red Hat·06:03 PM
DescriptionSeverityAffected Software
Sep 13, 2022
CVE Published
via MITRE·05:08 PM
Data Sourced
via MITRE·05:08 PM
DescriptionWeakness
Data Sourced
via NVD·06:15 PM
RemedyDescriptionSeverityWeaknessAffected Software
Data Sourced
via OSV·06:15 PM
DescriptionSeverityAffected Software
Apr 3, 2025
Data Sourced
via IBM·12:00 AM
DescriptionAffected Software

Frequently Asked Questions

1

What is the vulnerability ID of this flaw in the golang package?

The vulnerability ID is CVE-2022-32190.

2

What is the severity of CVE-2022-32190?

The severity of CVE-2022-32190 is high.

3

How does JoinPath and URL.JoinPath in the golang package behave in the presence of ../ path elements?

JoinPath and URL.JoinPath in the golang package do not remove ../ path elements from the result.

4

Are there any known remedies for this vulnerability?

Yes, there are known remedies for this vulnerability.

5

Where can I find more information about CVE-2022-32190?

You can find more information about CVE-2022-32190 on the CVE website, NVD, GitHub Go issue, Google Groups announcement, Red Hat Bugzilla, and Red Hat Access website.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203