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

CQI-104: fixed compiling regex pattern #227

Merged
merged 1 commit into from
Oct 19, 2023
Merged

Conversation

sniedzielski
Copy link
Contributor

@sniedzielski sniedzielski commented Oct 18, 2023

TICKET: https://openimis.atlassian.net/browse/CQI-104

COMMENT: We optimized the regular expression pattern by reducing backtracking. In this optimized pattern, we're using positive lookbehind (?<=[a-z0-9]) to ensure that the position we're looking at is preceded by a lowercase letter or a digit, and then we're using a positive lookahead (?=[A-Z]) to ensure that it's followed by an uppercase letter. This should help reduce backtracking and improve performance, addressing the security concern.

@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot B 3 Security Hotspots
Code Smell A 144 Code Smells

67.3% 67.3% Coverage
1.1% 1.1% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@sniedzielski sniedzielski marked this pull request as ready for review October 18, 2023 10:48
@dborowiecki dborowiecki merged commit 6fe20f0 into develop Oct 19, 2023
6 of 13 checks passed
@dborowiecki dborowiecki deleted the feature/CQI-104 branch October 19, 2023 12:44
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.

2 participants