File tree Expand file tree Collapse file tree 1 file changed +1
-11
lines changed
java/ql/lib/semmle/code/java/security Expand file tree Collapse file tree 1 file changed +1
-11
lines changed Original file line number Diff line number Diff line change @@ -235,22 +235,12 @@ string getAnInsecureHashAlgorithmName() {
235
235
result = "MD5"
236
236
}
237
237
238
- private string rankedInsecureAlgorithm ( int i ) {
239
- result = rank [ i ] ( string name | insecureAlgorithm ( name , _) )
240
- }
241
-
242
- private string insecureAlgorithmString ( int i ) {
243
- i = 1 and result = rankedInsecureAlgorithm ( i )
244
- or
245
- result = rankedInsecureAlgorithm ( i ) + "|" + insecureAlgorithmString ( i - 1 )
246
- }
247
-
248
238
/**
249
239
* Gets the regular expression used for matching strings that look like they
250
240
* contain an algorithm that is known to be insecure.
251
241
*/
252
242
string getInsecureAlgorithmRegex ( ) {
253
- result = algorithmRegex ( insecureAlgorithmString ( max ( int i | exists ( rankedInsecureAlgorithm ( i ) ) ) ) )
243
+ result = algorithmRegex ( concat ( string name | insecureAlgorithm ( name , _ ) | name , "|" ) )
254
244
}
255
245
256
246
/** Gets the reason why `input` is an insecure algorithm, if any. */
You can’t perform that action at this time.
0 commit comments