Merge pull request #12813 from atorralba/atorralba/java/sensitive-expr-fix-and-tests

Java: Add tests for SensitiveActions and fix getCommonSensitiveInfoRegex
This commit is contained in:
Tony Torralba
2023-04-13 13:13:37 +02:00
committed by GitHub
5 changed files with 233 additions and 1 deletions

View File

@@ -31,7 +31,7 @@ private string nonSuspicious() {
* Gets a regular expression for matching common names of variables that indicate the value being held contains sensitive information.
*/
string getCommonSensitiveInfoRegex() {
result = "(?i).*challenge|pass(wd|word|code|phrase)(?!.*question).*" or
result = "(?i).*(challenge|pass(wd|word|code|phrase))(?!.*question).*" or
result = "(?i).*(token|secret).*"
}