I’m using SonarQube at work to check for vulnerabilities, and sonar pointed out that my regex is vulnerable to DoS. This is the regex: /^(s+S+s*)(?!s).$/
I went to ReDoS checker and indeed it is vulnerable, but the attack string that they proposed it’d damage the app has 38000 characters. On the input in the app, besides this regex there is also a validator for max length ( 100 ), and I couldn’t ruin the app with that 38000 character long string ( maybe I don’t know how ).
The question is, should I really concern with this, or the validator for length is enough to stop this attack?
P.S. It is about a web app, and the validator I’m talking about is both on backend and front end ( the regex is only on front end )