CVE-2022-23647
CVSS V2 Medium 4.3
CVSS V3 Medium 6.1
Description
Prism is a syntax highlighting library. Starting with version 1.14.0 and prior to version 1.27.0, Prism's command line plugin can be used by attackers to achieve a cross-site scripting attack. The command line plugin did not properly escape its output, leading to the input text being inserted into the DOM as HTML code. Server-side usage of Prism is not impacted. Websites that do not use the Command Line plugin are also not impacted. This bug has been fixed in v1.27.0. As a workaround, do not use the command line plugin on untrusted inputs, or sanitize all code blocks (remove all HTML code text) from all code blocks that use the command line plugin.
Overview
- CVE ID
- CVE-2022-23647
- Assigner
- security-advisories@github.com
- Vulnerability Status
- Analyzed
- Published Version
- 2022-02-18T15:15:07
- Last Modified Date
- 2022-02-28T19:19:48
Weakness Enumerations
CPE Configuration (Product)
CPE | Vulnerable | Operator | Version Start | Version End |
---|---|---|---|---|
cpe:2.3:a:prismjs:prism:*:*:*:*:*:node.js:*:* | 1 | OR | 1.14.0 | 1.27.0 |
CVSS Version 2
- Version
- 2.0
- Vector String
- AV:N/AC:M/Au:N/C:N/I:P/A:N
- Access Vector
- NETWORK
- Access Compatibility
- MEDIUM
- Authentication
- NONE
- Confidentiality Impact
- NONE
- Integrity Impact
- PARTIAL
- Availability Impact
- NONE
- Base Score
- 4.3
- Severity
- MEDIUM
- Exploitability Score
- 8.6
- Impact Score
- 2.9
CVSS Version 3
- Version
- 3.1
- Vector String
- CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- Attack Vector
- NETWORK
- Attack Compatibility
- LOW
- Privileges Required
- NONE
- User Interaction
- REQUIRED
- Scope
- CHANGED
- Confidentiality Impact
- LOW
- Availability Impact
- NONE
- Base Score
- 6.1
- Base Severity
- MEDIUM
- Exploitability Score
- 2.8
- Impact Score
- 2.7
References
Reference URL | Reference Tags |
---|---|
https://github.com/PrismJS/prism/security/advisories/GHSA-3949-f494-cm99 | Third Party Advisory |
https://github.com/PrismJS/prism/pull/3341 | Patch Third Party Advisory |
https://github.com/PrismJS/prism/commit/e002e78c343154e1c0ddf9d6a0bb85689e1a5c7c | Patch Third Party Advisory |
Sources
Source Name | Source URL |
---|---|
NIST | https://nvd.nist.gov/vuln/detail/CVE-2022-23647 |
MITRE | https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-23647 |
History
Created | Old Value | New Value | Data Type | Notes |
---|---|---|---|---|
2022-05-10 15:48:19 | Added to TrackCVE | |||
2022-12-06 10:06:46 | 2022-02-18T15:15Z | 2022-02-18T15:15:07 | CVE Published Date | updated |
2022-12-06 10:06:46 | 2022-02-28T19:19:48 | CVE Modified Date | updated | |
2022-12-06 10:06:47 | Analyzed | Vulnerability Status | updated |