NodeJS/color-string/1.5.3
Parser and generator for CSS color strings
https://www.npmjs.com/package/color-string
MIT
1 Security Vulnerabilities
Regular Expression Denial of Service (ReDOS)
- https://nvd.nist.gov/vuln/detail/CVE-2021-29060
- https://github.com/advisories/GHSA-257v-vj4p-3w2h
- https://github.com/Qix-/color-string/commit/0789e21284c33d89ebc4ab4ca6f759b9375ac9d3
- https://github.com/Qix-/color-string/releases/tag/1.5.5
- https://github.com/yetingli/PoCs/blob/main/CVE-2021-29060/Color-String.md
- https://github.com/yetingli/SaveResults/blob/main/js/color-string.js
- https://www.npmjs.com/package/color-string
In the npm package color-string
, there is a ReDos (Regular Expression Denial of Service) vulnerability regarding an exponential time complexity for
linearly increasing input lengths for hwb()
color strings.
Strings reaching more than 5000 characters would see several milliseconds of processing time; strings reaching more than 50,000 characters began seeing 1500ms (1.5s) of processing time.
The cause was due to a the regular expression that parses hwb() strings - specifically, the hue value - where the integer portion of the hue value used a 0-or-more quantifier shortly thereafter followed by a 1-or-more quantifier.
This caused excessive backtracking and a cartesian scan, resulting in exponential time complexity given a linear increase in input length.
36 Other Versions
Version | License | Security | Released | |
---|---|---|---|---|
1.9.1 | MIT | 2022-04-22 - 18:08 | about 2 years | |
1.9.0 | MIT | 2021-12-03 - 15:50 | over 2 years | |
1.8.2 | MIT | 2021-11-30 - 19:13 | over 2 years | |
1.8.1 | MIT | 2021-11-30 - 09:23 | over 2 years | |
1.8.0 | MIT | 2021-11-30 - 09:19 | over 2 years | |
1.7.4 | MIT | 2021-11-26 - 08:00 | over 2 years | |
1.7.3 | MIT | 2021-11-26 - 07:52 | over 2 years | |
1.7.2 | MIT | 2021-11-26 - 07:48 | over 2 years | |
1.7.1 | MIT | 2021-11-26 - 07:37 | over 2 years | |
1.7.0 | MIT | 2021-11-26 - 07:30 | over 2 years | |
1.6.0 | MIT | 2021-07-17 - 06:30 | almost 3 years | |
1.5.5 | MIT | 2021-03-05 - 17:58 | about 3 years | |
1.5.4 | MIT | 1 | 2020-10-09 - 07:20 | over 3 years |
1.5.3 | MIT | 1 | 2018-08-01 - 22:46 | over 5 years |
1.5.2 | MIT | 1 | 2017-03-09 - 20:09 | about 7 years |
1.5.1 | MIT | 1 | 2017-03-09 - 19:14 | about 7 years |
1.5.0 | MIT | 1 | 2017-02-22 - 19:45 | about 7 years |
1.4.0 | MIT | 1 | 2016-12-06 - 17:41 | over 7 years |
1.3.1 | MIT | 1 | 2016-11-16 - 02:33 | over 7 years |
1.3.0 | MIT | 1 | 2016-11-11 - 19:35 | over 7 years |
1.2.0 | MIT | 1 | 2016-03-29 - 02:34 | about 8 years |
1.1.1 | MIT | 1 | 2016-03-29 - 00:06 | about 8 years |
1.1.0 | MIT | 1 | 2016-03-28 - 23:53 | about 8 years |
1.0.1 | MIT | 1 | 2016-01-23 - 18:04 | over 8 years |
1.0.0 | MIT | 1 | 2016-01-23 - 17:13 | over 8 years |
0.4.0 | MIT | 1 | 2016-01-03 - 17:26 | over 8 years |
0.3.0 | MIT | 1 | 2015-02-19 - 07:26 | about 9 years |
0.2.4 | MIT | 1 | 2014-12-15 - 20:53 | over 9 years |
0.2.3 | MIT | 1 | 2014-12-15 - 19:46 | over 9 years |
0.2.2 | MIT | 1 | 2014-12-12 - 08:16 | over 9 years |
0.2.1 | MIT | 1 | 2014-07-23 - 07:31 | almost 10 years |
0.2.0 | MIT | 1 | 2014-07-15 - 15:17 | almost 10 years |
0.1.3 | MIT | 1 | 2014-03-07 - 00:41 | about 10 years |
0.1.2 | MIT | 1 | 2013-02-11 - 19:28 | about 11 years |
0.1.1 | MIT | 1 | 2011-06-23 - 03:04 | almost 13 years |
0.1.0 | MIT | 1 | 2011-06-19 - 19:01 | almost 13 years |