Python: Move CommandInjection to new dataflow API

This commit is contained in:
Rasmus Wriedt Larsen
2023-08-25 15:44:02 +02:00
parent 700841e9b0
commit b30142c1d7
2 changed files with 17 additions and 4 deletions

View File

@@ -16,9 +16,9 @@
import python
import semmle.python.security.dataflow.CommandInjectionQuery
import DataFlow::PathGraph
import CommandInjectionFlow::PathGraph
from Configuration config, DataFlow::PathNode source, DataFlow::PathNode sink
where config.hasFlowPath(source, sink)
from CommandInjectionFlow::PathNode source, CommandInjectionFlow::PathNode sink
where CommandInjectionFlow::flowPath(source, sink)
select sink.getNode(), source, sink, "This command line depends on a $@.", source.getNode(),
"user-provided value"