Skip to content

Commit be2c824

Browse files
committed
Java/ImproperValidationOfArrayConstructionCodeSpecifiedQuery
java/ql/src/Security/CWE/CWE-129/ImproperValidationOfArrayConstructionCodeSpecified.ql
1 parent 1623ce2 commit be2c824

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ module BoundedFlowSourceConfig implements DataFlow::ConfigSig {
2121
predicate observeDiffInformedIncrementalMode() { any() }
2222

2323
Location getASelectedSinkLocation(DataFlow::Node sink) {
24+
result = sink.getLocation()
25+
or
2426
exists(ArrayCreationExpr arrayCreation, CheckableArrayAccess arrayAccess |
2527
result = [arrayCreation, arrayAccess.getIndexExpr()].getLocation() and
2628
arrayAccess.canThrowOutOfBoundsDueToEmptyArray(sink.asExpr(), arrayCreation)

0 commit comments

Comments
 (0)