mirror of
https://github.com/github/codeql.git
synced 2026-05-24 08:07:07 +02:00
Shared: Fix for 'wildcard'.
This commit is contained in:
@@ -368,7 +368,7 @@ fn test_private_info(
|
||||
sink(info.financials.accounting);
|
||||
sink(info.financials.unaccounted);
|
||||
sink(info.financials.multiband);
|
||||
sink(info.financials.wildcard_not_matched); // $ SPURIOUS: sensitive=private
|
||||
sink(info.financials.wildcard_not_matched);
|
||||
|
||||
sink(ContactDetails::FavouriteColor("blue".to_string()));
|
||||
}
|
||||
|
||||
@@ -145,13 +145,13 @@ module HeuristicNames {
|
||||
* suggesting nouns within the string do not represent the meaning of the whole string (e.g. a URL or a SQL query).
|
||||
*
|
||||
* We also filter out common words like `certain` and `concert`, since otherwise these could
|
||||
* be matched by the certificate regular expressions. Same for `accountable` (account), or
|
||||
* `secretarial` (secret).
|
||||
* be matched by the certificate regular expressions. Same for `accountable` (account),
|
||||
* `secretarial` (secret), `wildcard` (card).
|
||||
*/
|
||||
string notSensitiveRegexp() {
|
||||
result =
|
||||
"(?is).*([^\\w$.-]|redact|censor|obfuscate|hash|md5|sha|random|((?<!un)(en))?(crypt|(?<!pass)code)|"
|
||||
+ "certain|concert|secretar|account(ant|ab|ing|ed)|file|path|([_-]|\\b)url).*"
|
||||
+ "certain|concert|secretar|wildcard|account(ant|ab|ing|ed)|file|path|([_-]|\\b)url).*"
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user