Skip to content

Commit 507174e

Browse files
committed
Crypto: Fix bug in MacOperationNode constructor with detecting if the operation is also used for signatures.
1 parent cbe34f1 commit 507174e

File tree

1 file changed

+2
-2
lines changed
  • shared/quantum/codeql/quantum/experimental

1 file changed

+2
-2
lines changed

shared/quantum/codeql/quantum/experimental/Model.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1597,8 +1597,8 @@ module CryptographyBase<LocationSig Location, InputSig<Location> Input> {
15971597
final class MacOperationNode extends SignatureOrMacOperationNode {
15981598
MacOperationNode() {
15991599
this.getKeyOperationSubtype() = TMacMode() and
1600-
// If the type could be a mac, then we will not consider it a mac operation exclusively.
1601-
not exists(KeyOperationSubtype t | t = this.getKeyOperationSubtype() and t = TMacMode())
1600+
// If the type could be a signature, then we will not consider it a mac operation exclusively.
1601+
not exists(KeyOperationSubtype t | t = this.getKeyOperationSubtype() and t = TSignMode())
16021602
}
16031603

16041604
final override string getInternalType() { result = "MACOperation" }

0 commit comments

Comments
 (0)