Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0c124d2 commit 66dcd7dCopy full SHA for 66dcd7d
1 file changed
javascript/ql/src/semmle/javascript/dataflow/TaintTracking.qll
@@ -207,6 +207,13 @@ module TaintTracking {
207
this = DataFlow::parameterNode(p) and
208
pred.asExpr() = m.getReceiver()
209
)
210
+ or
211
+ // `array.map` with tainted return value in callback
212
+ exists (MethodCallExpr m, Function f |
213
+ this.asExpr() = m and
214
+ m.getMethodName() = "map" and
215
+ m.getArgument(0) = f and // Require the argument to be a closure to avoid spurious call/return flow
216
+ pred = f.getAReturnedExpr().flow())
217
218
or
219
// reading from a tainted object yields a tainted result
0 commit comments