KaTeX is a JavaScript library for TeX math rendering on the web. Code that uses KaTeX's `trust` option, specifically that provides a function to blacklist certain URL protocols, can be fooled by URLs in malicious inputs that use uppercase characters in the protocol. In particular, this can allow for malicious input to generate `javascript:` links in the output, even if the `trust` function tries to forbid this protocol via `trust: (context) => context.protocol !== 'javascript'`. Upgrade to KaTeX v0.16.10 to remove this vulnerability.
CVE-2024-28246 - Medium Severity Vulnerability
Vulnerable Library - katex-0.11.1.tgz
Fast math typesetting for the web.
Library home page: https://registry.npmjs.org/katex/-/katex-0.11.1.tgz
Path to dependency file: /package.json
Path to vulnerable library: /node_modules/katex/package.json
Dependency Hierarchy: - :x: **katex-0.11.1.tgz** (Vulnerable Library)
Found in HEAD commit: fb5f77da2e6a1abdc8035ddac751a729e7652710
Found in base branch: master
Vulnerability Details
KaTeX is a JavaScript library for TeX math rendering on the web. Code that uses KaTeX's `trust` option, specifically that provides a function to blacklist certain URL protocols, can be fooled by URLs in malicious inputs that use uppercase characters in the protocol. In particular, this can allow for malicious input to generate `javascript:` links in the output, even if the `trust` function tries to forbid this protocol via `trust: (context) => context.protocol !== 'javascript'`. Upgrade to KaTeX v0.16.10 to remove this vulnerability.
Publish Date: 2024-03-25
URL: CVE-2024-28246
CVSS 3 Score Details (5.5)
Base Score Metrics: - Exploitability Metrics: - Attack Vector: Network - Attack Complexity: Low - Privileges Required: Low - User Interaction: Required - Scope: Unchanged - Impact Metrics: - Confidentiality Impact: Low - Integrity Impact: Low - Availability Impact: Low
For more information on CVSS3 Scores, click here.Suggested Fix
Type: Upgrade version
Origin: https://www.cve.org/CVERecord?id=CVE-2024-28246
Release Date: 2024-03-25
Fix Resolution: 0.16.10
Step up your Open Source Security Game with Mend here