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

SafeRegEx check should allow invlid RegExs #8494

Merged
merged 3 commits into from
Nov 15, 2024

Conversation

mandy-chessell
Copy link
Contributor

Description

This PR makes a change to the SafeRegEx test which is looking for valid RegEx's that are designed to cause a denial of service by taking a very long time. The routine is passed any string that might be a regex - and this includes strings that are complex names of techinical metadata elements which include special characters from a RegEx point of view - but are not valid RegEx expressions. These are not a concern, because they are probably being passed as an exact value comparison - and if it turns out they are being passed as a RegEx then the database will fail it immediately. So exceptions from invalid RegEx expressions are now ignored rather than putting out alarming exception messages on the console.

Related Issue(s)

None

Testing

Restarting the server with the fix multiple times.

Release Notes & Documentation

None

Additional notes

None

mandy-chessell and others added 3 commits November 15, 2024 15:28
Signed-off-by: Mandy Chessell <mandy.e.chessell@gmail.com>
Signed-off-by: Mandy Chessell <mandy.e.chessell@gmail.com>
@mandy-chessell mandy-chessell merged commit aea88e9 into odpi:main Nov 15, 2024
4 checks passed
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

Successfully merging this pull request may close these issues.

1 participant