Hi, I would like to ask whether SonarQube detects SQL injection vulnerabilities in such popular examples as in python3:
cursor.execute("SELECT admin FROM users WHERE username = '" + username + '");
cursor.execute("SELECT admin FROM users WHERE username = '%s' % username);
cursor.execute("SELECT admin FROM users WHERE username = '{}'".format(username));
cursor.execute(f"SELECT admin FROM users WHERE username = '{username}'");
Unfortunately, it does not detect these vulnerabilities for me and I wonder if the error is on my side or maybe this version does not support the detection of this type of attacks.
-
which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension)
sonarqube-10.2.1.78527
Community Edition -
how is SonarQube deployed: zip, Docker, Helm
zip