mirror of
https://github.com/github/codeql.git
synced 2025-12-21 11:16:30 +01:00
Update javascript/ql/src/Security/CWE-400/PrototypePollutionUtility.ql
Co-Authored-By: Esben Sparre Andreasen <esbena@github.com>
This commit is contained in:
@@ -173,7 +173,7 @@ predicate dynamicPropReadStep(Node base, Node key, SourceNode output) {
|
||||
output = read
|
||||
)
|
||||
or
|
||||
// Summarize functions returning a dynamic property read of two parameters.
|
||||
// Summarize functions returning a dynamic property read of two parameters, such as `function getProp(obj, prop) { return obj[prop]; }`.
|
||||
exists(CallNode call, Function callee, ParameterNode baseParam, ParameterNode keyParam, Node innerBase, Node innerKey, SourceNode innerOutput |
|
||||
dynamicPropReadStep(innerBase, innerKey, innerOutput) and
|
||||
baseParam.flowsTo(innerBase) and
|
||||
|
||||
Reference in New Issue
Block a user