CVE-2023-32193: Github.com/rancher/norman Cross-Site Scripting Vulnerability

HIGH
Advisory Identifier: GHSA-r8f4-hv23-6qp6
CVSS 8.3
CWE-80
Published
Advisory Summary

CVE-2023-32193 is a HIGH (CVSS 8.3) cross-site scripting vulnerability (CWE-80: Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS)) affecting Github.com/rancher/norman libraries in the Go ecosystem. The issue involves norman api cross-site scripting vulnerability. Remediation is available by upgrading affected packages to version 0.0.0-20240207153100-3bb70b772b52.

CVE-2023-32193 at a Glance

CVE Identifier CVE-2023-32193
GHSA Identifier GHSA-r8f4-hv23-6qp6
Severity HIGH
CVSS v3.1 Base Score 8.3
CWE Classification CWE-80: Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS)
Affected Product Github.com/rancher/norman
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 8.3

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:L).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction Required (UI:R)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability Low (A:L)

How to Fix CVE-2023-32193

To remediate this vulnerability, upgrade all affected Github.com/rancher/norman dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/rancher/norman fixed: 0.0.0-20240207153100-3bb70b772b52
Upgrade github.com/rancher/norman to 0.0.0-20240207153100-3bb70b772b52
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/rancher/norman

How to Check if You Are Affected

To determine whether your application is affected by CVE-2023-32193, inspect your project dependencies for Github.com/rancher/norman:

inspect dependencies for github.com/rancher/norman

Analyze the terminal output to locate any version of Github.com/rancher/norman in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.0.0-20240207153100-3bb70b772b52), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-80: Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS), where the product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes special characters such as "<", ">", and "&" that could be interpreted as web-scripting elements when they are sent to a downstream component that processes web pages. In Github.com/rancher/norman, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact A vulnerability has been identified in which unauthenticated cross-site scripting (XSS) in Norman's public API endpoint can be exploited. This can lead to an attacker exploiting the vulnerability to trigger JavaScript code and execute commands remotely. The attack vector was identified as a Reflected XSS. Norman API propagates malicious payloads from user input to the UI, which renders the output. For example, a malicious URL gets rendered into a script that is executed on a page. The changes addressed by this fix are: - Encode input that comes from the request URL before adding it to the response. - The request input is escaped by changing the URL construction that is used for links to use `url.URL`. - The request input is escaped by escaping the JavaScript and CSS variables with attribute encoding as defined by [OWASP](https://cheatsheetseries.owasp.org/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.html#output-encoding-rules-summary). ### Patches Patched versions include the following commits: | Branch | Commit | | -------- | ------- | | master | 3bb70b7 | | release/v2.8 | a6a6cf5 | | release/v2.7 | cb54924 | | release/v2.7.s3 | 7b2b467 | | release/v2.6 | bd13c65 | ### Workarounds There is no direct mitigation besides updating Norman API to a patched version. ### References If you have any questions or comments about this advisory: - Reach out to the [SUSE Rancher Security team](https://github.com/rancher/rancher/security/policy) for security-related inquiries. - Open an issue in the [Rancher](https://github.com/rancher/rancher/issues/new/choose) repository. - Verify with our [support matrix](https://www.suse.com/suse-rancher/support-matrix/all-supported-versions/) and [product support lifecycle](https://www.suse.com/lifecycle/).

CVE-2023-32193 Affected Github.com/rancher/norman Versions

1 component(s)
Fixed Versions:
0.0.0-20240207153100-3bb70b772b52
Product / Package Ecosystem Affected Versions Fixed Version
github.com/rancher/norman
Go
< 0.0.0-20240207153100-3bb70b772b52
0.0.0-20240207153100-3bb70b772b52

References

Frequently Asked Questions

What is CVE-2023-32193?
CVE-2023-32193 is a security vulnerability in Github.com/rancher/norman involving Norman API Cross-site Scripting Vulnerability under CWE-80: Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS).
Which Github.com/rancher/norman versions are affected?
Affected versions include releases prior to 0.0.0-20240207153100-3bb70b772b52 across affected packages: github.com/rancher/norman.
What version fixes CVE-2023-32193?
Upgrading to 0.0.0-20240207153100-3bb70b772b52 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/rancher/norman affected?
Yes, github.com/rancher/norman is affected in releases prior to 0.0.0-20240207153100-3bb70b772b52. Upgrade your dependency to 0.0.0-20240207153100-3bb70b772b52 or later.
What is the CVSS score of CVE-2023-32193?
CVE-2023-32193 has a CVSS v3.1 base score of 8.3 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:L.
What CWE is associated with CVE-2023-32193?
CVE-2023-32193 is classified under CWE-80: Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS) (The product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes special characters such as "<", ">", and "&" that could be interpreted as web-scripting elements when they are sent to a downstream component that processes web pages.).
How can I check Go dependencies for CVE-2023-32193?
Run the dependency tree command: 'inspect dependencies for github.com/rancher/norman'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-r8f4-hv23-6qp6",
  "modified" : "2024-10-16T17:25:49Z",
  "published" : "2024-02-08T18:45:49Z",
  "aliases" : [ "CVE-2023-32193" ],
  "summary" : "Norman API Cross-site Scripting Vulnerability",
  "details" : "### Impact\nA vulnerability has been identified in which unauthenticated cross-site scripting (XSS) in Norman's public API endpoint can be exploited. This can lead to an attacker exploiting the vulnerability to trigger JavaScript code and execute commands remotely. \n\nThe attack vector was identified as a Reflected XSS.\n\nNorman API propagates malicious payloads from user input to the UI, which renders the output. For example, a malicious URL gets rendered into a script that is executed on a page.\n\nThe changes addressed by this fix are:\n- Encode input that comes from the request URL before adding it to the response.\n- The request input is escaped by changing the URL construction that is used for links to use `url.URL`.\n- The request input is escaped by escaping the JavaScript and CSS variables with attribute encoding as defined by [OWASP](https://cheatsheetseries.owasp.org/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.html#output-encoding-rules-summary).\n\n### Patches\nPatched versions include the following commits:\n\n| Branch    | Commit |\n| -------- | ------- |\n| master  | 3bb70b7 |\n| release/v2.8 | a6a6cf5 |\n| release/v2.7 | cb54924 |\n| release/v2.7.s3 | 7b2b467 |\n| release/v2.6 | bd13c65 |\n\n### Workarounds\nThere is no direct mitigation besides updating Norman API to a patched version.\n\n### References\nIf you have any questions or comments about this advisory:\n\n- Reach out to the [SUSE Rancher Security team](https://github.com/rancher/rancher/security/policy) for security-related inquiries.\n- Open an issue in the [Rancher](https://github.com/rancher/rancher/issues/new/choose) repository.\n- Verify with our [support matrix](https://www.suse.com/suse-rancher/support-matrix/all-supported-versions/) and [product support lifecycle](https://www.suse.com/lifecycle/).\n",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:L"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/rancher/norman"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.0.0-20240207153100-3bb70b772b52"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/rancher/norman/security/advisories/GHSA-r8f4-hv23-6qp6"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-32193"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rancher/norman/commit/3bb70b772b52297feac64f5fdeb1b13c06c37e39"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rancher/norman/commit/7b2b467995e6dfab6d4a5dee8dffc15033ae8269"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rancher/norman/commit/a6a6cf5696088c32002953d36b75bdcc84f2399e"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rancher/norman/commit/bd13c653293b9b5e0b37e8a6ccd1c3277f4623ed"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rancher/norman/commit/cb54924f25c7666511a913cd41834299ef22dba4"
  }, {
    "type" : "WEB",
    "url" : "https://bugzilla.suse.com/show_bug.cgi?id=CVE-2023-32193"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/rancher/norman"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-80" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-02-08T18:45:49Z",
    "nvd_published_at" : "2024-10-16T13:15:12Z"
  }
}