Skip to content

Commit 216393f

Browse files
committed
Java/NumericCastTaintedQuery
java/ql/src/Security/CWE/CWE-681/NumericCastTainted.ql
1 parent 3d59f5b commit 216393f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,9 @@ module NumericCastFlowConfig implements DataFlow::ConfigSig {
106106
predicate observeDiffInformedIncrementalMode() { any() }
107107

108108
Location getASelectedSinkLocation(DataFlow::Node sink) {
109-
exists(NumericNarrowingCastExpr cast |
110-
cast.getExpr() = sink.asExpr() and
109+
exists(NumericNarrowingCastExpr cast | cast.getExpr() = sink.asExpr() |
110+
result = sink.getLocation()
111+
or
111112
result = cast.getLocation()
112113
)
113114
}

0 commit comments

Comments
 (0)