CVE-2025-59840 — Vulnerability in vega-expression — CVE Details
Vega Cross-Site Scripting (XSS) via expressions abusing toString calls in environments using the VEGA_DEBUG global variable
Summary
Advisory Timeline
- First published November 13, 2025 (333 days ago).
- Last revised September 10, 2026 — 300 days after initial publication.
Remediation
Upgrade to the fixed version using your package manager.
npm install vega-expression@5.2.1
npm install vega@6.2.0
npm install vega-interpreter@1.2.1
npm install vega-expression@6.1.0
npm install vega-interpreter@2.2.1
After upgrading, run your dependency scanner again to confirm the vulnerability is resolved.
Affected Packages (5)
Affects 1 ecosystem: npm (3).
| Package | Ecosystem | Affected | Fixed In |
|---|---|---|---|
| vega-expression | npm | All versions | 5.2.1 |
| vega | npm | All versions | 6.2.0 |
| vega-interpreter | npm | All versions | 1.2.1 |
| vega-expression | npm | All versions | 6.1.0 |
| vega-interpreter | npm | All versions | 2.2.1 |
Vulnerability Classification
Common Weakness Enumeration (CWE) identifiers for this vulnerability type.
- CWE-79Cross-site Scripting (XSS)MITRE
CVSS Score Breakdown
What the CVSS (Common Vulnerability Scoring System) 8.1 score means for each attack dimension.
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N
References
- https://github.com/vega/vega/security/advisories/GHSA-7f2v-3qq3-vvjfWEB
- https://nvd.nist.gov/vuln/detail/CVE-2025-59840ADVISORY
- https://github.com/vega/editor/blob/e102355589d23cdd0dbfd607a2cc5f9c5b7a4c55/src/components/renderer/renderer.tsx#L239WEB
- https://github.com/vega/editor/blob/e102355589d23cdd0dbfd607a2cc5f9c5b7a4c55/src/index.tsx#L14-L16WEB
- https://github.com/vega/vegaPACKAGE
- https://vega.github.io/editor/#/url/vega/N4IgJAzgxgFgpgWwIYgFwhgF0wBwqgegIDc4BzJAOjIEtMYBXAI0poHsDp5kTykSArJQBWENgDsQAGhAB3GgBN6aAMwCADDPg0yWVRplIGmNhBoAvOGhDiJVmQrjQATjRyZ2k9ABU2ZMgA2cAAEAELGJpIyZmTiSAEQaADaoHEIVugm-kHSIMTxDBmYzoUyEsmgcKTimImooJgAnjgZIFABNFAA1rnIzl1prVA0zu1WAL4yDDgKSJitWYEhAPzBAGbxECGowcWFIOMAupOpSOnWSAoKAGI0AfPOueWoKSBVcDV1Dc2tCGwMWz+pFyYgYo1a8nECjYsgOUxmc1aAApgCYAMrFGjiMiod41SjEGhwWSUABqAFEAOIAQQA+gARcmhACqlIJfEoAGEkOJ8hAABI8hRBZyUHDONgmJotSgSKTBPGYAByZzguOqmAJRJJUAkYiClACfiktJgQpF+GADChcDWWLgClQAHJ4nBnJgkWxXLRxMEANTBAAGwQAGmi0cEJMFSM4zFHAwGKTSGUzWWSqXSKQAlNEASQA8kqAJROyam81u3M2gAe6o+msJxMoVXi4yLfoAjAdjscgAWEB
- https://vega.github.io/vega/usage/interpreterWEB
Frequently Asked Questions
- What is CVE-2025-59840?
- Vega Cross-Site Scripting (XSS) via expressions abusing toString calls in environments using the VEGA_DEBUG global variable This vulnerability has been assigned a severity rating of HIGH (CVSS score: 8.1/10).
- How do I check if my project is affected by CVE-2025-59840?
- CVE-2025-59840 affects vega-expression, vega and vega-interpreter. Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2025-59840 and 200,000+ other known vulnerabilities.
Severity & Exploitability
High exploitability or significant impact. Prioritize remediation within days.
Also Known As
Related CVEs
- CVE-2026-107375HIGH
JHipster: SQL Injection in the Parameter of JHipster-Generated Reactive (WebFlux + R2DBC) Applicationssort
- CVE-2026-107384HIGH
MariaDB Connector/Node.js: SQL injection through object keys in SET expansion (permitSetMultiParamEntries)
Check if you're affected
Scan your dependencies to see if this vulnerability affects your projects.
Scan Your Dependencies