CVE-2023-23630: Eta Cross-Site Scripting Vulnerability

HIGH
Advisory Identifier: GHSA-xrh7-m5pp-39r6
CVSS 8.6
CWE-79
Published
Advisory Summary

CVE-2023-23630 is a HIGH (CVSS 8.6) cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting Eta libraries in the npm ecosystem. The issue involves xss attack with express api. Remediation is available by upgrading affected packages to version 2.0.0.

CVE-2023-23630 at a Glance

CVE Identifier CVE-2023-23630
GHSA Identifier GHSA-xrh7-m5pp-39r6
Severity HIGH
CVSS v3.1 Base Score 8.6
CWE Classification CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Affected Product Eta
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 8.6

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:N/S:U/C:L/I:L/A:H).

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

How to Fix CVE-2023-23630

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

eta fixed: 2.0.0
npm install eta@2.0.0
Verify Direct and Transitive Dependencies

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

npm ls eta

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2023-23630, inspect your project dependencies using npm:

npm ls eta

Analyze the terminal output to locate any version of Eta in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.0.0), your application is affected.

Note: The npm ls eta command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'), where the product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. In Eta, 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 XSS attack - anyone using the Express API is impacted ### Patches The problem has been resolved. Users should upgrade to version 2.0.0. ### Workarounds Don't pass user supplied data directly to `res.renderFile`. ### References _Are there any links users can visit to find out more?_ See https://github.com/eta-dev/eta/releases/tag/v2.0.0

CVE-2023-23630 Affected Eta Versions

1 component(s)
Fixed Versions:
2.0.0
Product / Package Ecosystem Affected Versions Fixed Version
eta
npm
< 2.0.0
2.0.0

References

Frequently Asked Questions

What is CVE-2023-23630?
CVE-2023-23630 is a security vulnerability in Eta involving XSS Attack with Express API under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting').
Which Eta versions are affected?
Affected versions include releases prior to 2.0.0 across affected packages: eta.
What version fixes CVE-2023-23630?
Upgrading to 2.0.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is eta affected?
Yes, eta is affected in releases prior to 2.0.0. Upgrade your dependency to 2.0.0 or later.
What is the CVSS score of CVE-2023-23630?
CVE-2023-23630 has a CVSS v3.1 base score of 8.6 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:H.
What CWE is associated with CVE-2023-23630?
CVE-2023-23630 is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') (The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.).
How can I check npm dependencies for CVE-2023-23630?
Run the dependency tree command: 'npm ls eta'. 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-xrh7-m5pp-39r6",
  "modified" : "2023-02-08T22:37:39Z",
  "published" : "2023-01-31T22:39:40Z",
  "aliases" : [ "CVE-2023-23630" ],
  "summary" : "XSS Attack with Express API",
  "details" : "### Impact\nXSS attack - anyone using the Express API is impacted\n\n### Patches\nThe problem has been resolved. Users should upgrade to version 2.0.0.\n\n### Workarounds\nDon't pass user supplied data directly to `res.renderFile`. \n\n### References\n_Are there any links users can visit to find out more?_\nSee https://github.com/eta-dev/eta/releases/tag/v2.0.0",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "eta"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.0.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/eta-dev/eta/security/advisories/GHSA-xrh7-m5pp-39r6"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-23630"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/eta-dev/eta/commit/5651392462ee0ff19d77c8481081a99e5b9138dd"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/eta-dev/eta"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/eta-dev/eta/releases/tag/v2.0.0"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-79" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2023-01-31T22:39:40Z",
    "nvd_published_at" : "2023-02-01T01:15:00Z"
  }
}