File tree Expand file tree Collapse file tree 1 file changed +15
-10
lines changed
powershell/ql/lib/semmle/code/powershell/dataflow/internal Expand file tree Collapse file tree 1 file changed +15
-10
lines changed Original file line number Diff line number Diff line change @@ -33,17 +33,22 @@ private module Cached {
33
33
*/
34
34
cached
35
35
predicate defaultAdditionalTaintStep ( DataFlow:: Node nodeFrom , DataFlow:: Node nodeTo , string model ) {
36
- // Although flow through collections is modeled precisely using stores/reads, we still
37
- // allow flow out of a _tainted_ collection. This is needed in order to support taint-
38
- // tracking configurations where the source is a collection.
39
- exists ( DataFlow :: ContentSet c | readStep ( nodeFrom , c , nodeTo ) |
40
- c . isSingleton ( any ( DataFlow :: Content :: ElementContent ec ) )
36
+ (
37
+ exists ( CfgNodes :: ExprNodes :: OperationCfgNode op |
38
+ op = nodeTo . asExpr ( ) and
39
+ op . getAnOperand ( ) = nodeFrom . asExpr ( )
40
+ )
41
41
or
42
- c .isKnownOrUnknownElement ( _)
43
- // or
44
- // TODO: We do't generate this one from readSteps yet, but we will as
45
- // soon as we start on models-as-data.
46
- // c.isAnyElement()
42
+ // Although flow through collections is modeled precisely using stores/reads, we still
43
+ // allow flow out of a _tainted_ collection. This is needed in order to support taint-
44
+ // tracking configurations where the source is a collection.
45
+ exists ( DataFlow:: ContentSet c | readStep ( nodeFrom , c , nodeTo ) |
46
+ c .isSingleton ( any ( DataFlow:: Content:: ElementContent ec ) )
47
+ or
48
+ c .isKnownOrUnknownElement ( _)
49
+ or
50
+ c .isAnyElement ( )
51
+ )
47
52
) and
48
53
model = ""
49
54
}
You can’t perform that action at this time.
0 commit comments