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

[BUG][Ruby] CodeQL: Polynomial regular expression #18698

Closed
4 of 6 tasks
RiccardoPetteruti-Onfido opened this issue May 17, 2024 · 0 comments
Closed
4 of 6 tasks

[BUG][Ruby] CodeQL: Polynomial regular expression #18698

RiccardoPetteruti-Onfido opened this issue May 17, 2024 · 0 comments

Comments

@RiccardoPetteruti-Onfido
Copy link
Contributor

RiccardoPetteruti-Onfido commented May 17, 2024

Bug Report Checklist

Description

Running CodeQL raises 2 alerts like:
Polynomial regular expression used on uncontrolled data

https://codeql.github.com/codeql-query-help/ruby/rb-polynomial-redos/

image

openapi-generator version

7.5.0

OpenAPI declaration file content or url

N/A

Generation Details
inputSpec: openapi.yaml
generatorName: ruby
library: "faraday"
templateDir: generators/ruby/faraday/templates
outputDir: generated/artifacts/ruby/faraday
disallowAdditionalPropertiesIfNotPresent: false
enumUnknownDefaultCase: true
gemName: onfido
gemHomepage: https://github.com/onfido/onfido-ruby
gemLicense: MIT
gemSummary: The official Ruby library for integrating with the Onfido API.
gemDescription: Ruby Library for the Onfido API
httpUserAgent: onfido-ruby/2.9.0
Steps to reproduce

Run CodeQL in Github on generated ruby code with faraday library.

Related issues/PRs

N/A

Suggest a fix

Update the two regex:

PR link

@RiccardoPetteruti-Onfido RiccardoPetteruti-Onfido changed the title [BUG][Ruby] CodeQL: Polynomial regural expression [BUG][Ruby] CodeQL: Polynomial regular expression May 17, 2024
@wing328 wing328 closed this as completed May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants