Skip to content
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

Known regex vuln #215

Closed
kieransquare opened this issue Oct 13, 2022 · 5 comments
Closed

Known regex vuln #215

kieransquare opened this issue Oct 13, 2022 · 5 comments

Comments

@kieransquare
Copy link

Just thought I'd inform this project that it has a known regex vuln out against it now.

https://nvd.nist.gov/vuln/detail/CVE-2022-37599

@alexander-akait
Copy link
Member

PR welcome

@alexander-akait
Copy link
Member

And I don't see any problems with

directory = resourcePath.replace(/\\/g, '/').replace(/\.\.(\/)?/g, '_$1');

And #211

@getroyer
Copy link

I'm interested in finding a way to resolve this regex vulnerability as well. If anyone knows how it should be resolved please let me know.

@jeran-urban
Copy link

I'm interested in finding a way to resolve this regex vulnerability as well. If anyone knows how it should be resolved please let me know.

The main issues around Regex DOS attacks is in badly formed queries that are not strict enough, and no exit condition involving a time limit for processing. If you ensure that the query is perfectly formed or at least add an exit condition based on a time limit (a few seconds) then this should resolve the issue. More information here: https://www.regular-expressions.info/redos.html#Handling%20Regexes%20Provided%20by%20The%20User. I will drop this information on the other threads as I believe this is still a legitimate vulnerability in v 3.x as well

@alexander-akait
Copy link
Member

Close in favor #216

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants