Merge pull request #16444 from owen-mc/shared/update-summary-through-step-value

Shared data flow: Make summaryThroughStepValue include param outputs
This commit is contained in:
Owen Mansel-Chan
2024-05-08 09:53:30 +01:00
committed by GitHub
2 changed files with 4 additions and 4 deletions

View File

@@ -1286,10 +1286,8 @@ module Make<
* be useful to include in the exposed local data-flow/taint-tracking relations.
*/
predicate summaryThroughStepValue(ArgNode arg, Node out, SummarizedCallable sc) {
exists(ReturnKind rk, SummaryNode ret, DataFlowCall call |
summaryLocalStep(summaryArgParam(call, arg, sc), ret, true, _) and
summaryReturnNode(ret, pragma[only_bind_into](rk)) and
out = getAnOutNode(call, pragma[only_bind_into](rk))
exists(SummaryNode ret |
summaryLocalStep(summaryArgParamRetOut(arg, ret, out, sc), ret, true, _)
)
}

View File

@@ -794,8 +794,10 @@
| test.swift:680:10:680:11 | &... | test.swift:681:15:681:15 | x |
| test.swift:680:11:680:11 | [post] x | test.swift:680:10:680:11 | &... |
| test.swift:680:11:680:11 | x | test.swift:680:10:680:11 | &... |
| test.swift:680:11:680:11 | x | test.swift:680:15:680:15 | [post] y |
| test.swift:680:14:680:15 | &... | test.swift:682:15:682:15 | y |
| test.swift:680:15:680:15 | [post] y | test.swift:680:14:680:15 | &... |
| test.swift:680:15:680:15 | y | test.swift:680:11:680:11 | [post] x |
| test.swift:680:15:680:15 | y | test.swift:680:14:680:15 | &... |
| test.swift:686:9:686:9 | SSA def(arr1) | test.swift:687:15:687:15 | arr1 |
| test.swift:686:9:686:9 | arr1 | test.swift:686:9:686:9 | SSA def(arr1) |