diff --git a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl.qll b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl.qll +++ b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl2.qll b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl2.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl2.qll +++ b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl2.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl3.qll b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl3.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl3.qll +++ b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl3.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl4.qll b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl4.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl4.qll +++ b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImpl4.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImplLocal.qll b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImplLocal.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImplLocal.qll +++ b/cpp/ql/src/semmle/code/cpp/dataflow/internal/DataFlowImplLocal.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl.qll b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl.qll +++ b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl2.qll b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl2.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl2.qll +++ b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl2.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl3.qll b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl3.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl3.qll +++ b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl3.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl4.qll b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl4.qll index 9519a74265f..1f322a02201 100644 --- a/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl4.qll +++ b/cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl4.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl.qll b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl.qll index 9519a74265f..1f322a02201 100644 --- a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl.qll +++ b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl2.qll b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl2.qll index 9519a74265f..1f322a02201 100644 --- a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl2.qll +++ b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl2.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl3.qll b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl3.qll index 9519a74265f..1f322a02201 100644 --- a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl3.qll +++ b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl3.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl4.qll b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl4.qll index 9519a74265f..1f322a02201 100644 --- a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl4.qll +++ b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl4.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl5.qll b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl5.qll index 9519a74265f..1f322a02201 100644 --- a/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl5.qll +++ b/csharp/ql/src/semmle/code/csharp/dataflow/internal/DataFlowImpl5.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl.qll b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl.qll index 9519a74265f..1f322a02201 100644 --- a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl.qll +++ b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl2.qll b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl2.qll index 9519a74265f..1f322a02201 100644 --- a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl2.qll +++ b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl2.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl3.qll b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl3.qll index 9519a74265f..1f322a02201 100644 --- a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl3.qll +++ b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl3.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl4.qll b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl4.qll index 9519a74265f..1f322a02201 100644 --- a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl4.qll +++ b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl4.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) } diff --git a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl5.qll b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl5.qll index 9519a74265f..1f322a02201 100644 --- a/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl5.qll +++ b/java/ql/src/semmle/code/java/dataflow/internal/DataFlowImpl5.qll @@ -510,13 +510,20 @@ private predicate simpleParameterFlow( pragma[noinline] private predicate simpleArgumentFlowsThrough0( + ParameterNode p, ReturnNode ret, ReturnKind kind, DataFlowType t, Configuration config +) { + simpleParameterFlow(p, ret, t, config) and + kind = ret.getKind() +} + +pragma[noinline] +private predicate simpleArgumentFlowsThrough1( DataFlowCall call, ArgumentNode arg, ReturnKind kind, DataFlowType t, Configuration config ) { nodeCand1(arg, unbind(config)) and not outBarrier(arg, config) and exists(ParameterNode p, ReturnNode ret | - simpleParameterFlow(p, ret, t, config) and - kind = ret.getKind() and + simpleArgumentFlowsThrough0(p, ret, kind, t, config) and viableParamArg(call, p, arg) ) } @@ -534,7 +541,7 @@ private predicate simpleArgumentFlowsThrough( exists(DataFlowCall call, ReturnKind kind | nodeCand1(out, unbind(config)) and not inBarrier(out, config) and - simpleArgumentFlowsThrough0(call, arg, kind, t, config) and + simpleArgumentFlowsThrough1(call, arg, kind, t, config) and out = getAnOutNode(call, kind) ) }