JS: Port LoopBoundInjection

This commit is contained in:
Asger F
2023-10-04 21:45:08 +02:00
parent 40d68cb4dc
commit ae680e747b
4 changed files with 98 additions and 78 deletions

View File

@@ -14,10 +14,10 @@
import javascript
import semmle.javascript.security.dataflow.LoopBoundInjectionQuery
import DataFlow::PathGraph
import LoopBoundInjectionFlow::PathGraph
from Configuration dataflow, DataFlow::PathNode source, DataFlow::PathNode sink
where dataflow.hasFlowPath(source, sink)
from LoopBoundInjectionFlow::PathNode source, LoopBoundInjectionFlow::PathNode sink
where LoopBoundInjectionFlow::flowPath(source, sink)
select sink, source, sink,
"Iteration over a user-controlled object with a potentially unbounded .length property from a $@.",
source, "user-provided value"