-
Notifications
You must be signed in to change notification settings - Fork 954
Closed
koajs/static-cache
#73Description
The following regular expression used in the "o" formatter is vulnerable to ReDoS:
/\s*\n\s*/
The slowdown is moderately low: for 50.000 characters around 2 seconds matching time. However, I would still suggest one of the following:
- remove the regex,
- anchor the regex,
- limit the number of characters that can be matched by the repetition,
- limit the input size.
If needed, I can provide an actual example showing the slowdown.
b4dnewz, Ma3lishh, dmitmel, DrKain, hendrikpawlowski and 1 more
Metadata
Metadata
Assignees
Labels
No labels