File tree Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ module NormalHashFunction {
43
43
* data" vulnerabilities that applies to data that does not require computationally expensive
44
44
* hashing. That is, a broken or weak hashing algorithm.
45
45
*/
46
- abstract class Sink extends DataFlow :: Node {
46
+ abstract class Sink extends QuerySink :: Range {
47
47
/**
48
48
* Gets the name of the weak hashing algorithm.
49
49
*/
@@ -76,6 +76,8 @@ module NormalHashFunction {
76
76
class WeakHashingOperationInputAsSink extends Sink {
77
77
Cryptography:: HashingAlgorithm algorithm ;
78
78
79
+ override string getSinkType ( ) { result = "WeakSensitiveDataHashing" }
80
+
79
81
WeakHashingOperationInputAsSink ( ) {
80
82
exists ( Cryptography:: CryptographicOperation operation |
81
83
algorithm .isWeak ( ) and
@@ -114,7 +116,9 @@ module ComputationallyExpensiveHashFunction {
114
116
* hashing. That is, a broken or weak hashing algorithm or one that is not computationally
115
117
* expensive enough for password hashing.
116
118
*/
117
- abstract class Sink extends DataFlow:: Node {
119
+ abstract class Sink extends QuerySink:: Range {
120
+ override string getSinkType ( ) { result = "WeakSensitiveDataHashing" }
121
+
118
122
/**
119
123
* Gets the name of the weak hashing algorithm.
120
124
*/
Original file line number Diff line number Diff line change @@ -11,8 +11,9 @@ private import codeql.rust.controlflow.internal.CfgConsistency as CfgConsistency
11
11
private import codeql.rust.dataflow.internal.DataFlowConsistency as DataFlowConsistency
12
12
private import codeql.rust.Concepts
13
13
// import all query extensions files, so that all extensions of `QuerySink` are found
14
- private import codeql.rust.security.SqlInjectionExtensions
15
14
private import codeql.rust.security.CleartextLoggingExtensions
15
+ private import codeql.rust.security.SqlInjectionExtensions
16
+ private import codeql.rust.security.WeakSensitiveDataHashingExtensions
16
17
17
18
/**
18
19
* Gets a count of the total number of lines of code in the database.
You can’t perform that action at this time.
0 commit comments