-
Notifications
You must be signed in to change notification settings - Fork 13
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
Potential Polynomial regex used (says CodeQL) #18
Comments
Ruby 3.2.something:
Seems plenty fast to me... |
Oh CodeQL did say the problem was much improved with Ruby 3.2, let me try 3.1...
Still seems fine. |
I also don't believe this input is ever "user controlled". However, I'd be fine for a PR to fix this if it doesn't significantly increase complexity. |
@tenderlove you are an expert on these issues - is there anything we need to do here? |
Since it's not user controlled, I'm not worried about it. If someone sends a PR to clean up the regex though I'm also happy to merge it |
I agree, if anyone wants to make a PR, it would be welcome. Otherwise, I'll close this issue for now. |
Due to #13 (and other version dependency issues) we've been forced to vendor a "fake" version 1.0 that fixes that issue within our project, but CodeQL isn't very happy about the regex being used.
This is exactly the same code present in this repo in: https://github.com/rack/rackup/blob/main/lib/rackup/handler.rb#L107-L108
I don't see the issue since
[A-Z]+
and[^A-Z]
have no overlap... does anyone else see it or is this a false positive?The text was updated successfully, but these errors were encountered: