mirror of
https://github.com/github/codeql.git
synced 2026-02-24 10:53:49 +01:00
Merge pull request #16028 from owen-mc/java/sensitive-log-whitelist-tokenimage
Java: whitelist variable name `tokenImage` for `java/sensitive-log` as it's used in code generated by JavaCC
This commit is contained in:
@@ -12,7 +12,8 @@ class VariableWithSensitiveName extends Variable {
|
||||
VariableWithSensitiveName() {
|
||||
exists(string name | name = this.getName() |
|
||||
name.regexpMatch(getCommonSensitiveInfoRegex()) and
|
||||
not name.regexpMatch("(?i).*null.*")
|
||||
not name.regexpMatch("(?i).*null.*") and
|
||||
name != "tokenImage" // appears in parser code generated by JavaCC
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user