-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vulnerable Regular Expression #10
Comments
Yes, thanks for your report! We will fix this high security problem as soon as possible! |
Can you send me the example to my email fengmk2#gmail.com? |
fengmk2
added a commit
that referenced
this issue
Sep 7, 2017
only allow max 10 spaces and 100 charset string closes #10
Merged
fengmk2
added a commit
that referenced
this issue
Sep 7, 2017
only allow max 10 spaces and 100 charset string closes #10
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The following regular expression used for parsing the HTTP header is vulnerable to ReDoS:
/(?:charset|encoding)\s*=\s*['"]? *([\w\-]+)/i
The slowdown is moderate: for 30.000 characters around 4 seconds matching time. I would suggest one of the following:
If needed, I can provide an actual example showing the slowdown.
The text was updated successfully, but these errors were encountered: