Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shared data flow: Make summaryThroughStepValue include param outputs #16444

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions shared/dataflow/codeql/dataflow/internal/FlowSummaryImpl.qll
Original file line number Diff line number Diff line change
Expand Up @@ -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, _)
)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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) |
Expand Down
Loading