Skip to content

css-what vulnerable to ReDoS due to use of insecure regular expression

High severity GitHub Reviewed Published Oct 1, 2022 to the GitHub Advisory Database • Updated Nov 29, 2023

Package

npm css-what (npm)

Affected versions

< 2.1.3

Patched versions

2.1.3

Description

The package css-what before 2.1.3 is vulnerable to Regular Expression Denial of Service (ReDoS) due to the use of insecure regular expression in the re_attr variable of index.js. The exploitation of this vulnerability could be triggered via the parse function.

References

Published by the National Vulnerability Database Sep 30, 2022
Published to the GitHub Advisory Database Oct 1, 2022
Reviewed Oct 4, 2022
Last updated Nov 29, 2023

Severity

High
7.5
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Weaknesses

CVE ID

CVE-2022-21222

GHSA ID

GHSA-p28h-cc7q-c4fg

Source code

Checking history
See something to contribute? Suggest improvements for this vulnerability.