Skip to content

Commit 02a0eef

Browse files
committed
Java/ArithmeticTainted
java/ql/src/Security/CWE/CWE-190/ArithmeticTainted.ql
1 parent fb32d0d commit 02a0eef

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

java/ql/lib/semmle/code/java/security/ArithmeticTaintedQuery.qll

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ module ArithmeticOverflowConfig implements DataFlow::ConfigSig {
1919
}
2020

2121
Location getASelectedSinkLocation(DataFlow::Node sink) {
22+
result = sink.getLocation()
23+
or
2224
exists(ArithExpr exp | result = exp.getLocation() | overflowSink(exp, sink.asExpr()))
2325
}
2426
}
@@ -43,6 +45,8 @@ module ArithmeticUnderflowConfig implements DataFlow::ConfigSig {
4345
}
4446

4547
Location getASelectedSinkLocation(DataFlow::Node sink) {
48+
result = sink.getLocation()
49+
or
4650
exists(ArithExpr exp | result = exp.getLocation() | underflowSink(exp, sink.asExpr()))
4751
}
4852
}

0 commit comments

Comments
 (0)