Skip to content

Commit 538bf7c

Browse files
haby0yoff
andauthored
Update python/ql/src/experimental/Security/CWE-348/ClientSuppliedIpUsedInSecurityCheck.ql
Co-authored-by: yoff <[email protected]>
1 parent a17b0d4 commit 538bf7c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

python/ql/src/experimental/Security/CWE-348/ClientSuppliedIpUsedInSecurityCheck.ql

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,9 @@ class ClientSuppliedIpUsedInSecurityCheckConfig extends TaintTracking::Configura
3838
}
3939

4040
override predicate isSanitizer(DataFlow::Node node) {
41+
// `client_supplied_ip.split(",")[n]` for `n` > 0
4142
exists(Subscript ss |
43+
not ss.getIndex().(IntegerLiteral).getText() = "0" and
4244
ss.getObject().(Call).getFunc().(Attribute).getName() = "split" and
4345
ss.getObject().(Call).getAnArg().(StrConst).getText() = "," and
4446
ss = node.asExpr()

0 commit comments

Comments
 (0)