Skip to content

Commit 7d480bd

Browse files
Alvaro MuñozGeekMasher
authored andcommitted
Update hasQualifiedName to hasFullyQualifiedName
1 parent cf22bd3 commit 7d480bd

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

csharp/lib/ghsl/Cryptography.qll

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ module Cryptography {
3636
class CryptoRfc2898DeriveBytes extends HashingAlgorithms {
3737
CryptoRfc2898DeriveBytes() {
3838
exists(ObjectCreation object |
39-
object.getType().getQualifiedName() = "System.Security.Cryptography.Rfc2898DeriveBytes" and
39+
object.getType().hasFullyQualifiedName("System.Security.Cryptography", "Rfc2898DeriveBytes") and
4040
this.asExpr() = object
4141
)
4242
}
@@ -67,7 +67,7 @@ module Cryptography {
6767
exists(ObjectCreation object |
6868
object
6969
.getType()
70-
.hasQualifiedName("System.Security.Cryptography", "DSACryptoServiceProvider") and
70+
.hasFullyQualifiedName("System.Security.Cryptography", "DSACryptoServiceProvider") and
7171
this.asExpr() = object
7272
)
7373
}
@@ -90,7 +90,7 @@ module Cryptography {
9090
exists(ObjectCreation object |
9191
object
9292
.getType()
93-
.hasQualifiedName("System.Security.Cryptography", "RC2CryptoServiceProvider") and
93+
.hasFullyQualifiedName("System.Security.Cryptography", "RC2CryptoServiceProvider") and
9494
this.asExpr() = object
9595
)
9696
}
@@ -113,12 +113,13 @@ module Cryptography {
113113
exists(ObjectCreation object |
114114
object
115115
.getType()
116-
.hasQualifiedName("System.Security.Cryptography", ["RSACryptoServiceProvider", "RSACng"]) and
116+
.hasFullyQualifiedName("System.Security.Cryptography",
117+
["RSACryptoServiceProvider", "RSACng"]) and
117118
this.asExpr() = object
118119
)
119120
or
120121
exists(MethodCall call |
121-
call.getType().hasQualifiedName("System.Security.Cryptography", ["RSA"]) and
122+
call.getType().hasFullyQualifiedName("System.Security.Cryptography", ["RSA"]) and
122123
call.getTarget().hasName("Create") and
123124
this.asExpr() = call
124125
)
@@ -152,7 +153,7 @@ module Cryptography {
152153
exists(ObjectCreation object |
153154
object
154155
.getType()
155-
.hasQualifiedName("System.Security.Cryptography",
156+
.hasFullyQualifiedName("System.Security.Cryptography",
156157
["HMACMD5", "HMACSHA1", "HMACSHA256", "HMACSHA384", "HMACSHA512", "HMACRIPEMD160"]) and
157158
this.asExpr() = object
158159
)

0 commit comments

Comments
 (0)