diff --git a/powershell/ql/lib/semmle/code/powershell/ApiGraphs.qll b/powershell/ql/lib/semmle/code/powershell/ApiGraphs.qll index f233fb840cf8..c7a4aa152a75 100644 --- a/powershell/ql/lib/semmle/code/powershell/ApiGraphs.qll +++ b/powershell/ql/lib/semmle/code/powershell/ApiGraphs.qll @@ -511,7 +511,7 @@ module API { predicate toplevelCall(string name, Node node) { exists(DataFlow::CallNode call | call.asExpr().getExpr().getEnclosingScope() instanceof TopLevelScriptBlock and - call.getName() = name and + call.getLowerCaseName() = name and node = MkMethodAccessNode(call) ) } @@ -522,7 +522,7 @@ module API { // from receiver to method call node pred = getForwardEndNode(getALocalSourceStrict(call.getQualifier())) and succ = MkMethodAccessNode(call) and - name = call.getName() + name = call.getLowerCaseName() ) } @@ -549,7 +549,7 @@ module API { _) | result = MkMethodAccessNode(call) and - name = call.getName().toLowerCase() + name = call.getLowerCaseName() ) } @@ -586,7 +586,7 @@ module API { cached predicate methodEdge(Node pred, string name, Node succ) { exists(DataFlow::CallNode call | - succ = MkMethodAccessNode(call) and name = call.getName().toLowerCase() + succ = MkMethodAccessNode(call) and name = call.getLowerCaseName() | pred = getForwardEndNode(getALocalSourceStrict(call.getQualifier())) ) diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/CallExpr.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/CallExpr.qll index c8dd8dbc9ad5..d56741fdd6c6 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/CallExpr.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/CallExpr.qll @@ -5,7 +5,17 @@ class CallExpr extends Expr, TCallExpr { Expr getArgument(int i) { none() } /** Gets the name that is used to select the callee. */ - string getName() { none() } + string getLowerCaseName() { none() } + + /** Holds if `name` is the name of this call. The name is case insensitive. */ + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } + + /** Gets a name that case-insensitively matches the name of this call. */ + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } /** Gets the i'th positional argument to this call. */ Expr getPositionalArgument(int i) { none() } @@ -32,7 +42,7 @@ class CallExpr extends Expr, TCallExpr { exists(Pipeline p, int i | this = p.getComponent(i + 1) and result = p.getComponent(i)) } - final override string toString() { result = "Call to " + this.getName() } + final override string toString() { result = "Call to " + this.getLowerCaseName() } predicate isStatic() { none() } } @@ -44,7 +54,15 @@ class Argument extends Expr { int getPosition() { this = call.getPositionalArgument(result) } - string getName() { this = call.getNamedArgument(result) } + string getLowerCaseName() { this = call.getNamedArgument(result) } + + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } + + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } CallExpr getCall() { result = call } } diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/ChildIndex.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/ChildIndex.qll index 772aab474ae3..9ec865440d11 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/ChildIndex.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/ChildIndex.qll @@ -37,7 +37,7 @@ newtype ChildIndex = RealVar(string name) { name = variableNameInScope(_, _) } or ProcessBlockPipelineVarReadAccess() or ProcessBlockPipelineByPropertyNameVarReadAccess(string name) { - name = any(Raw::PipelineByPropertyNameParameter p).getName() + name = any(Raw::PipelineByPropertyNameParameter p).getLowerCaseName() } int synthPipelineParameterChildIndex(Raw::ScriptBlock sb) { diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Command.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Command.qll index fb8b93ff9c15..8983c373d9bf 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Command.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Command.qll @@ -1,7 +1,7 @@ private import AstImport class CmdCall extends CallExpr, TCmd { - final override string getName() { result = getRawAst(this).(Raw::Cmd).getCommandName() } + final override string getLowerCaseName() { result = getRawAst(this).(Raw::Cmd).getLowerCaseName() } final override Expr getArgument(int i) { synthChild(getRawAst(this), cmdArgument(i), result) } @@ -85,7 +85,7 @@ class DotSourcingOperator extends CmdCall { } class JoinPath extends CmdCall { - JoinPath() { this.getName().toLowerCase() = "join-path" } + JoinPath() { this.getLowerCaseName() = "join-path" } Expr getPath() { result = this.getNamedArgument("path") @@ -103,7 +103,7 @@ class JoinPath extends CmdCall { } class SplitPath extends CmdCall { - SplitPath() { this.getName().toLowerCase() = "split-path" } + SplitPath() { this.getLowerCaseName() = "split-path" } Expr getPath() { result = this.getNamedArgument("path") @@ -131,7 +131,7 @@ class SplitPath extends CmdCall { } class GetVariable extends CmdCall { - GetVariable() { this.getName().toLowerCase() = "get-variable" } + GetVariable() { this.getLowerCaseName() = "get-variable" } Expr getVariable() { result = this.getPositionalArgument(0) } diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/InvokeMemberExpression.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/InvokeMemberExpression.qll index 0fdde64208f0..4772233c9f5a 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/InvokeMemberExpression.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/InvokeMemberExpression.qll @@ -1,7 +1,9 @@ private import AstImport class InvokeMemberExpr extends CallExpr, TInvokeMemberExpr { - final override string getName() { result = getRawAst(this).(Raw::InvokeMemberExpr).getName() } + final override string getLowerCaseName() { + result = getRawAst(this).(Raw::InvokeMemberExpr).getLowerCaseName() + } final override Ast getChild(ChildIndex i) { result = super.getChild(i) @@ -66,7 +68,7 @@ class ConstructorCall extends InvokeMemberExpr { TypeNameExpr typename; ConstructorCall() { - this.isStatic() and typename = this.getQualifier() and this.getName() = "new" + this.isStatic() and typename = this.getQualifier() and this.getLowerCaseName() = "new" } /** Gets the name of the type being constructed by this constructor call. */ @@ -81,5 +83,5 @@ class ConstructorCall extends InvokeMemberExpr { * ``` */ class ToStringCall extends InvokeMemberExpr { - ToStringCall() { this.getName().toLowerCase() = "toString" } + ToStringCall() { this.getLowerCaseName() = "tostring" } } diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/NamedBlock.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/NamedBlock.qll index 5e721df9de14..6f162c6e1a87 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/NamedBlock.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/NamedBlock.qll @@ -60,7 +60,7 @@ class ProcessBlock extends NamedBlock { PipelineByPropertyNameParameter getPipelineByPropertyNameParameter(string name) { result = scriptBlock.getAParameter() and - result.getPropertyName() = name + result.getLowerCaseName() = name } PipelineByPropertyNameParameter getAPipelineByPropertyNameParameter() { diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/ObjectCreation.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/ObjectCreation.qll index 5cb392762599..a2b65a8b0c4f 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/ObjectCreation.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/ObjectCreation.qll @@ -28,7 +28,7 @@ class NewObjectCreation extends AbstractObjectCreation, ConstructorCall { * ``` */ class DotNetObjectCreation extends AbstractObjectCreation, CmdCall { - DotNetObjectCreation() { this.getName() = "New-Object" } + DotNetObjectCreation() { this.getLowerCaseName() = "new-object" } final override string getConstructedTypeName() { result = this.getConstructedTypeExpr().(StringConstExpr).getValueString() diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Parameter.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Parameter.qll index 6a3bc757ead7..a6f45e335189 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Parameter.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Parameter.qll @@ -1,9 +1,15 @@ private import AstImport class Parameter extends Variable instanceof ParameterImpl { - string getName() { result = super.getNameImpl() } + string getLowerCaseName() { result = super.getLowerCaseNameImpl() } - final predicate hasName(string name) { name = this.getName() } + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } + + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } override Ast getChild(ChildIndex childIndex) { result = Variable.super.getChild(childIndex) @@ -41,7 +47,7 @@ class PipelineParameter extends Parameter instanceof PipelineParameterImpl { /** * The iterator variable associated with a pipeline parameter. - * + * * This is the variable that is bound to the current element in the pipeline. */ class PipelineIteratorVariable extends Variable instanceof PipelineIteratorVariableImpl { @@ -55,8 +61,6 @@ class PipelineByPropertyNameParameter extends Parameter instanceof PipelineByPro { ScriptBlock getScriptBlock() { result = super.getScriptBlock() } - string getPropertyName() { result = super.getName() } - /** * Gets the iterator variable that is used to iterate over the elements in the pipeline. */ @@ -65,7 +69,7 @@ class PipelineByPropertyNameParameter extends Parameter instanceof PipelineByPro /** * The iterator variable associated with a pipeline-by-property-name parameter. - * + * * This is the variable that is bound to the current element in the pipeline. */ class PipelineByPropertyNameIteratorVariable extends Variable instanceof PipelineByPropertyNameIteratorVariableImpl @@ -79,4 +83,4 @@ class PipelineByPropertyNameIteratorVariable extends Variable instanceof Pipelin * iterates over. */ PipelineByPropertyNameParameter getParameter() { result = super.getParameter() } -} \ No newline at end of file +} diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Command.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Command.qll index da889b1f573b..323a85d19e3d 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Command.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Command.qll @@ -2,13 +2,13 @@ private import Raw private predicate parseCommandName(Cmd cmd, string namespace, string name) { exists(string qualified | command(cmd, qualified, _, _, _) | - namespace = qualified.regexpCapture("([^\\\\]+)\\\\([^\\\\]+)", 1) and - name = qualified.regexpCapture("([^\\\\]+)\\\\([^\\\\]+)", 2) + namespace = qualified.regexpCapture("([^\\\\]+)\\\\([^\\\\]+)", 1).toLowerCase() and + name = qualified.regexpCapture("([^\\\\]+)\\\\([^\\\\]+)", 2).toLowerCase() or // Not a qualified name not exists(qualified.indexOf("\\")) and namespace = "" and - name = qualified + name = qualified.toLowerCase() ) } @@ -30,7 +30,15 @@ class Cmd extends @command, CmdBase { CmdElement getCallee() { result = this.getElement(0) } /** Gets the name of the command without any qualifiers. */ - string getCommandName() { parseCommandName(this, _, result) } + string getLowerCaseName() { parseCommandName(this, _, result) } + + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } + + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } /** Holds if the command is qualified. */ predicate isQualified() { parseCommandName(this, any(string s | s != ""), _) } @@ -70,7 +78,7 @@ class Cmd extends @command, CmdBase { // sourcing operator) the 0'th element is not the command name, but // rather the thing to invoke. These all appear to be commands with // an empty string as the command name. - this.getCommandName() = "" + this.matchesName("") ) and e = this.getElement(j) and ( diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/InvokeMemberExpression.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/InvokeMemberExpression.qll index a2fa623f3957..d57fe19f1fce 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/InvokeMemberExpression.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/InvokeMemberExpression.qll @@ -5,11 +5,9 @@ class InvokeMemberExpr extends @invoke_member_expression, MemberExprBase { Expr getQualifier() { invoke_member_expression(this, result, _) } - string getName() { result = this.getCallee().(StringConstExpr).getValue().getValue() } - Expr getCallee() { invoke_member_expression(this, _, result) } - string getMemberName() { result = this.getCallee().(StringConstExpr).getValue().getValue() } + string getLowerCaseName() { result = this.getCallee().(StringConstExpr).getValue().getValue().toLowerCase() } Expr getArgument(int i) { invoke_member_expression_argument(this, i, result) } diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Parameter.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Parameter.qll index 08ee3f9e2091..9316bdba9252 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Parameter.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Parameter.qll @@ -1,10 +1,11 @@ private import Raw class Parameter extends @parameter, Ast { - string getName() { - exists(@variable_expression va | + string getLowerCaseName() { + exists(@variable_expression va, string userPath | parameter(this, va, _, _) and - variable_expression(va, result, _, _, _, _, _, _, _, _, _, _) + variable_expression(va, userPath, _, _, _, _, _, _, _, _, _, _) and + result = userPath.toLowerCase() ) } diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Scope.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Scope.qll index 6c8488e1a1a8..98d683d096d9 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Scope.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Raw/Scope.qll @@ -9,16 +9,6 @@ Scope scopeOf(Ast n) { ) } -module Parameter { - abstract class Scope extends Ast { - abstract string getName(); - } - - private class ParameterScope extends Scope instanceof Parameter { - final override string getName() { result = Parameter.super.getName() } - } -} - abstract private class ScopeImpl extends Ast { abstract Scope getOuterScopeImpl(); diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Synthesis.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Synthesis.qll index 24cb4d323b65..68c2452ba61c 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Synthesis.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Synthesis.qll @@ -26,7 +26,7 @@ newtype VarKind = PipelineIteratorKind() or PipelineByPropertyNameIteratorKind(string name) { exists(Raw::ProcessBlock pb | - name = pb.getScriptBlock().getParamBlock().getAPipelineByPropertyNameParameter().getName() + name = pb.getScriptBlock().getParamBlock().getAPipelineByPropertyNameParameter().getLowerCaseName() ) } @@ -156,7 +156,7 @@ private module SetVariableAssignment { override predicate explicitAssignment(Raw::Ast dest, string name, Raw::Ast assignment) { exists(Raw::Cmd cmd | assignment = cmd and - cmd.getCommandName().toLowerCase() = "set-variable" and + cmd.getLowerCaseName() = "set-variable" and cmd.getNamedArgument("name") = dest and name = dest.(Raw::StringConstExpr).getValue().getValue() ) @@ -192,7 +192,7 @@ private module ParameterSynth { override predicate implicitAssignment(Raw::Ast dest, string name) { exists(Raw::Parameter p | dest = p and - name = p.getName() + name = p.getLowerCaseName() ) } @@ -200,7 +200,7 @@ private module ParameterSynth { exists(Raw::Ast parent, ChildIndex i | v = TVariableSynth(parent, i) | exists(Raw::Parameter p | this.parameter(parent, i, p, _) and - name = p.getName() + name = p.getLowerCaseName() ) or this.isPipelineParameterChild(parent, _, i, _, true) and @@ -765,7 +765,7 @@ private module IteratorAccessSynth { or // or // result = "psitem" // TODO: This is also an automatic variable - result = pb.getScriptBlock().getParamBlock().getPipelineParameter().getName().toLowerCase() + result = pb.getScriptBlock().getParamBlock().getPipelineParameter().getLowerCaseName() ) or // TODO: We could join on something other than the string if we wanted (i.e., the raw parameter). @@ -774,8 +774,7 @@ private module IteratorAccessSynth { pb.getScriptBlock() .getParamBlock() .getAPipelineByPropertyNameParameter() - .getName() - .toLowerCase() + .getLowerCaseName() } private class IteratorAccessSynth extends Synthesis { @@ -787,14 +786,13 @@ private module IteratorAccessSynth { va.getUserPath() = "_" or va.getUserPath().toLowerCase() = - pb.getScriptBlock().getParamBlock().getPipelineParameter().getName().toLowerCase() + pb.getScriptBlock().getParamBlock().getPipelineParameter().getLowerCaseName() or va.getUserPath().toLowerCase() = pb.getScriptBlock() .getParamBlock() .getAPipelineByPropertyNameParameter() - .getName() - .toLowerCase() + .getLowerCaseName() ) } @@ -829,7 +827,7 @@ private module IteratorAccessSynth { or exists(Raw::Parameter p | p = pb.getScriptBlock().getParamBlock().getAPipelineByPropertyNameParameter() and - child = SynthChild(VarSynthKind(PipelineByPropertyNameIteratorKind(p.getName()))) and + child = SynthChild(VarSynthKind(PipelineByPropertyNameIteratorKind(p.getLowerCaseName()))) and i = PipelineByPropertyNameIteratorVar(p) ) ) @@ -864,7 +862,7 @@ private module IteratorAccessSynth { or exists(Raw::PipelineByPropertyNameParameter p | v = TVariableSynth(_, PipelineByPropertyNameIteratorVar(p)) and - name = "__pipeline_iterator for " + p.getName() + name = "__pipeline_iterator for " + p.getLowerCaseName() ) } @@ -896,7 +894,7 @@ private module PipelineAccess { ) or exists(PipelineByPropertyNameParameter pipelineVar, Raw::PipelineByPropertyNameParameter p | - i = processBlockPipelineByPropertyNameVarReadAccess(p.getName()) and + i = processBlockPipelineByPropertyNameVarReadAccess(p.getLowerCaseName()) and getResultAst(p) = pipelineVar and child = SynthChild(VarAccessSynthKind(pipelineVar)) ) diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/TAst.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/TAst.qll index f62e71e58b91..b8f91de3cac8 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/TAst.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/TAst.qll @@ -13,9 +13,9 @@ private predicate mkSynthChild(SynthKind kind, Raw::Ast parent, ChildIndex i) { string variableNameInScope(Raw::Ast n, Scope::Range scope) { scope = Raw::scopeOf(n) and ( - result = n.(Raw::VarAccess).getUserPath() and - not scope.getAParameter().(Raw::PipelineByPropertyNameParameter).getName() = result and - not result.toLowerCase() = ["_", "this", "false", "true", "null"] and + result = n.(Raw::VarAccess).getUserPath().toLowerCase() and + not scope.getAParameter().(Raw::PipelineByPropertyNameParameter).getLowerCaseName() = result and + not result = ["_", "this", "false", "true", "null"] and not parameter(_, n, _, _) and not Raw::isEnvVariableAccess(n, _) or @@ -56,7 +56,7 @@ private predicate inherits(Scope::Range scope, string name, Scope::Range outer) pragma[nomagic] private predicate hasScopeAndName(VariableImpl variable, Scope::Range scope, string name) { - variable.getNameImpl() = name and + variable.getLowerCaseNameImpl() = name and scope = variable.getDeclaringScopeImpl() } diff --git a/powershell/ql/lib/semmle/code/powershell/ast/internal/Variable.qll b/powershell/ql/lib/semmle/code/powershell/ast/internal/Variable.qll index bfff89bdd209..89fc6d2bba1c 100644 --- a/powershell/ql/lib/semmle/code/powershell/ast/internal/Variable.qll +++ b/powershell/ql/lib/semmle/code/powershell/ast/internal/Variable.qll @@ -5,9 +5,9 @@ module Private { class TVariable = TVariableReal or TVariableSynth; class VariableImpl extends Ast, TVariable { - abstract string getNameImpl(); + abstract string getLowerCaseNameImpl(); - final override string toString() { result = this.getNameImpl() } + final override string toString() { result = this.getLowerCaseNameImpl() } abstract Location getLocationImpl(); @@ -21,7 +21,7 @@ module Private { VariableReal() { this = TVariableReal(scope, name, n) } - override string getNameImpl() { result = name } + override string getLowerCaseNameImpl() { result = name } override Location getLocationImpl() { result = n.getLocation() } @@ -36,7 +36,7 @@ module Private { VariableSynth() { this = TVariableSynth(scope, i) } - override string getNameImpl() { any(Synthesis s).variableSynthName(this, result) } + override string getLowerCaseNameImpl() { any(Synthesis s).variableSynthName(this, result) } override Location getLocationImpl() { result = any(Synthesis s).getLocation(this) } @@ -92,7 +92,7 @@ module Private { string getPropertyName() { exists(Raw::PipelineByPropertyNameParameter p | i = PipelineByPropertyNameIteratorVar(p) and - result = p.getName() + result = p.getLowerCaseName() ) } @@ -100,7 +100,7 @@ module Private { exists(Raw::PipelineByPropertyNameParameter p | i = PipelineByPropertyNameIteratorVar(p) and p.getScriptBlock() = getRawAst(result.getEnclosingFunction().getBody()) and - p.getName() = result.getName() + p.getLowerCaseName() = result.getLowerCaseName() ) } } @@ -127,7 +127,7 @@ module Private { final override Variable getVariableImpl() { any(Synthesis s).getAnAccess(this, result) } - final override string toString() { result = this.getVariableImpl().getName() } + final override string toString() { result = this.getVariableImpl().getLowerCaseName() } final override Location getLocation() { result = parent.getLocation() } } @@ -145,9 +145,17 @@ private import Private module Public { class Variable extends Ast instanceof VariableImpl { - final string getName() { result = super.getNameImpl() } + final string getLowerCaseName() { result = super.getLowerCaseNameImpl() } - final override string toString() { result = this.getName() } + final override string toString() { result = this.getLowerCaseName() } + + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } + + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } final override Location getLocation() { result = super.getLocationImpl() } diff --git a/powershell/ql/lib/semmle/code/powershell/controlflow/CfgNodes.qll b/powershell/ql/lib/semmle/code/powershell/controlflow/CfgNodes.qll index 555aa6637170..cf04bead05d2 100644 --- a/powershell/ql/lib/semmle/code/powershell/controlflow/CfgNodes.qll +++ b/powershell/ql/lib/semmle/code/powershell/controlflow/CfgNodes.qll @@ -538,9 +538,17 @@ module ExprNodes { ExprCfgNode getAnArgument() { result = this.getArgument(_) } /** Gets the name that is used to select the callee. */ - string getName() { result = e.getName() } + string getLowerCaseName() { result = e.getLowerCaseName() } + + predicate hasLowerCaseName(string name) { this.getLowerCaseName() = name } + + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } - predicate hasName(string name) { this.getName() = name } + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } /** Gets the i'th positional argument to this call. */ ExprCfgNode getPositionalArgument(int i) { @@ -1041,7 +1049,15 @@ module ExprNodes { CallExprCfgNode getCall() { result.getAnArgument() = this } - string getName() { result = e.getName() } + string getLowerCaseName() { result = e.getLowerCaseName() } + + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } + + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } int getPosition() { result = e.getPosition() } } diff --git a/powershell/ql/lib/semmle/code/powershell/controlflow/ControlFlowGraph.qll b/powershell/ql/lib/semmle/code/powershell/controlflow/ControlFlowGraph.qll index d8ec9bb88020..cb35a2379402 100644 --- a/powershell/ql/lib/semmle/code/powershell/controlflow/ControlFlowGraph.qll +++ b/powershell/ql/lib/semmle/code/powershell/controlflow/ControlFlowGraph.qll @@ -41,9 +41,6 @@ class CfgNode extends CfgImpl::Node { /** Gets the file of this control flow node. */ final File getFile() { result = this.getLocation().getFile() } - /** DEPRECATED: Use `getAstNode` instead. */ - deprecated Ast getNode() { result = this.getAstNode() } - /** Gets a successor node of a given type, if any. */ final CfgNode getASuccessor(SuccessorType t) { result = super.getASuccessor(t) } diff --git a/powershell/ql/lib/semmle/code/powershell/controlflow/internal/Completion.qll b/powershell/ql/lib/semmle/code/powershell/controlflow/internal/Completion.qll index d551b674fbad..39444b4afb5c 100644 --- a/powershell/ql/lib/semmle/code/powershell/controlflow/internal/Completion.qll +++ b/powershell/ql/lib/semmle/code/powershell/controlflow/internal/Completion.qll @@ -24,7 +24,7 @@ private newtype TCompletion = private predicate commandThrows(CallExpr c, boolean unconditional) { c.getNamedArgument("ErrorAction").getValue().asString() = "Stop" and - if c.getName() = "Write-Error" then unconditional = true else unconditional = false + if c.matchesName("Write-Error") then unconditional = true else unconditional = false } pragma[noinline] diff --git a/powershell/ql/lib/semmle/code/powershell/dataflow/FlowSummary.qll b/powershell/ql/lib/semmle/code/powershell/dataflow/FlowSummary.qll index 4e1b38358f2a..de05d4bc7ddd 100644 --- a/powershell/ql/lib/semmle/code/powershell/dataflow/FlowSummary.qll +++ b/powershell/ql/lib/semmle/code/powershell/dataflow/FlowSummary.qll @@ -56,7 +56,7 @@ abstract class SimpleSummarizedCallable extends SummarizedCallable { CallExpr c; bindingset[this] - SimpleSummarizedCallable() { c.getName() = this } + SimpleSummarizedCallable() { c.getLowerCaseName() = this } final override CallExpr getACall() { result = c } diff --git a/powershell/ql/lib/semmle/code/powershell/dataflow/Ssa.qll b/powershell/ql/lib/semmle/code/powershell/dataflow/Ssa.qll index 0d1b37283265..7c6e9c35692a 100644 --- a/powershell/ql/lib/semmle/code/powershell/dataflow/Ssa.qll +++ b/powershell/ql/lib/semmle/code/powershell/dataflow/Ssa.qll @@ -34,13 +34,6 @@ module Ssa { */ final VarReadAccessCfgNode getAFirstRead() { SsaImpl::firstRead(this, result) } - /** - * Gets a last control-flow node that reads the value of this SSA definition. - * That is, a read that can reach the end of the enclosing CFG scope, or another - * SSA definition for the source variable, without passing through any other read. - */ - deprecated final VarReadAccessCfgNode getALastRead() { SsaImpl::lastRead(this, result) } - /** * Holds if `read1` and `read2` are adjacent reads of this SSA definition. * That is, `read2` can be reached from `read1` without passing through diff --git a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowDispatch.qll b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowDispatch.qll index 3c3dba5cfd72..57e3f5390947 100644 --- a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowDispatch.qll +++ b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowDispatch.qll @@ -200,7 +200,7 @@ private predicate qualifiedCall( CfgNodes::ExprNodes::CallExprCfgNode call, Node receiver, string method ) { call.getQualifier() = receiver.asExpr() and - call.getName() = method + call.getLowerCaseName() = method } Node trackInstance(string typename, boolean exact) { @@ -287,7 +287,7 @@ private module Cached { newtype TArgumentPosition = TThisArgumentPosition() or TKeywordArgumentPosition(string name) { - name = any(Argument p).getName() + name = any(Argument p).getLowerCaseName() or FlowSummaryImpl::ParsePositions::isParsedKeywordParameterPosition(_, name) } or @@ -304,7 +304,7 @@ private module Cached { cached newtype TParameterPosition = TThisParameterPosition() or - TKeywordParameter(string name) { name = any(Argument p).getName() } or + TKeywordParameter(string name) { name = any(Argument p).getLowerCaseName() } or TPositionalParameter(int pos, NamedSet ns) { exists(CfgNodes::ExprNodes::CallExprCfgNode call | call = ns.getABindingCall() and diff --git a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPrivate.qll b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPrivate.qll index ee37aa00f6fa..bd0aa428094d 100644 --- a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPrivate.qll +++ b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPrivate.qll @@ -47,15 +47,6 @@ private class ExprNodeImpl extends ExprNode, NodeImpl { override string toStringImpl() { result = this.getExprNode().toString() } } -/** Gets the SSA definition node corresponding to parameter `p`. */ -pragma[nomagic] -SsaImpl::DefinitionExt getParameterDef(Parameter p) { - exists(EntryBasicBlock bb, int i | - bb.getNode(i).getAstNode() = p and - result.definesAt(_, bb, i, _) - ) -} - /** Provides logic related to SSA. */ module SsaFlow { private module Impl = SsaImpl::DataFlowIntegration; @@ -453,7 +444,7 @@ class SsaDefinitionNodeImpl extends SsaNode { exists(SsaImpl::Definition def | def = this.getDefinition() | not def instanceof Ssa::WriteDefinition or - def = getParameterDef(_) + def = SsaImpl::getParameterDef(_) ) } } @@ -514,7 +505,7 @@ class NamedSet extends NamedSet0 { /** Gets a function that has a parameter for each name in this set. */ Function getAFunction() { - forex(string name | name = this.getAName() | result.getAParameter().hasName(name)) + forex(string name | name = this.getAName() | result.getAParameter().matchesName(name)) or this.isEmpty() and exists(result) @@ -556,7 +547,7 @@ private module ParameterNodes { override predicate isParameterOf(DataFlowCallable c, ParameterPosition pos) { parameter.getEnclosingScope() = c.asCfgScope() and ( - pos.isKeyword(parameter.getName().toLowerCase()) + pos.isKeyword(parameter.getLowerCaseName()) or // Given a function f with parameters x, y we map // x to the positions: @@ -574,14 +565,14 @@ private module ParameterNodes { parameter.getIndexExcludingPipelines() = i and f = parameter.getFunction() and f = ns.getAFunction() and - name = parameter.getName().toLowerCase() and + name = parameter.getLowerCaseName() and not name = ns.getAName() and j = i - count(int k, Parameter p | k < i and p = getNormalParameter(f, k) and - p.getName() = ns.getAName() + p.getLowerCaseName() = ns.getAName() ) ) ) @@ -652,7 +643,7 @@ private module ParameterNodes { override string toStringImpl() { result = this.getParameter().toString() } - string getPropertyName() { result = parameter.getPropertyName() } + string getPropertyName() { result = parameter.getLowerCaseName() } } /** A parameter for a library callable with a flow summary. */ @@ -721,7 +712,7 @@ module ArgumentNodes { ) { arg.getCall() = call and ( - pos.isKeyword(arg.getName()) + pos.isKeyword(arg.getLowerCaseName()) or exists(NamedSet ns, int i | i = arg.getPosition() and @@ -1009,7 +1000,7 @@ predicate readStep(Node node1, ContentSet c, Node node2) { or exists(PipelineByPropertyNameParameter p, Content::KnownElementContent ec | c.isKnownOrUnknownElement(ec) and - ec.getIndex().asString() = p.getPropertyName() and + ec.getIndex().asString() = p.getLowerCaseName() and node1 = TProcessPropertyByNameNode(p, false) and node2 = TProcessPropertyByNameNode(p, true) ) diff --git a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPublic.qll b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPublic.qll index 7fc9295a9d17..4d9681761f94 100644 --- a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPublic.qll +++ b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/DataFlowPublic.qll @@ -180,7 +180,7 @@ private module Cached { cached predicate hasMethodCall(LocalSourceNode source, CallNode call, string name) { source.flowsTo(call.getQualifier()) and - call.getName() = name + call.getLowerCaseName() = name } cached @@ -506,7 +506,15 @@ class CallNode extends ExprNode { CfgNodes::ExprNodes::CallExprCfgNode getCallNode() { result = call } - string getName() { result = call.getName() } + string getLowerCaseName() { result = call.getLowerCaseName() } + + bindingset[name] + pragma[inline_late] + final predicate matchesName(string name) { this.getLowerCaseName() = name.toLowerCase() } + + bindingset[result] + pragma[inline_late] + final string getAName() { result.toLowerCase() = this.getLowerCaseName() } Node getQualifier() { result.asExpr() = call.getQualifier() } diff --git a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/SsaImpl.qll b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/SsaImpl.qll index 7e4b811e0911..037f58e8eb7c 100644 --- a/powershell/ql/lib/semmle/code/powershell/dataflow/internal/SsaImpl.qll +++ b/powershell/ql/lib/semmle/code/powershell/dataflow/internal/SsaImpl.qll @@ -78,66 +78,6 @@ private predicate variableReadActual(Cfg::BasicBlock bb, int i, Variable v) { ) } -pragma[noinline] -deprecated private predicate adjacentDefReadExt( - DefinitionExt def, SsaInput::BasicBlock bb1, int i1, SsaInput::BasicBlock bb2, int i2, - SsaInput::SourceVariable v -) { - Impl::adjacentDefReadExt(def, _, bb1, i1, bb2, i2) and - v = def.getSourceVariable() -} - -deprecated private predicate adjacentDefReachesReadExt( - DefinitionExt def, SsaInput::BasicBlock bb1, int i1, SsaInput::BasicBlock bb2, int i2 -) { - exists(SsaInput::SourceVariable v | adjacentDefReadExt(def, bb1, i1, bb2, i2, v) | - def.definesAt(v, bb1, i1, _) - or - SsaInput::variableRead(bb1, i1, v, true) - ) - or - exists(SsaInput::BasicBlock bb3, int i3 | - adjacentDefReachesReadExt(def, bb1, i1, bb3, i3) and - SsaInput::variableRead(bb3, i3, _, false) and - Impl::adjacentDefReadExt(def, _, bb3, i3, bb2, i2) - ) -} - -deprecated private predicate adjacentDefReachesUncertainReadExt( - DefinitionExt def, SsaInput::BasicBlock bb1, int i1, SsaInput::BasicBlock bb2, int i2 -) { - adjacentDefReachesReadExt(def, bb1, i1, bb2, i2) and - SsaInput::variableRead(bb2, i2, _, false) -} - -/** Same as `lastRefRedef`, but skips uncertain reads. */ -pragma[nomagic] -deprecated private predicate lastRefSkipUncertainReadsExt( - DefinitionExt def, SsaInput::BasicBlock bb, int i -) { - Impl::lastRef(def, bb, i) and - not SsaInput::variableRead(bb, i, def.getSourceVariable(), false) - or - exists(SsaInput::BasicBlock bb0, int i0 | - Impl::lastRef(def, bb0, i0) and - adjacentDefReachesUncertainReadExt(def, bb, i, bb0, i0) - ) -} - -/** - * Holds if the read of `def` at `read` may be a last read. That is, `read` - * can either reach another definition of the underlying source variable or - * the end of the CFG scope, without passing through another non-pseudo read. - */ -pragma[nomagic] -deprecated predicate lastRead(Definition def, VarReadAccessCfgNode read) { - exists(Cfg::BasicBlock bb, int i | - lastRefSkipUncertainReadsExt(def, bb, i) and - variableReadActual(bb, i, _) and - read = bb.getNode(i) - ) -} - cached private module Cached { /** @@ -239,39 +179,12 @@ private module Cached { import Cached -/** - * An extended static single assignment (SSA) definition. - * - * This is either a normal SSA definition (`Definition`) or a - * phi-read node (`PhiReadNode`). - * - * Only intended for internal use. - */ -class DefinitionExt extends Impl::DefinitionExt { - VarReadAccessCfgNode getARead() { result = getARead(this) } - - override string toString() { result = this.(Ssa::Definition).toString() } - - override Location getLocation() { result = this.(Ssa::Definition).getLocation() } -} - -/** - * A phi-read node. - * - * Only intended for internal use. - */ -class PhiReadNode extends DefinitionExt, Impl::PhiReadNode { - override string toString() { result = "SSA phi read(" + this.getSourceVariable() + ")" } - - override Location getLocation() { result = Impl::PhiReadNode.super.getLocation() } -} - /** Gets the SSA definition node corresponding to parameter `p`. */ pragma[nomagic] -DefinitionExt getParameterDef(Parameter p) { +Definition getParameterDef(Parameter p) { exists(Cfg::BasicBlock bb, int i | bb.getNode(i).getAstNode() = p and - result.definesAt(_, bb, i, _) + result.definesAt(_, bb, i) ) } diff --git a/powershell/ql/lib/semmle/code/powershell/frameworks/SystemManagementAutomationEngineIntrinsics/EngineIntrinsics.qll b/powershell/ql/lib/semmle/code/powershell/frameworks/SystemManagementAutomationEngineIntrinsics/EngineIntrinsics.qll index b22dd618246a..37b7fe8c5332 100644 --- a/powershell/ql/lib/semmle/code/powershell/frameworks/SystemManagementAutomationEngineIntrinsics/EngineIntrinsics.qll +++ b/powershell/ql/lib/semmle/code/powershell/frameworks/SystemManagementAutomationEngineIntrinsics/EngineIntrinsics.qll @@ -6,7 +6,7 @@ module EngineIntrinsics { private class EngineIntrinsicsGlobalEntry extends ModelInput::TypeModel { override DataFlow::Node getASource(string type) { type = "System.Management.Automation.EngineIntrinsics" and - result.asExpr().getExpr().(VarReadAccess).getVariable().getName().toLowerCase() = "executioncontext" + result.asExpr().getExpr().(VarReadAccess).getVariable().matchesName("ExecutionContext") } } } diff --git a/powershell/ql/lib/semmle/code/powershell/frameworks/data/internal/ApiGraphModelsSpecific.qll b/powershell/ql/lib/semmle/code/powershell/frameworks/data/internal/ApiGraphModelsSpecific.qll index d97c3cd78c8a..cd6ae9b74f0d 100644 --- a/powershell/ql/lib/semmle/code/powershell/frameworks/data/internal/ApiGraphModelsSpecific.qll +++ b/powershell/ql/lib/semmle/code/powershell/frameworks/data/internal/ApiGraphModelsSpecific.qll @@ -63,7 +63,7 @@ API::Node getExtraNodeFromPath(string type, AccessPath path, int n) { n = 1 and exists(string methodName, DataFlow::CallNode call | methodMatchedByName(path, methodName) and - call.getName() = methodName and + call.matchesName(methodName) and result.(API::MethodAccessNode).asCall() = call ) } diff --git a/powershell/ql/lib/semmle/code/powershell/security/CommandInjectionCustomizations.qll b/powershell/ql/lib/semmle/code/powershell/security/CommandInjectionCustomizations.qll index 7f2ab885764d..6935f8900404 100644 --- a/powershell/ql/lib/semmle/code/powershell/security/CommandInjectionCustomizations.qll +++ b/powershell/ql/lib/semmle/code/powershell/security/CommandInjectionCustomizations.qll @@ -21,7 +21,7 @@ module CommandInjection { /** * A data flow sink for command-injection vulnerabilities. */ - abstract class Sink extends DataFlow::Node { + abstract class Sink extends DataFlow::Node { abstract string getSinkType(); } @@ -42,170 +42,161 @@ module CommandInjection { SystemCommandExecutionSink() { // An argument to a call exists(DataFlow::CallNode call | - call.getName() = ["Invoke-Expression", "iex"] and + call.matchesName(["Invoke-Expression", "iex"]) and call.getAnArgument() = this ) or // Or the call command itself in case it's a use of operator &. any(DataFlow::CallOperatorNode call).getCommand() = this } - override string getSinkType() { - result = "call to Invoke-Expression" - } + + override string getSinkType() { result = "call to Invoke-Expression" } } class AddTypeSink extends Sink { AddTypeSink() { exists(DataFlow::CallNode call | - call.getName() = "Add-Type" and + call.matchesName("Add-Type") and call.getAnArgument() = this ) } - override string getSinkType() { - result = "call to Add-Type" - } + + override string getSinkType() { result = "call to Add-Type" } } class InvokeScriptSink extends Sink { - InvokeScriptSink() { - exists(API::Node call | - API::getTopLevelMember("executioncontext").getMember("invokecommand").getMethod("invokescript") = call and - this = call.getArgument(_).asSink() - ) + InvokeScriptSink() { + exists(API::Node call | + API::getTopLevelMember("executioncontext") + .getMember("invokecommand") + .getMethod("invokescript") = call and + this = call.getArgument(_).asSink() + ) } - override string getSinkType(){ - result = "call to InvokeScript" - } -} -class CreateNestedPipelineSink extends Sink { - CreateNestedPipelineSink() { - exists(API::Node call | - API::getTopLevelMember("host").getMember("runspace").getMethod("createnestedpipeline") = call and - this = call.getArgument(_).asSink() - ) - } - override string getSinkType(){ - result = "call to CreateNestedPipeline" + override string getSinkType() { result = "call to InvokeScript" } + } + + class CreateNestedPipelineSink extends Sink { + CreateNestedPipelineSink() { + exists(API::Node call | + API::getTopLevelMember("host").getMember("runspace").getMethod("createnestedpipeline") = + call and + this = call.getArgument(_).asSink() + ) } -} -class AddScriptInvokeSink extends Sink { - AddScriptInvokeSink() { - exists(InvokeMemberExpr addscript, InvokeMemberExpr create | - this.asExpr().getExpr() = addscript.getAnArgument() and - addscript.getName() = "AddScript" and - create.getName() = "Create" and + override string getSinkType() { result = "call to CreateNestedPipeline" } + } - addscript.getQualifier().(InvokeMemberExpr) = create and - create.getQualifier().(TypeNameExpr).getName() = "PowerShell" + class AddScriptInvokeSink extends Sink { + AddScriptInvokeSink() { + exists(InvokeMemberExpr addscript, InvokeMemberExpr create | + this.asExpr().getExpr() = addscript.getAnArgument() and + addscript.matchesName("AddScript") and + create.matchesName("Create") and + addscript.getQualifier().(InvokeMemberExpr) = create and + create.getQualifier().(TypeNameExpr).getName() = "PowerShell" ) + } + + override string getSinkType() { result = "call to AddScript" } } - override string getSinkType(){ - result = "call to AddScript" - } -} -class PowershellSink extends Sink { - PowershellSink() { - exists( CmdCall c | - c.getName() = "powershell" | - ( - this.asExpr().getExpr() = c.getArgument(1) and - c.getArgument(0).getValue().asString() = "-command" - ) or - ( - this.asExpr().getExpr() = c.getArgument(0) - ) - ) + class PowershellSink extends Sink { + PowershellSink() { + exists(CmdCall c | c.matchesName("powershell") | + this.asExpr().getExpr() = c.getArgument(1) and + c.getArgument(0).getValue().asString() = "-command" + or + this.asExpr().getExpr() = c.getArgument(0) + ) } - override string getSinkType(){ - result = "call to Powershell" + + override string getSinkType() { result = "call to Powershell" } + } + + class CmdSink extends Sink { + CmdSink() { + exists(CmdCall c | + this.asExpr().getExpr() = c.getArgument(1) and + c.matchesName("cmd") and + c.getArgument(0).getValue().asString() = "/c" + ) } -} -class CmdSink extends Sink { - CmdSink() { - exists(CmdCall c | - this.asExpr().getExpr() = c.getArgument(1) and - c.getName() = "cmd" and - c.getArgument(0).getValue().asString() = "/c" - ) - } - override string getSinkType(){ - result = "call to Cmd" + override string getSinkType() { result = "call to Cmd" } + } + + class ForEachObjectSink extends Sink { + ForEachObjectSink() { + exists(CmdCall c | + this.asExpr().getExpr() = c.getAnArgument() and + c.matchesName("Foreach-Object") + ) } -} -class ForEachObjectSink extends Sink { - ForEachObjectSink() { - exists(CmdCall c | - this.asExpr().getExpr() = c.getAnArgument() and - c.getName() = "Foreach-Object" - ) - } - override string getSinkType(){ - result = "call to ForEach-Object" + override string getSinkType() { result = "call to ForEach-Object" } + } + + class InvokeSink extends Sink { + InvokeSink() { + exists(InvokeMemberExpr ie | + this.asExpr().getExpr() = ie.getCallee() or + this.asExpr().getExpr() = ie.getQualifier().getAChild*() + ) } -} -class InvokeSink extends Sink { - InvokeSink() { - exists(InvokeMemberExpr ie | - this.asExpr().getExpr() = ie.getCallee() or - this.asExpr().getExpr() = ie.getQualifier().getAChild*() - ) - } - override string getSinkType(){ - result = "call to Invoke" + override string getSinkType() { result = "call to Invoke" } + } + + class CreateScriptBlockSink extends Sink { + CreateScriptBlockSink() { + exists(InvokeMemberExpr ie | + this.asExpr().getExpr() = ie.getAnArgument() and + ie.matchesName("Create") and + ie.getQualifier().(TypeNameExpr).getName() = "ScriptBlock" + ) } -} -class CreateScriptBlockSink extends Sink { - CreateScriptBlockSink() { - exists(InvokeMemberExpr ie | - this.asExpr().getExpr() = ie.getAnArgument() and - ie.getName() = "Create" and - ie.getQualifier().(TypeNameExpr).getName() = "ScriptBlock" - ) - } - override string getSinkType(){ - result = "call to CreateScriptBlock" + override string getSinkType() { result = "call to CreateScriptBlock" } + } + + class NewScriptBlockSink extends Sink { + NewScriptBlockSink() { + exists(API::Node call | + API::getTopLevelMember("executioncontext") + .getMember("invokecommand") + .getMethod("newscriptblock") = call and + this = call.getArgument(_).asSink() + ) } -} -class NewScriptBlockSink extends Sink { - NewScriptBlockSink() { - exists(API::Node call | - API::getTopLevelMember("executioncontext").getMember("invokecommand").getMethod("newscriptblock") = call and - this = call.getArgument(_).asSink() - ) - } - override string getSinkType(){ - result = "call to NewScriptBlock" - } -} + override string getSinkType() { result = "call to NewScriptBlock" } + } -class ExpandStringSink extends Sink { - ExpandStringSink() { - exists(API::Node call | this = call.getArgument(_).asSink() | - API::getTopLevelMember("executioncontext").getMember("invokecommand").getMethod("expandstring") = call or - API::getTopLevelMember("executioncontext").getMember("sessionstate").getMember("invokecommand").getMethod("expandstring") = call - - ) - } - override string getSinkType(){ - result = "call to ExpandString" - } -} + class ExpandStringSink extends Sink { + ExpandStringSink() { + exists(API::Node call | this = call.getArgument(_).asSink() | + API::getTopLevelMember("executioncontext") + .getMember("invokecommand") + .getMethod("expandstring") = call or + API::getTopLevelMember("executioncontext") + .getMember("sessionstate") + .getMember("invokecommand") + .getMethod("expandstring") = call + ) + } + + override string getSinkType() { result = "call to ExpandString" } + } private class ExternalCommandInjectionSink extends Sink { ExternalCommandInjectionSink() { this = ModelOutput::getASinkNode("command-injection").asSink() } - override string getSinkType() { - result = "external command injection" - } + + override string getSinkType() { result = "external command injection" } } class TypedParameterSanitizer extends Sanitizer { @@ -217,15 +208,16 @@ class ExpandStringSink extends Sink { ) } } - + class SingleQuoteSanitizer extends Sanitizer { - SingleQuoteSanitizer() { - exists(ExpandableStringExpr e, VarReadAccess v | - v = this.asExpr().getExpr() and - e.getUnexpandedValue().matches("%'$" + v.getVariable().getName() + "'%") and - e.getAnExpr() = v - ) + SingleQuoteSanitizer() { + exists(ExpandableStringExpr e, VarReadAccess v | + v = this.asExpr().getExpr() and + e.getUnexpandedValue() + .toLowerCase() + .matches("%'$" + v.getVariable().getLowerCaseName() + "'%") and + e.getAnExpr() = v + ) } } } - diff --git a/powershell/ql/src/experimental/CommandInjection.ql b/powershell/ql/src/experimental/CommandInjection.ql index 9f4696533ea9..82ce42ebd313 100644 --- a/powershell/ql/src/experimental/CommandInjection.ql +++ b/powershell/ql/src/experimental/CommandInjection.ql @@ -11,7 +11,7 @@ import powershell predicate containsScope(VarAccess outer, VarAccess inner) { - outer.getVariable().getName() = inner.getVariable().getName() and + outer.getVariable().getLowerCaseName() = inner.getVariable().getLowerCaseName() and outer != inner } @@ -60,7 +60,7 @@ Expr getAllSubExpressions(Expr expr) { Expr dangerousCommandElement(CallExpr command) { ( command instanceof CallOperator or - command.getName() = "Invoke-Expression" + command.matchesName("Invoke-Expression") ) and result = getAllSubExpressions(command.getAnArgument()) } @@ -75,4 +75,4 @@ where commandarg = dangerousCommandElement(command) ) select commandarg.(VarAccess).getLocation(), "Unsafe flow to command argument from $@.", - unknownDeclaration, unknownDeclaration.getVariable().getName() + unknownDeclaration, unknownDeclaration.getVariable().getLowerCaseName() diff --git a/powershell/ql/src/experimental/ConvertToSecureStringAsPlainText.ql b/powershell/ql/src/experimental/ConvertToSecureStringAsPlainText.ql index f01abb69a8ba..c93b9849bff2 100644 --- a/powershell/ql/src/experimental/ConvertToSecureStringAsPlainText.ql +++ b/powershell/ql/src/experimental/ConvertToSecureStringAsPlainText.ql @@ -14,6 +14,6 @@ from CmdCall c where - c.getName() = "ConvertTo-SecureString" and + c.matchesName("ConvertTo-SecureString") and c.hasNamedArgument("asplaintext") select c, "Use of AsPlainText parameter in ConvertTo-SecureString call" \ No newline at end of file diff --git a/powershell/ql/src/experimental/HardcodedComputerName.ql b/powershell/ql/src/experimental/HardcodedComputerName.ql index 860205acb93f..f4468916da01 100644 --- a/powershell/ql/src/experimental/HardcodedComputerName.ql +++ b/powershell/ql/src/experimental/HardcodedComputerName.ql @@ -13,5 +13,5 @@ import powershell from Argument a -where a.getName() = "computername" and exists(a.getValue()) +where a.matchesName("computername") and exists(a.getValue()) select a, "ComputerName argument is hardcoded to" + a.getValue() diff --git a/powershell/ql/src/experimental/UsernameOrPasswordParameter.ql b/powershell/ql/src/experimental/UsernameOrPasswordParameter.ql index d86b74a24624..b82c2572fd67 100644 --- a/powershell/ql/src/experimental/UsernameOrPasswordParameter.ql +++ b/powershell/ql/src/experimental/UsernameOrPasswordParameter.ql @@ -13,5 +13,5 @@ import powershell from Parameter p -where p.getName().toLowerCase() = ["username", "password"] +where p.matchesName(["username", "password"]) select p, "Do not use username or password parameters." diff --git a/powershell/ql/src/queries/security/cwe-078/DoNotUseInvokeExpression.ql b/powershell/ql/src/queries/security/cwe-078/DoNotUseInvokeExpression.ql index aaa4ec8c306a..ed2fe8df398c 100644 --- a/powershell/ql/src/queries/security/cwe-078/DoNotUseInvokeExpression.ql +++ b/powershell/ql/src/queries/security/cwe-078/DoNotUseInvokeExpression.ql @@ -12,5 +12,5 @@ import powershell import semmle.code.powershell.dataflow.DataFlow from CmdCall call -where call.getName() = "Invoke-Expression" +where call.matchesName("Invoke-Expression") select call, "Do not use Invoke-Expression. It is a command injection risk." diff --git a/powershell/ql/test/TestUtilities/InlineFlowTestUtil.qll b/powershell/ql/test/TestUtilities/InlineFlowTestUtil.qll index 96fe15ea7a96..82ab56bacc19 100644 --- a/powershell/ql/test/TestUtilities/InlineFlowTestUtil.qll +++ b/powershell/ql/test/TestUtilities/InlineFlowTestUtil.qll @@ -6,13 +6,13 @@ import powershell import semmle.code.powershell.dataflow.DataFlow predicate defaultSource(DataFlow::Node src) { - src.asExpr().getExpr().(CmdCall).getName() = ["Source", "Taint"] + src.asExpr().getExpr().(CmdCall).matchesName(["Source", "Taint"]) or - src.asParameter().getName().matches(["Source%", "Taint%"]) + src.asParameter().matchesName(["Source%", "Taint%"]) } predicate defaultSink(DataFlow::Node sink) { - exists(CmdCall cmd | cmd.getName() = "Sink" | sink.asExpr().getExpr() = cmd.getAnArgument()) + exists(CmdCall cmd | cmd.matchesName("Sink") | sink.asExpr().getExpr() = cmd.getAnArgument()) } string getSourceArgString(DataFlow::Node src) { @@ -20,6 +20,6 @@ string getSourceArgString(DataFlow::Node src) { ( src.asExpr().getExpr().(CmdCall).getAnArgument().(StringConstExpr).getValue().getValue() = result or - src.asParameter().getName().regexpCapture(["Source(.+)", "Taint(.+)"], 1) = result + src.asParameter().getLowerCaseName().regexpCapture(["source(.+)", "taint(.+)"], 1) = result ) } diff --git a/powershell/ql/test/library-tests/ast/Arguments/arguments.ql b/powershell/ql/test/library-tests/ast/Arguments/arguments.ql index fb5ab3c699ff..c0c4936de1aa 100644 --- a/powershell/ql/test/library-tests/ast/Arguments/arguments.ql +++ b/powershell/ql/test/library-tests/ast/Arguments/arguments.ql @@ -2,4 +2,4 @@ import powershell query predicate positionalArguments(Argument a, int p) { p = a.getPosition() } -query predicate namedArguments(Argument a, string name) { name = a.getName() } +query predicate namedArguments(Argument a, string name) { name = a.getLowerCaseName() } diff --git a/powershell/ql/test/library-tests/ast/Blocks/blocks.expected b/powershell/ql/test/library-tests/ast/Blocks/blocks.expected index 82ef295aa52d..764a43321fcc 100644 --- a/powershell/ql/test/library-tests/ast/Blocks/blocks.expected +++ b/powershell/ql/test/library-tests/ast/Blocks/blocks.expected @@ -1,2 +1,2 @@ -| ParamBlock.ps1:1:1:5:1 | {...} | 0 | ParamBlock.ps1:3:5:4:22 | Parameter | +| ParamBlock.ps1:1:1:5:1 | {...} | 0 | ParamBlock.ps1:3:5:4:22 | parameter | | ParamBlock.ps1:1:1:5:1 | {...} | 1 | ParamBlock.ps1:1:1:5:1 | [synth] pipeline | diff --git a/powershell/ql/test/library-tests/ast/Expressions/expressions.expected b/powershell/ql/test/library-tests/ast/Expressions/expressions.expected index 772ab137630a..dd93724801a5 100644 --- a/powershell/ql/test/library-tests/ast/Expressions/expressions.expected +++ b/powershell/ql/test/library-tests/ast/Expressions/expressions.expected @@ -6,12 +6,12 @@ cmdExpr | ExpandableString.ps1:1:1:1:39 | [Stmt] Date: $([DateTime]::Now)\nName: $name | ExpandableString.ps1:1:1:1:39 | Date: $([DateTime]::Now)\nName: $name | | ExpandableString.ps1:1:23:1:37 | [Stmt] Now | ExpandableString.ps1:1:23:1:37 | Now | | MemberExpression.ps1:2:1:2:14 | [Stmt] ... | MemberExpression.ps1:2:1:2:14 | ... | -| SubExpression.ps1:1:1:1:23 | [Stmt] Call to AddDays | SubExpression.ps1:1:1:1:23 | Call to AddDays | -| SubExpression.ps1:1:3:1:10 | [Stmt] Call to Get-Date | SubExpression.ps1:1:3:1:10 | Call to Get-Date | -| SubExpression.ps1:2:1:2:21 | [Stmt] Call to AddDays | SubExpression.ps1:2:1:2:21 | Call to AddDays | -| SubExpression.ps1:2:3:2:10 | [Stmt] Call to Get-Date | SubExpression.ps1:2:3:2:10 | Call to Get-Date | +| SubExpression.ps1:1:1:1:23 | [Stmt] Call to adddays | SubExpression.ps1:1:1:1:23 | Call to adddays | +| SubExpression.ps1:1:3:1:10 | [Stmt] Call to get-date | SubExpression.ps1:1:3:1:10 | Call to get-date | +| SubExpression.ps1:2:1:2:21 | [Stmt] Call to adddays | SubExpression.ps1:2:1:2:21 | Call to adddays | +| SubExpression.ps1:2:3:2:10 | [Stmt] Call to get-date | SubExpression.ps1:2:3:2:10 | Call to get-date | invokeMemoryExpression -| SubExpression.ps1:1:1:1:23 | Call to AddDays | SubExpression.ps1:1:1:1:11 | $(...) | 0 | SubExpression.ps1:1:21:1:22 | 10 | +| SubExpression.ps1:1:1:1:23 | Call to adddays | SubExpression.ps1:1:1:1:11 | $(...) | 0 | SubExpression.ps1:1:21:1:22 | 10 | expandableString | ExpandableString.ps1:1:1:1:39 | Date: $([DateTime]::Now)\nName: $name | 1 | ExpandableString.ps1:1:21:1:38 | $(...) | memberExpr diff --git a/powershell/ql/test/library-tests/ast/Statements/statements.expected b/powershell/ql/test/library-tests/ast/Statements/statements.expected index f8994f476941..3ab2b06d05b2 100644 --- a/powershell/ql/test/library-tests/ast/Statements/statements.expected +++ b/powershell/ql/test/library-tests/ast/Statements/statements.expected @@ -9,8 +9,8 @@ | TrapStatement.ps1:2:5:2:25 | trap {...} | | TrapStatement.ps1:2:10:2:25 | {...} | | TrapStatement.ps1:2:11:2:24 | [Stmt] Error found. | -| TrapStatement.ps1:3:5:3:18 | [Stmt] Call to nonsenseString | -| TrapStatement.ps1:6:1:6:8 | [Stmt] Call to TrapTest | +| TrapStatement.ps1:3:5:3:18 | [Stmt] Call to nonsensestring | +| TrapStatement.ps1:6:1:6:8 | [Stmt] Call to traptest | | Try.ps1:1:1:13:1 | try {...} | | Try.ps1:1:5:4:1 | {...} | | Try.ps1:2:4:2:94 | ...=... | diff --git a/powershell/ql/test/library-tests/ast/parent.expected b/powershell/ql/test/library-tests/ast/parent.expected index c4462fbebf8b..b15f8fd90371 100644 --- a/powershell/ql/test/library-tests/ast/parent.expected +++ b/powershell/ql/test/library-tests/ast/parent.expected @@ -1,36 +1,36 @@ -| Arguments/arguments.ps1:1:1:1:3 | Foo | Arguments/arguments.ps1:1:1:1:5 | Call to Foo | -| Arguments/arguments.ps1:1:1:1:5 | Call to Foo | Arguments/arguments.ps1:1:1:1:5 | [Stmt] Call to Foo | -| Arguments/arguments.ps1:1:1:1:5 | [Stmt] Call to Foo | Arguments/arguments.ps1:1:1:8:13 | {...} | +| Arguments/arguments.ps1:1:1:1:3 | Foo | Arguments/arguments.ps1:1:1:1:5 | Call to foo | +| Arguments/arguments.ps1:1:1:1:5 | Call to foo | Arguments/arguments.ps1:1:1:1:5 | [Stmt] Call to foo | +| Arguments/arguments.ps1:1:1:1:5 | [Stmt] Call to foo | Arguments/arguments.ps1:1:1:8:13 | {...} | | Arguments/arguments.ps1:1:1:8:13 | {...} | Arguments/arguments.ps1:1:1:8:13 | toplevel function for arguments.ps1 | | Arguments/arguments.ps1:1:1:8:13 | {...} | Arguments/arguments.ps1:1:1:8:13 | {...} | -| Arguments/arguments.ps1:1:5:1:5 | 1 | Arguments/arguments.ps1:1:1:1:5 | Call to Foo | -| Arguments/arguments.ps1:2:1:2:3 | Foo | Arguments/arguments.ps1:2:1:2:8 | Call to Foo | -| Arguments/arguments.ps1:2:1:2:8 | Call to Foo | Arguments/arguments.ps1:2:1:2:8 | [Stmt] Call to Foo | -| Arguments/arguments.ps1:2:1:2:8 | [Stmt] Call to Foo | Arguments/arguments.ps1:1:1:8:13 | {...} | -| Arguments/arguments.ps1:2:8:2:8 | 1 | Arguments/arguments.ps1:2:1:2:8 | Call to Foo | -| Arguments/arguments.ps1:3:1:3:3 | Foo | Arguments/arguments.ps1:3:1:3:8 | Call to Foo | -| Arguments/arguments.ps1:3:1:3:8 | Call to Foo | Arguments/arguments.ps1:3:1:3:8 | [Stmt] Call to Foo | -| Arguments/arguments.ps1:3:1:3:8 | [Stmt] Call to Foo | Arguments/arguments.ps1:1:1:8:13 | {...} | -| Arguments/arguments.ps1:3:8:3:8 | 1 | Arguments/arguments.ps1:3:1:3:8 | Call to Foo | -| Arguments/arguments.ps1:4:1:4:3 | Foo | Arguments/arguments.ps1:4:1:4:6 | Call to Foo | -| Arguments/arguments.ps1:4:1:4:6 | Call to Foo | Arguments/arguments.ps1:4:1:4:6 | [Stmt] Call to Foo | -| Arguments/arguments.ps1:4:1:4:6 | [Stmt] Call to Foo | Arguments/arguments.ps1:1:1:8:13 | {...} | -| Arguments/arguments.ps1:4:5:4:6 | true | Arguments/arguments.ps1:4:1:4:6 | Call to Foo | -| Arguments/arguments.ps1:6:1:6:3 | Bar | Arguments/arguments.ps1:6:1:6:9 | Call to Bar | -| Arguments/arguments.ps1:6:1:6:9 | Call to Bar | Arguments/arguments.ps1:6:1:6:9 | [Stmt] Call to Bar | -| Arguments/arguments.ps1:6:1:6:9 | [Stmt] Call to Bar | Arguments/arguments.ps1:1:1:8:13 | {...} | -| Arguments/arguments.ps1:6:5:6:6 | true | Arguments/arguments.ps1:6:1:6:9 | Call to Bar | -| Arguments/arguments.ps1:6:8:6:9 | true | Arguments/arguments.ps1:6:1:6:9 | Call to Bar | -| Arguments/arguments.ps1:7:1:7:3 | Bar | Arguments/arguments.ps1:7:1:7:13 | Call to Bar | -| Arguments/arguments.ps1:7:1:7:13 | Call to Bar | Arguments/arguments.ps1:7:1:7:13 | [Stmt] Call to Bar | -| Arguments/arguments.ps1:7:1:7:13 | [Stmt] Call to Bar | Arguments/arguments.ps1:1:1:8:13 | {...} | -| Arguments/arguments.ps1:7:8:7:8 | 1 | Arguments/arguments.ps1:7:1:7:13 | Call to Bar | -| Arguments/arguments.ps1:7:13:7:13 | 2 | Arguments/arguments.ps1:7:1:7:13 | Call to Bar | -| Arguments/arguments.ps1:8:1:8:3 | Bar | Arguments/arguments.ps1:8:1:8:13 | Call to Bar | -| Arguments/arguments.ps1:8:1:8:13 | Call to Bar | Arguments/arguments.ps1:8:1:8:13 | [Stmt] Call to Bar | -| Arguments/arguments.ps1:8:1:8:13 | [Stmt] Call to Bar | Arguments/arguments.ps1:1:1:8:13 | {...} | -| Arguments/arguments.ps1:8:8:8:8 | 1 | Arguments/arguments.ps1:8:1:8:13 | Call to Bar | -| Arguments/arguments.ps1:8:13:8:13 | 2 | Arguments/arguments.ps1:8:1:8:13 | Call to Bar | +| Arguments/arguments.ps1:1:5:1:5 | 1 | Arguments/arguments.ps1:1:1:1:5 | Call to foo | +| Arguments/arguments.ps1:2:1:2:3 | Foo | Arguments/arguments.ps1:2:1:2:8 | Call to foo | +| Arguments/arguments.ps1:2:1:2:8 | Call to foo | Arguments/arguments.ps1:2:1:2:8 | [Stmt] Call to foo | +| Arguments/arguments.ps1:2:1:2:8 | [Stmt] Call to foo | Arguments/arguments.ps1:1:1:8:13 | {...} | +| Arguments/arguments.ps1:2:8:2:8 | 1 | Arguments/arguments.ps1:2:1:2:8 | Call to foo | +| Arguments/arguments.ps1:3:1:3:3 | Foo | Arguments/arguments.ps1:3:1:3:8 | Call to foo | +| Arguments/arguments.ps1:3:1:3:8 | Call to foo | Arguments/arguments.ps1:3:1:3:8 | [Stmt] Call to foo | +| Arguments/arguments.ps1:3:1:3:8 | [Stmt] Call to foo | Arguments/arguments.ps1:1:1:8:13 | {...} | +| Arguments/arguments.ps1:3:8:3:8 | 1 | Arguments/arguments.ps1:3:1:3:8 | Call to foo | +| Arguments/arguments.ps1:4:1:4:3 | Foo | Arguments/arguments.ps1:4:1:4:6 | Call to foo | +| Arguments/arguments.ps1:4:1:4:6 | Call to foo | Arguments/arguments.ps1:4:1:4:6 | [Stmt] Call to foo | +| Arguments/arguments.ps1:4:1:4:6 | [Stmt] Call to foo | Arguments/arguments.ps1:1:1:8:13 | {...} | +| Arguments/arguments.ps1:4:5:4:6 | true | Arguments/arguments.ps1:4:1:4:6 | Call to foo | +| Arguments/arguments.ps1:6:1:6:3 | Bar | Arguments/arguments.ps1:6:1:6:9 | Call to bar | +| Arguments/arguments.ps1:6:1:6:9 | Call to bar | Arguments/arguments.ps1:6:1:6:9 | [Stmt] Call to bar | +| Arguments/arguments.ps1:6:1:6:9 | [Stmt] Call to bar | Arguments/arguments.ps1:1:1:8:13 | {...} | +| Arguments/arguments.ps1:6:5:6:6 | true | Arguments/arguments.ps1:6:1:6:9 | Call to bar | +| Arguments/arguments.ps1:6:8:6:9 | true | Arguments/arguments.ps1:6:1:6:9 | Call to bar | +| Arguments/arguments.ps1:7:1:7:3 | Bar | Arguments/arguments.ps1:7:1:7:13 | Call to bar | +| Arguments/arguments.ps1:7:1:7:13 | Call to bar | Arguments/arguments.ps1:7:1:7:13 | [Stmt] Call to bar | +| Arguments/arguments.ps1:7:1:7:13 | [Stmt] Call to bar | Arguments/arguments.ps1:1:1:8:13 | {...} | +| Arguments/arguments.ps1:7:8:7:8 | 1 | Arguments/arguments.ps1:7:1:7:13 | Call to bar | +| Arguments/arguments.ps1:7:13:7:13 | 2 | Arguments/arguments.ps1:7:1:7:13 | Call to bar | +| Arguments/arguments.ps1:8:1:8:3 | Bar | Arguments/arguments.ps1:8:1:8:13 | Call to bar | +| Arguments/arguments.ps1:8:1:8:13 | Call to bar | Arguments/arguments.ps1:8:1:8:13 | [Stmt] Call to bar | +| Arguments/arguments.ps1:8:1:8:13 | [Stmt] Call to bar | Arguments/arguments.ps1:1:1:8:13 | {...} | +| Arguments/arguments.ps1:8:8:8:8 | 1 | Arguments/arguments.ps1:8:1:8:13 | Call to bar | +| Arguments/arguments.ps1:8:13:8:13 | 2 | Arguments/arguments.ps1:8:1:8:13 | Call to bar | | Arrays/Arrays.ps1:0:0:0:-1 | {...} | Arrays/Arrays.ps1:14:41:14:43 | @(...) | | Arrays/Arrays.ps1:1:1:1:7 | array1 | Arrays/Arrays.ps1:1:1:1:36 | ...=... | | Arrays/Arrays.ps1:1:1:1:7 | array1 | Arrays/Arrays.ps1:1:1:15:14 | {...} | @@ -57,11 +57,11 @@ | Arrays/Arrays.ps1:5:1:5:7 | array2 | Arrays/Arrays.ps1:1:1:15:14 | {...} | | Arrays/Arrays.ps1:5:1:5:7 | array2 | Arrays/Arrays.ps1:5:1:5:36 | ...=... | | Arrays/Arrays.ps1:5:1:5:36 | ...=... | Arrays/Arrays.ps1:1:1:15:14 | {...} | -| Arrays/Arrays.ps1:5:11:5:20 | New-Object | Arrays/Arrays.ps1:5:11:5:36 | Call to New-Object | -| Arrays/Arrays.ps1:5:11:5:36 | Call to New-Object | Arrays/Arrays.ps1:5:1:5:36 | ...=... | -| Arrays/Arrays.ps1:5:22:5:32 | object[,] | Arrays/Arrays.ps1:5:11:5:36 | Call to New-Object | +| Arrays/Arrays.ps1:5:11:5:20 | New-Object | Arrays/Arrays.ps1:5:11:5:36 | Call to new-object | +| Arrays/Arrays.ps1:5:11:5:36 | Call to new-object | Arrays/Arrays.ps1:5:1:5:36 | ...=... | +| Arrays/Arrays.ps1:5:22:5:32 | object[,] | Arrays/Arrays.ps1:5:11:5:36 | Call to new-object | | Arrays/Arrays.ps1:5:34:5:34 | 2 | Arrays/Arrays.ps1:5:34:5:36 | ...,... | -| Arrays/Arrays.ps1:5:34:5:36 | ...,... | Arrays/Arrays.ps1:5:11:5:36 | Call to New-Object | +| Arrays/Arrays.ps1:5:34:5:36 | ...,... | Arrays/Arrays.ps1:5:11:5:36 | Call to new-object | | Arrays/Arrays.ps1:5:36:5:36 | 2 | Arrays/Arrays.ps1:5:34:5:36 | ...,... | | Arrays/Arrays.ps1:6:1:6:7 | array2 | Arrays/Arrays.ps1:6:1:6:12 | ...[...] | | Arrays/Arrays.ps1:6:1:6:12 | ...[...] | Arrays/Arrays.ps1:6:1:6:21 | ...=... | @@ -111,40 +111,40 @@ | Arrays/Arrays.ps1:14:11:14:40 | System.Collections.ArrayList | Arrays/Arrays.ps1:14:11:14:43 | [...]... | | Arrays/Arrays.ps1:14:11:14:43 | [...]... | Arrays/Arrays.ps1:14:1:14:43 | ...=... | | Arrays/Arrays.ps1:14:41:14:43 | @(...) | Arrays/Arrays.ps1:14:11:14:43 | [...]... | -| Arrays/Arrays.ps1:15:1:15:7 | array4 | Arrays/Arrays.ps1:15:1:15:14 | Call to Add | -| Arrays/Arrays.ps1:15:1:15:14 | Call to Add | Arrays/Arrays.ps1:15:1:15:14 | [Stmt] Call to Add | -| Arrays/Arrays.ps1:15:1:15:14 | [Stmt] Call to Add | Arrays/Arrays.ps1:1:1:15:14 | {...} | -| Arrays/Arrays.ps1:15:9:15:11 | Add | Arrays/Arrays.ps1:15:1:15:14 | Call to Add | -| Arrays/Arrays.ps1:15:13:15:13 | 1 | Arrays/Arrays.ps1:15:1:15:14 | Call to Add | +| Arrays/Arrays.ps1:15:1:15:7 | array4 | Arrays/Arrays.ps1:15:1:15:14 | Call to add | +| Arrays/Arrays.ps1:15:1:15:14 | Call to add | Arrays/Arrays.ps1:15:1:15:14 | [Stmt] Call to add | +| Arrays/Arrays.ps1:15:1:15:14 | [Stmt] Call to add | Arrays/Arrays.ps1:1:1:15:14 | {...} | +| Arrays/Arrays.ps1:15:9:15:11 | Add | Arrays/Arrays.ps1:15:1:15:14 | Call to add | +| Arrays/Arrays.ps1:15:13:15:13 | 1 | Arrays/Arrays.ps1:15:1:15:14 | Call to add | | Blocks/ParamBlock.ps1:1:1:1:17 | CmdletBinding | Blocks/ParamBlock.ps1:1:1:5:1 | {...} | | Blocks/ParamBlock.ps1:1:1:5:1 | [synth] pipeline | Blocks/ParamBlock.ps1:1:1:5:1 | {...} | | Blocks/ParamBlock.ps1:1:1:5:1 | {...} | Blocks/ParamBlock.ps1:1:1:5:1 | toplevel function for ParamBlock.ps1 | | Blocks/ParamBlock.ps1:2:1:5:1 | {...} | Blocks/ParamBlock.ps1:1:1:5:1 | {...} | -| Blocks/ParamBlock.ps1:3:5:3:17 | Parameter | Blocks/ParamBlock.ps1:3:5:4:22 | Parameter | -| Blocks/ParamBlock.ps1:3:5:4:22 | Parameter | Blocks/ParamBlock.ps1:1:1:5:1 | {...} | -| Blocks/ParamBlock.ps1:4:5:4:12 | string | Blocks/ParamBlock.ps1:3:5:4:22 | Parameter | +| Blocks/ParamBlock.ps1:3:5:3:17 | Parameter | Blocks/ParamBlock.ps1:3:5:4:22 | parameter | +| Blocks/ParamBlock.ps1:3:5:4:22 | parameter | Blocks/ParamBlock.ps1:1:1:5:1 | {...} | +| Blocks/ParamBlock.ps1:4:5:4:12 | string | Blocks/ParamBlock.ps1:3:5:4:22 | parameter | | Dynamic/DynamicExecution.ps1:1:1:1:4 | foo | Dynamic/DynamicExecution.ps1:1:1:1:16 | ...=... | | Dynamic/DynamicExecution.ps1:1:1:1:4 | foo | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | | Dynamic/DynamicExecution.ps1:1:1:1:16 | ...=... | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | Dynamic/DynamicExecution.ps1:1:1:5:7 | toplevel function for DynamicExecution.ps1 | | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | | Dynamic/DynamicExecution.ps1:1:8:1:16 | cmd.exe | Dynamic/DynamicExecution.ps1:1:1:1:16 | ...=... | -| Dynamic/DynamicExecution.ps1:2:1:2:17 | Invoke-Expression | Dynamic/DynamicExecution.ps1:2:1:2:22 | Call to Invoke-Expression | -| Dynamic/DynamicExecution.ps1:2:1:2:22 | Call to Invoke-Expression | Dynamic/DynamicExecution.ps1:2:1:2:22 | [Stmt] Call to Invoke-Expression | -| Dynamic/DynamicExecution.ps1:2:1:2:22 | [Stmt] Call to Invoke-Expression | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | -| Dynamic/DynamicExecution.ps1:2:19:2:22 | foo | Dynamic/DynamicExecution.ps1:2:1:2:22 | Call to Invoke-Expression | -| Dynamic/DynamicExecution.ps1:3:1:3:13 | scriptblock | Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to Create | -| Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to Create | Dynamic/DynamicExecution.ps1:3:1:3:27 | [Stmt] Call to Create | -| Dynamic/DynamicExecution.ps1:3:1:3:27 | [Stmt] Call to Create | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | -| Dynamic/DynamicExecution.ps1:3:16:3:21 | Create | Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to Create | -| Dynamic/DynamicExecution.ps1:3:23:3:26 | foo | Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to Create | +| Dynamic/DynamicExecution.ps1:2:1:2:17 | Invoke-Expression | Dynamic/DynamicExecution.ps1:2:1:2:22 | Call to invoke-expression | +| Dynamic/DynamicExecution.ps1:2:1:2:22 | Call to invoke-expression | Dynamic/DynamicExecution.ps1:2:1:2:22 | [Stmt] Call to invoke-expression | +| Dynamic/DynamicExecution.ps1:2:1:2:22 | [Stmt] Call to invoke-expression | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | +| Dynamic/DynamicExecution.ps1:2:19:2:22 | foo | Dynamic/DynamicExecution.ps1:2:1:2:22 | Call to invoke-expression | +| Dynamic/DynamicExecution.ps1:3:1:3:13 | scriptblock | Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to create | +| Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to create | Dynamic/DynamicExecution.ps1:3:1:3:27 | [Stmt] Call to create | +| Dynamic/DynamicExecution.ps1:3:1:3:27 | [Stmt] Call to create | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | +| Dynamic/DynamicExecution.ps1:3:16:3:21 | Create | Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to create | +| Dynamic/DynamicExecution.ps1:3:23:3:26 | foo | Dynamic/DynamicExecution.ps1:3:1:3:27 | Call to create | | Dynamic/DynamicExecution.ps1:4:1:4:31 | Call to | Dynamic/DynamicExecution.ps1:4:1:4:31 | [Stmt] Call to | | Dynamic/DynamicExecution.ps1:4:1:4:31 | [Stmt] Call to | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | | Dynamic/DynamicExecution.ps1:4:3:4:31 | (...) | Dynamic/DynamicExecution.ps1:4:1:4:31 | Call to | -| Dynamic/DynamicExecution.ps1:4:4:4:16 | scriptblock | Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to Create | -| Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to Create | Dynamic/DynamicExecution.ps1:4:3:4:31 | (...) | -| Dynamic/DynamicExecution.ps1:4:19:4:24 | Create | Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to Create | -| Dynamic/DynamicExecution.ps1:4:26:4:29 | foo | Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to Create | +| Dynamic/DynamicExecution.ps1:4:4:4:16 | scriptblock | Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to create | +| Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to create | Dynamic/DynamicExecution.ps1:4:3:4:31 | (...) | +| Dynamic/DynamicExecution.ps1:4:19:4:24 | Create | Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to create | +| Dynamic/DynamicExecution.ps1:4:26:4:29 | foo | Dynamic/DynamicExecution.ps1:4:4:4:30 | Call to create | | Dynamic/DynamicExecution.ps1:5:1:5:7 | Call to | Dynamic/DynamicExecution.ps1:5:1:5:7 | [Stmt] Call to | | Dynamic/DynamicExecution.ps1:5:1:5:7 | [Stmt] Call to | Dynamic/DynamicExecution.ps1:1:1:5:7 | {...} | | Dynamic/DynamicExecution.ps1:5:2:5:7 | $foo | Dynamic/DynamicExecution.ps1:5:1:5:7 | Call to | @@ -156,29 +156,29 @@ | Dynamic/DynamicExecutionWithFunc.ps1:1:24:11:1 | [synth] pipeline | Dynamic/DynamicExecutionWithFunc.ps1:1:24:11:1 | {...} | | Dynamic/DynamicExecutionWithFunc.ps1:1:24:11:1 | {...} | Dynamic/DynamicExecutionWithFunc.ps1:1:1:11:1 | ExecuteAThing | | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | Dynamic/DynamicExecutionWithFunc.ps1:1:24:11:1 | {...} | -| Dynamic/DynamicExecutionWithFunc.ps1:3:9:3:18 | userInput | Dynamic/DynamicExecutionWithFunc.ps1:1:24:11:1 | {...} | +| Dynamic/DynamicExecutionWithFunc.ps1:3:9:3:18 | userinput | Dynamic/DynamicExecutionWithFunc.ps1:1:24:11:1 | {...} | | Dynamic/DynamicExecutionWithFunc.ps1:5:5:5:8 | foo | Dynamic/DynamicExecutionWithFunc.ps1:1:24:11:1 | {...} | | Dynamic/DynamicExecutionWithFunc.ps1:5:5:5:8 | foo | Dynamic/DynamicExecutionWithFunc.ps1:5:5:5:33 | ...=... | | Dynamic/DynamicExecutionWithFunc.ps1:5:5:5:33 | ...=... | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | | Dynamic/DynamicExecutionWithFunc.ps1:5:12:5:20 | cmd.exe | Dynamic/DynamicExecutionWithFunc.ps1:5:12:5:33 | ...+... | | Dynamic/DynamicExecutionWithFunc.ps1:5:12:5:33 | ...+... | Dynamic/DynamicExecutionWithFunc.ps1:5:5:5:33 | ...=... | | Dynamic/DynamicExecutionWithFunc.ps1:5:24:5:33 | userInput | Dynamic/DynamicExecutionWithFunc.ps1:5:12:5:33 | ...+... | -| Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:21 | Invoke-Expression | Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | Call to Invoke-Expression | -| Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | Call to Invoke-Expression | Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | [Stmt] Call to Invoke-Expression | -| Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | [Stmt] Call to Invoke-Expression | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | -| Dynamic/DynamicExecutionWithFunc.ps1:6:23:6:26 | foo | Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | Call to Invoke-Expression | -| Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:17 | scriptblock | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to Create | -| Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to Create | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | [Stmt] Call to Create | -| Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | [Stmt] Call to Create | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | -| Dynamic/DynamicExecutionWithFunc.ps1:7:20:7:25 | Create | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to Create | -| Dynamic/DynamicExecutionWithFunc.ps1:7:27:7:30 | foo | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to Create | +| Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:21 | Invoke-Expression | Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | Call to invoke-expression | +| Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | Call to invoke-expression | Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | [Stmt] Call to invoke-expression | +| Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | [Stmt] Call to invoke-expression | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | +| Dynamic/DynamicExecutionWithFunc.ps1:6:23:6:26 | foo | Dynamic/DynamicExecutionWithFunc.ps1:6:5:6:26 | Call to invoke-expression | +| Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:17 | scriptblock | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to create | +| Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to create | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | [Stmt] Call to create | +| Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | [Stmt] Call to create | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | +| Dynamic/DynamicExecutionWithFunc.ps1:7:20:7:25 | Create | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to create | +| Dynamic/DynamicExecutionWithFunc.ps1:7:27:7:30 | foo | Dynamic/DynamicExecutionWithFunc.ps1:7:5:7:31 | Call to create | | Dynamic/DynamicExecutionWithFunc.ps1:8:5:8:35 | Call to | Dynamic/DynamicExecutionWithFunc.ps1:8:5:8:35 | [Stmt] Call to | | Dynamic/DynamicExecutionWithFunc.ps1:8:5:8:35 | [Stmt] Call to | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | | Dynamic/DynamicExecutionWithFunc.ps1:8:7:8:35 | (...) | Dynamic/DynamicExecutionWithFunc.ps1:8:5:8:35 | Call to | -| Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:20 | scriptblock | Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to Create | -| Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to Create | Dynamic/DynamicExecutionWithFunc.ps1:8:7:8:35 | (...) | -| Dynamic/DynamicExecutionWithFunc.ps1:8:23:8:28 | Create | Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to Create | -| Dynamic/DynamicExecutionWithFunc.ps1:8:30:8:33 | foo | Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to Create | +| Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:20 | scriptblock | Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to create | +| Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to create | Dynamic/DynamicExecutionWithFunc.ps1:8:7:8:35 | (...) | +| Dynamic/DynamicExecutionWithFunc.ps1:8:23:8:28 | Create | Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to create | +| Dynamic/DynamicExecutionWithFunc.ps1:8:30:8:33 | foo | Dynamic/DynamicExecutionWithFunc.ps1:8:8:8:34 | Call to create | | Dynamic/DynamicExecutionWithFunc.ps1:9:5:9:11 | Call to | Dynamic/DynamicExecutionWithFunc.ps1:9:5:9:11 | [Stmt] Call to | | Dynamic/DynamicExecutionWithFunc.ps1:9:5:9:11 | [Stmt] Call to | Dynamic/DynamicExecutionWithFunc.ps1:2:5:10:29 | {...} | | Dynamic/DynamicExecutionWithFunc.ps1:9:6:9:11 | $foo | Dynamic/DynamicExecutionWithFunc.ps1:9:5:9:11 | Call to | @@ -209,21 +209,21 @@ | Expressions/BinaryExpression.ps1:4:1:4:7 | [Stmt] result | Expressions/BinaryExpression.ps1:1:1:4:7 | {...} | | Expressions/BinaryExpression.ps1:4:1:4:7 | result | Expressions/BinaryExpression.ps1:4:1:4:7 | [Stmt] result | | Expressions/ConvertWithSecureString.ps1:1:1:1:10 | UserInput | Expressions/ConvertWithSecureString.ps1:1:1:1:54 | ...=... | -| Expressions/ConvertWithSecureString.ps1:1:1:1:10 | UserInput | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | +| Expressions/ConvertWithSecureString.ps1:1:1:1:10 | userinput | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | | Expressions/ConvertWithSecureString.ps1:1:1:1:54 | ...=... | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | toplevel function for ConvertWithSecureString.ps1 | | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | -| Expressions/ConvertWithSecureString.ps1:1:14:1:22 | Read-Host | Expressions/ConvertWithSecureString.ps1:1:14:1:54 | Call to Read-Host | -| Expressions/ConvertWithSecureString.ps1:1:14:1:54 | Call to Read-Host | Expressions/ConvertWithSecureString.ps1:1:1:1:54 | ...=... | -| Expressions/ConvertWithSecureString.ps1:1:24:1:54 | Please enter your secure code | Expressions/ConvertWithSecureString.ps1:1:14:1:54 | Call to Read-Host | -| Expressions/ConvertWithSecureString.ps1:2:1:2:15 | EncryptedInput | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | +| Expressions/ConvertWithSecureString.ps1:1:14:1:22 | Read-Host | Expressions/ConvertWithSecureString.ps1:1:14:1:54 | Call to read-host | +| Expressions/ConvertWithSecureString.ps1:1:14:1:54 | Call to read-host | Expressions/ConvertWithSecureString.ps1:1:1:1:54 | ...=... | +| Expressions/ConvertWithSecureString.ps1:1:24:1:54 | Please enter your secure code | Expressions/ConvertWithSecureString.ps1:1:14:1:54 | Call to read-host | | Expressions/ConvertWithSecureString.ps1:2:1:2:15 | EncryptedInput | Expressions/ConvertWithSecureString.ps1:2:1:2:79 | ...=... | +| Expressions/ConvertWithSecureString.ps1:2:1:2:15 | encryptedinput | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | | Expressions/ConvertWithSecureString.ps1:2:1:2:79 | ...=... | Expressions/ConvertWithSecureString.ps1:1:1:2:79 | {...} | -| Expressions/ConvertWithSecureString.ps1:2:19:2:40 | ConvertTo-SecureString | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to ConvertTo-SecureString | -| Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to ConvertTo-SecureString | Expressions/ConvertWithSecureString.ps1:2:1:2:79 | ...=... | -| Expressions/ConvertWithSecureString.ps1:2:50:2:59 | UserInput | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to ConvertTo-SecureString | -| Expressions/ConvertWithSecureString.ps1:2:61:2:72 | true | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to ConvertTo-SecureString | -| Expressions/ConvertWithSecureString.ps1:2:74:2:79 | true | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to ConvertTo-SecureString | +| Expressions/ConvertWithSecureString.ps1:2:19:2:40 | ConvertTo-SecureString | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to convertto-securestring | +| Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to convertto-securestring | Expressions/ConvertWithSecureString.ps1:2:1:2:79 | ...=... | +| Expressions/ConvertWithSecureString.ps1:2:50:2:59 | UserInput | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to convertto-securestring | +| Expressions/ConvertWithSecureString.ps1:2:61:2:72 | true | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to convertto-securestring | +| Expressions/ConvertWithSecureString.ps1:2:74:2:79 | true | Expressions/ConvertWithSecureString.ps1:2:19:2:79 | Call to convertto-securestring | | Expressions/ExpandableString.ps1:1:1:1:39 | Date: $([DateTime]::Now)\nName: $name | Expressions/ExpandableString.ps1:1:1:1:39 | [Stmt] Date: $([DateTime]::Now)\nName: $name | | Expressions/ExpandableString.ps1:1:1:1:39 | [Stmt] Date: $([DateTime]::Now)\nName: $name | Expressions/ExpandableString.ps1:1:1:1:39 | {...} | | Expressions/ExpandableString.ps1:1:1:1:39 | {...} | Expressions/ExpandableString.ps1:1:1:1:39 | toplevel function for ExpandableString.ps1 | @@ -242,25 +242,25 @@ | Expressions/MemberExpression.ps1:2:1:2:14 | ... | Expressions/MemberExpression.ps1:2:1:2:14 | [Stmt] ... | | Expressions/MemberExpression.ps1:2:1:2:14 | [Stmt] ... | Expressions/MemberExpression.ps1:1:1:2:14 | {...} | | Expressions/MemberExpression.ps1:2:13:2:14 | x | Expressions/MemberExpression.ps1:2:1:2:14 | ... | -| Expressions/SubExpression.ps1:1:1:1:11 | $(...) | Expressions/SubExpression.ps1:1:1:1:23 | Call to AddDays | -| Expressions/SubExpression.ps1:1:1:1:23 | Call to AddDays | Expressions/SubExpression.ps1:1:1:1:23 | [Stmt] Call to AddDays | -| Expressions/SubExpression.ps1:1:1:1:23 | [Stmt] Call to AddDays | Expressions/SubExpression.ps1:1:1:2:21 | {...} | +| Expressions/SubExpression.ps1:1:1:1:11 | $(...) | Expressions/SubExpression.ps1:1:1:1:23 | Call to adddays | +| Expressions/SubExpression.ps1:1:1:1:23 | Call to adddays | Expressions/SubExpression.ps1:1:1:1:23 | [Stmt] Call to adddays | +| Expressions/SubExpression.ps1:1:1:1:23 | [Stmt] Call to adddays | Expressions/SubExpression.ps1:1:1:2:21 | {...} | | Expressions/SubExpression.ps1:1:1:2:21 | {...} | Expressions/SubExpression.ps1:1:1:2:21 | toplevel function for SubExpression.ps1 | | Expressions/SubExpression.ps1:1:1:2:21 | {...} | Expressions/SubExpression.ps1:1:1:2:21 | {...} | -| Expressions/SubExpression.ps1:1:3:1:10 | Call to Get-Date | Expressions/SubExpression.ps1:1:3:1:10 | [Stmt] Call to Get-Date | -| Expressions/SubExpression.ps1:1:3:1:10 | Get-Date | Expressions/SubExpression.ps1:1:3:1:10 | Call to Get-Date | -| Expressions/SubExpression.ps1:1:3:1:10 | [Stmt] Call to Get-Date | Expressions/SubExpression.ps1:1:3:1:10 | {...} | +| Expressions/SubExpression.ps1:1:3:1:10 | Call to get-date | Expressions/SubExpression.ps1:1:3:1:10 | [Stmt] Call to get-date | +| Expressions/SubExpression.ps1:1:3:1:10 | Get-Date | Expressions/SubExpression.ps1:1:3:1:10 | Call to get-date | +| Expressions/SubExpression.ps1:1:3:1:10 | [Stmt] Call to get-date | Expressions/SubExpression.ps1:1:3:1:10 | {...} | | Expressions/SubExpression.ps1:1:3:1:10 | {...} | Expressions/SubExpression.ps1:1:1:1:11 | $(...) | -| Expressions/SubExpression.ps1:1:13:1:19 | AddDays | Expressions/SubExpression.ps1:1:1:1:23 | Call to AddDays | -| Expressions/SubExpression.ps1:1:21:1:22 | 10 | Expressions/SubExpression.ps1:1:1:1:23 | Call to AddDays | -| Expressions/SubExpression.ps1:2:1:2:11 | $(...) | Expressions/SubExpression.ps1:2:1:2:21 | Call to AddDays | -| Expressions/SubExpression.ps1:2:1:2:21 | Call to AddDays | Expressions/SubExpression.ps1:2:1:2:21 | [Stmt] Call to AddDays | -| Expressions/SubExpression.ps1:2:1:2:21 | [Stmt] Call to AddDays | Expressions/SubExpression.ps1:1:1:2:21 | {...} | -| Expressions/SubExpression.ps1:2:3:2:10 | Call to Get-Date | Expressions/SubExpression.ps1:2:3:2:10 | [Stmt] Call to Get-Date | -| Expressions/SubExpression.ps1:2:3:2:10 | Get-Date | Expressions/SubExpression.ps1:2:3:2:10 | Call to Get-Date | -| Expressions/SubExpression.ps1:2:3:2:10 | [Stmt] Call to Get-Date | Expressions/SubExpression.ps1:2:3:2:10 | {...} | +| Expressions/SubExpression.ps1:1:13:1:19 | AddDays | Expressions/SubExpression.ps1:1:1:1:23 | Call to adddays | +| Expressions/SubExpression.ps1:1:21:1:22 | 10 | Expressions/SubExpression.ps1:1:1:1:23 | Call to adddays | +| Expressions/SubExpression.ps1:2:1:2:11 | $(...) | Expressions/SubExpression.ps1:2:1:2:21 | Call to adddays | +| Expressions/SubExpression.ps1:2:1:2:21 | Call to adddays | Expressions/SubExpression.ps1:2:1:2:21 | [Stmt] Call to adddays | +| Expressions/SubExpression.ps1:2:1:2:21 | [Stmt] Call to adddays | Expressions/SubExpression.ps1:1:1:2:21 | {...} | +| Expressions/SubExpression.ps1:2:3:2:10 | Call to get-date | Expressions/SubExpression.ps1:2:3:2:10 | [Stmt] Call to get-date | +| Expressions/SubExpression.ps1:2:3:2:10 | Get-Date | Expressions/SubExpression.ps1:2:3:2:10 | Call to get-date | +| Expressions/SubExpression.ps1:2:3:2:10 | [Stmt] Call to get-date | Expressions/SubExpression.ps1:2:3:2:10 | {...} | | Expressions/SubExpression.ps1:2:3:2:10 | {...} | Expressions/SubExpression.ps1:2:1:2:11 | $(...) | -| Expressions/SubExpression.ps1:2:13:2:19 | AddDays | Expressions/SubExpression.ps1:2:1:2:21 | Call to AddDays | +| Expressions/SubExpression.ps1:2:13:2:19 | AddDays | Expressions/SubExpression.ps1:2:1:2:21 | Call to adddays | | Expressions/TernaryExpression.ps1:1:1:1:4 | var | Expressions/TernaryExpression.ps1:1:1:1:22 | ...=... | | Expressions/TernaryExpression.ps1:1:1:1:4 | var | Expressions/TernaryExpression.ps1:1:1:1:22 | {...} | | Expressions/TernaryExpression.ps1:1:1:1:22 | ...=... | Expressions/TernaryExpression.ps1:1:1:1:22 | {...} | @@ -310,15 +310,15 @@ | Loops/While.ps1:2:8:2:17 | ... -le ... | Loops/While.ps1:2:1:13:1 | while(...) {...} | | Loops/While.ps1:2:17:2:17 | 5 | Loops/While.ps1:2:8:2:17 | ... -le ... | | Loops/While.ps1:3:1:13:1 | {...} | Loops/While.ps1:2:1:13:1 | while(...) {...} | -| Loops/While.ps1:4:5:4:14 | Write-Host | Loops/While.ps1:4:5:4:40 | Call to Write-Host | -| Loops/While.ps1:4:5:4:40 | Call to Write-Host | Loops/While.ps1:4:5:4:40 | [Stmt] Call to Write-Host | -| Loops/While.ps1:4:5:4:40 | [Stmt] Call to Write-Host | Loops/While.ps1:3:1:13:1 | {...} | -| Loops/While.ps1:4:16:4:18 | The | Loops/While.ps1:4:5:4:40 | Call to Write-Host | -| Loops/While.ps1:4:20:4:24 | value | Loops/While.ps1:4:5:4:40 | Call to Write-Host | -| Loops/While.ps1:4:26:4:27 | of | Loops/While.ps1:4:5:4:40 | Call to Write-Host | -| Loops/While.ps1:4:29:4:31 | Var | Loops/While.ps1:4:5:4:40 | Call to Write-Host | -| Loops/While.ps1:4:33:4:35 | is: | Loops/While.ps1:4:5:4:40 | Call to Write-Host | -| Loops/While.ps1:4:37:4:40 | var | Loops/While.ps1:4:5:4:40 | Call to Write-Host | +| Loops/While.ps1:4:5:4:14 | Write-Host | Loops/While.ps1:4:5:4:40 | Call to write-host | +| Loops/While.ps1:4:5:4:40 | Call to write-host | Loops/While.ps1:4:5:4:40 | [Stmt] Call to write-host | +| Loops/While.ps1:4:5:4:40 | [Stmt] Call to write-host | Loops/While.ps1:3:1:13:1 | {...} | +| Loops/While.ps1:4:16:4:18 | The | Loops/While.ps1:4:5:4:40 | Call to write-host | +| Loops/While.ps1:4:20:4:24 | value | Loops/While.ps1:4:5:4:40 | Call to write-host | +| Loops/While.ps1:4:26:4:27 | of | Loops/While.ps1:4:5:4:40 | Call to write-host | +| Loops/While.ps1:4:29:4:31 | Var | Loops/While.ps1:4:5:4:40 | Call to write-host | +| Loops/While.ps1:4:33:4:35 | is: | Loops/While.ps1:4:5:4:40 | Call to write-host | +| Loops/While.ps1:4:37:4:40 | var | Loops/While.ps1:4:5:4:40 | Call to write-host | | Loops/While.ps1:5:5:5:8 | var | Loops/While.ps1:5:5:5:10 | ...++ | | Loops/While.ps1:5:5:5:10 | ...++ | Loops/While.ps1:5:5:5:10 | [Stmt] ...++ | | Loops/While.ps1:5:5:5:10 | [Stmt] ...++ | Loops/While.ps1:3:1:13:1 | {...} | @@ -335,14 +335,14 @@ | Redirections/FileRedirection.ps1:1:1:3:19 | [Stmt] $(...) | Redirections/FileRedirection.ps1:1:1:3:19 | {...} | | Redirections/FileRedirection.ps1:1:1:3:19 | {...} | Redirections/FileRedirection.ps1:1:1:3:19 | toplevel function for FileRedirection.ps1 | | Redirections/FileRedirection.ps1:1:1:3:19 | {...} | Redirections/FileRedirection.ps1:1:1:3:19 | {...} | -| Redirections/FileRedirection.ps1:2:5:2:8 | Here | Redirections/FileRedirection.ps1:2:5:2:31 | Call to Here | -| Redirections/FileRedirection.ps1:2:5:2:31 | Call to Here | Redirections/FileRedirection.ps1:2:5:2:31 | [Stmt] Call to Here | -| Redirections/FileRedirection.ps1:2:5:2:31 | [Stmt] Call to Here | Redirections/FileRedirection.ps1:2:5:2:31 | {...} | +| Redirections/FileRedirection.ps1:2:5:2:8 | Here | Redirections/FileRedirection.ps1:2:5:2:31 | Call to here | +| Redirections/FileRedirection.ps1:2:5:2:31 | Call to here | Redirections/FileRedirection.ps1:2:5:2:31 | [Stmt] Call to here | +| Redirections/FileRedirection.ps1:2:5:2:31 | [Stmt] Call to here | Redirections/FileRedirection.ps1:2:5:2:31 | {...} | | Redirections/FileRedirection.ps1:2:5:2:31 | {...} | Redirections/FileRedirection.ps1:1:1:3:1 | $(...) | -| Redirections/FileRedirection.ps1:2:10:2:11 | is | Redirections/FileRedirection.ps1:2:5:2:31 | Call to Here | -| Redirections/FileRedirection.ps1:2:13:2:16 | your | Redirections/FileRedirection.ps1:2:5:2:31 | Call to Here | -| Redirections/FileRedirection.ps1:2:18:2:24 | current | Redirections/FileRedirection.ps1:2:5:2:31 | Call to Here | -| Redirections/FileRedirection.ps1:2:26:2:31 | script | Redirections/FileRedirection.ps1:2:5:2:31 | Call to Here | +| Redirections/FileRedirection.ps1:2:10:2:11 | is | Redirections/FileRedirection.ps1:2:5:2:31 | Call to here | +| Redirections/FileRedirection.ps1:2:13:2:16 | your | Redirections/FileRedirection.ps1:2:5:2:31 | Call to here | +| Redirections/FileRedirection.ps1:2:18:2:24 | current | Redirections/FileRedirection.ps1:2:5:2:31 | Call to here | +| Redirections/FileRedirection.ps1:2:26:2:31 | script | Redirections/FileRedirection.ps1:2:5:2:31 | Call to here | | Redirections/FileRedirection.ps1:3:10:3:19 | output.txt | Redirections/FileRedirection.ps1:3:8:3:19 | FileRedirection | | Statements/ExitStatement.ps1:1:1:1:7 | exit ... | Statements/ExitStatement.ps1:1:1:1:7 | {...} | | Statements/ExitStatement.ps1:1:1:1:7 | {...} | Statements/ExitStatement.ps1:1:1:1:7 | toplevel function for ExitStatement.ps1 | @@ -378,23 +378,23 @@ | Statements/TrapStatement.ps1:2:10:2:25 | {...} | Statements/TrapStatement.ps1:2:5:2:25 | trap {...} | | Statements/TrapStatement.ps1:2:11:2:24 | Error found. | Statements/TrapStatement.ps1:2:11:2:24 | [Stmt] Error found. | | Statements/TrapStatement.ps1:2:11:2:24 | [Stmt] Error found. | Statements/TrapStatement.ps1:2:10:2:25 | {...} | -| Statements/TrapStatement.ps1:3:5:3:18 | Call to nonsenseString | Statements/TrapStatement.ps1:3:5:3:18 | [Stmt] Call to nonsenseString | -| Statements/TrapStatement.ps1:3:5:3:18 | [Stmt] Call to nonsenseString | Statements/TrapStatement.ps1:2:5:3:18 | {...} | -| Statements/TrapStatement.ps1:3:5:3:18 | nonsenseString | Statements/TrapStatement.ps1:3:5:3:18 | Call to nonsenseString | -| Statements/TrapStatement.ps1:6:1:6:8 | Call to TrapTest | Statements/TrapStatement.ps1:6:1:6:8 | [Stmt] Call to TrapTest | -| Statements/TrapStatement.ps1:6:1:6:8 | TrapTest | Statements/TrapStatement.ps1:6:1:6:8 | Call to TrapTest | -| Statements/TrapStatement.ps1:6:1:6:8 | [Stmt] Call to TrapTest | Statements/TrapStatement.ps1:1:1:6:8 | {...} | +| Statements/TrapStatement.ps1:3:5:3:18 | Call to nonsensestring | Statements/TrapStatement.ps1:3:5:3:18 | [Stmt] Call to nonsensestring | +| Statements/TrapStatement.ps1:3:5:3:18 | [Stmt] Call to nonsensestring | Statements/TrapStatement.ps1:2:5:3:18 | {...} | +| Statements/TrapStatement.ps1:3:5:3:18 | nonsenseString | Statements/TrapStatement.ps1:3:5:3:18 | Call to nonsensestring | +| Statements/TrapStatement.ps1:6:1:6:8 | Call to traptest | Statements/TrapStatement.ps1:6:1:6:8 | [Stmt] Call to traptest | +| Statements/TrapStatement.ps1:6:1:6:8 | TrapTest | Statements/TrapStatement.ps1:6:1:6:8 | Call to traptest | +| Statements/TrapStatement.ps1:6:1:6:8 | [Stmt] Call to traptest | Statements/TrapStatement.ps1:1:1:6:8 | {...} | | Statements/Try.ps1:1:1:13:1 | try {...} | Statements/Try.ps1:1:1:13:1 | {...} | | Statements/Try.ps1:1:1:13:1 | {...} | Statements/Try.ps1:1:1:13:1 | toplevel function for Try.ps1 | | Statements/Try.ps1:1:1:13:1 | {...} | Statements/Try.ps1:1:1:13:1 | {...} | | Statements/Try.ps1:1:5:4:1 | {...} | Statements/Try.ps1:1:1:13:1 | try {...} | -| Statements/Try.ps1:2:4:2:13 | Exception | Statements/Try.ps1:1:1:13:1 | {...} | | Statements/Try.ps1:2:4:2:13 | Exception | Statements/Try.ps1:2:4:2:94 | ...=... | +| Statements/Try.ps1:2:4:2:13 | exception | Statements/Try.ps1:1:1:13:1 | {...} | | Statements/Try.ps1:2:4:2:94 | ...=... | Statements/Try.ps1:1:5:4:1 | {...} | -| Statements/Try.ps1:2:17:2:26 | New-Object | Statements/Try.ps1:2:17:2:94 | Call to New-Object | -| Statements/Try.ps1:2:17:2:94 | Call to New-Object | Statements/Try.ps1:2:4:2:94 | ...=... | -| Statements/Try.ps1:2:28:2:52 | System.Xaml.XamlException | Statements/Try.ps1:2:17:2:94 | Call to New-Object | -| Statements/Try.ps1:2:68:2:94 | (...) | Statements/Try.ps1:2:17:2:94 | Call to New-Object | +| Statements/Try.ps1:2:17:2:26 | New-Object | Statements/Try.ps1:2:17:2:94 | Call to new-object | +| Statements/Try.ps1:2:17:2:94 | Call to new-object | Statements/Try.ps1:2:4:2:94 | ...=... | +| Statements/Try.ps1:2:28:2:52 | System.Xaml.XamlException | Statements/Try.ps1:2:17:2:94 | Call to new-object | +| Statements/Try.ps1:2:68:2:94 | (...) | Statements/Try.ps1:2:17:2:94 | Call to new-object | | Statements/Try.ps1:2:69:2:79 | Bad XAML! | Statements/Try.ps1:2:69:2:93 | ...,... | | Statements/Try.ps1:2:69:2:93 | ...,... | Statements/Try.ps1:2:68:2:94 | (...) | | Statements/Try.ps1:2:82:2:86 | null | Statements/Try.ps1:2:69:2:93 | ...,... | @@ -422,10 +422,10 @@ | Statements/UseProcessBlockForPipelineCommand.ps1:2:1:11:1 | {...} | Statements/UseProcessBlockForPipelineCommand.ps1:1:1:11:1 | Get-Number | | Statements/UseProcessBlockForPipelineCommand.ps1:3:5:3:21 | CmdletBinding | Statements/UseProcessBlockForPipelineCommand.ps1:2:1:11:1 | {...} | | Statements/UseProcessBlockForPipelineCommand.ps1:4:5:10:11 | {...} | Statements/UseProcessBlockForPipelineCommand.ps1:2:1:11:1 | {...} | -| Statements/UseProcessBlockForPipelineCommand.ps1:5:9:5:38 | ValueFromPipeline | Statements/UseProcessBlockForPipelineCommand.ps1:5:9:7:15 | Number | -| Statements/UseProcessBlockForPipelineCommand.ps1:5:9:7:15 | Number | Statements/UseProcessBlockForPipelineCommand.ps1:2:1:11:1 | {...} | +| Statements/UseProcessBlockForPipelineCommand.ps1:5:9:5:38 | ValueFromPipeline | Statements/UseProcessBlockForPipelineCommand.ps1:5:9:7:15 | number | +| Statements/UseProcessBlockForPipelineCommand.ps1:5:9:7:15 | number | Statements/UseProcessBlockForPipelineCommand.ps1:2:1:11:1 | {...} | | Statements/UseProcessBlockForPipelineCommand.ps1:5:20:5:36 | (no string representation) | Statements/UseProcessBlockForPipelineCommand.ps1:5:20:5:36 | ValueFromPipeline | | Statements/UseProcessBlockForPipelineCommand.ps1:5:20:5:36 | ValueFromPipeline | Statements/UseProcessBlockForPipelineCommand.ps1:5:9:5:38 | ValueFromPipeline | -| Statements/UseProcessBlockForPipelineCommand.ps1:6:9:6:13 | int | Statements/UseProcessBlockForPipelineCommand.ps1:5:9:7:15 | Number | +| Statements/UseProcessBlockForPipelineCommand.ps1:6:9:6:13 | int | Statements/UseProcessBlockForPipelineCommand.ps1:5:9:7:15 | number | | Statements/UseProcessBlockForPipelineCommand.ps1:10:5:10:11 | Number | Statements/UseProcessBlockForPipelineCommand.ps1:10:5:10:11 | [Stmt] Number | | Statements/UseProcessBlockForPipelineCommand.ps1:10:5:10:11 | [Stmt] Number | Statements/UseProcessBlockForPipelineCommand.ps1:4:5:10:11 | {...} | diff --git a/powershell/ql/test/library-tests/controlflow/graph/Cfg.expected b/powershell/ql/test/library-tests/controlflow/graph/Cfg.expected index ad0746a58c49..cb4d46fc73ca 100644 --- a/powershell/ql/test/library-tests/controlflow/graph/Cfg.expected +++ b/powershell/ql/test/library-tests/controlflow/graph/Cfg.expected @@ -6,9 +6,9 @@ | conditionals.ps1:1:18:9:1 | [synth] pipeline | conditionals.ps1:2:5:8:13 | {...} | | | conditionals.ps1:1:18:9:1 | enter {...} | conditionals.ps1:1:18:9:1 | {...} | | | conditionals.ps1:1:18:9:1 | exit {...} (normal) | conditionals.ps1:1:18:9:1 | exit {...} | | -| conditionals.ps1:1:18:9:1 | {...} | conditionals.ps1:2:11:2:17 | myBool | | +| conditionals.ps1:1:18:9:1 | {...} | conditionals.ps1:2:11:2:17 | mybool | | | conditionals.ps1:2:5:8:13 | {...} | conditionals.ps1:4:5:7:5 | [Stmt] if (...) {...} | | -| conditionals.ps1:2:11:2:17 | myBool | conditionals.ps1:1:18:9:1 | [synth] pipeline | | +| conditionals.ps1:2:11:2:17 | mybool | conditionals.ps1:1:18:9:1 | [synth] pipeline | | | conditionals.ps1:4:5:7:5 | [Stmt] if (...) {...} | conditionals.ps1:4:8:4:14 | myBool | | | conditionals.ps1:4:5:7:5 | if (...) {...} | conditionals.ps1:8:5:8:13 | return ... | | | conditionals.ps1:4:8:4:14 | myBool | conditionals.ps1:4:5:7:5 | if (...) {...} | false | @@ -22,9 +22,9 @@ | conditionals.ps1:11:23:22:1 | [synth] pipeline | conditionals.ps1:12:5:21:5 | {...} | | | conditionals.ps1:11:23:22:1 | enter {...} | conditionals.ps1:11:23:22:1 | {...} | | | conditionals.ps1:11:23:22:1 | exit {...} (normal) | conditionals.ps1:11:23:22:1 | exit {...} | | -| conditionals.ps1:11:23:22:1 | {...} | conditionals.ps1:12:11:12:17 | myBool | | +| conditionals.ps1:11:23:22:1 | {...} | conditionals.ps1:12:11:12:17 | mybool | | | conditionals.ps1:12:5:21:5 | {...} | conditionals.ps1:14:5:21:5 | [Stmt] if (...) {...} else {...} | | -| conditionals.ps1:12:11:12:17 | myBool | conditionals.ps1:11:23:22:1 | [synth] pipeline | | +| conditionals.ps1:12:11:12:17 | mybool | conditionals.ps1:11:23:22:1 | [synth] pipeline | | | conditionals.ps1:14:5:21:5 | [Stmt] if (...) {...} else {...} | conditionals.ps1:14:8:14:14 | myBool | | | conditionals.ps1:14:5:21:5 | if (...) {...} else {...} | conditionals.ps1:11:23:22:1 | exit {...} (normal) | | | conditionals.ps1:14:8:14:14 | myBool | conditionals.ps1:15:5:17:5 | {...} | true | @@ -39,10 +39,10 @@ | conditionals.ps1:24:23:32:1 | [synth] pipeline | conditionals.ps1:25:5:31:13 | {...} | | | conditionals.ps1:24:23:32:1 | enter {...} | conditionals.ps1:24:23:32:1 | {...} | | | conditionals.ps1:24:23:32:1 | exit {...} (normal) | conditionals.ps1:24:23:32:1 | exit {...} | | -| conditionals.ps1:24:23:32:1 | {...} | conditionals.ps1:25:11:25:18 | myBool1 | | +| conditionals.ps1:24:23:32:1 | {...} | conditionals.ps1:25:11:25:18 | mybool1 | | | conditionals.ps1:25:5:31:13 | {...} | conditionals.ps1:27:5:30:5 | [Stmt] if (...) {...} | | -| conditionals.ps1:25:11:25:18 | myBool1 | conditionals.ps1:25:21:25:28 | myBool2 | | -| conditionals.ps1:25:21:25:28 | myBool2 | conditionals.ps1:24:23:32:1 | [synth] pipeline | | +| conditionals.ps1:25:11:25:18 | mybool1 | conditionals.ps1:25:21:25:28 | mybool2 | | +| conditionals.ps1:25:21:25:28 | mybool2 | conditionals.ps1:24:23:32:1 | [synth] pipeline | | | conditionals.ps1:27:5:30:5 | [Stmt] if (...) {...} | conditionals.ps1:27:8:27:15 | myBool1 | | | conditionals.ps1:27:5:30:5 | if (...) {...} | conditionals.ps1:31:5:31:13 | return ... | | | conditionals.ps1:27:8:27:15 | myBool1 | conditionals.ps1:27:22:27:29 | myBool2 | false, true | @@ -59,10 +59,10 @@ | conditionals.ps1:34:28:45:1 | [synth] pipeline | conditionals.ps1:35:5:44:5 | {...} | | | conditionals.ps1:34:28:45:1 | enter {...} | conditionals.ps1:34:28:45:1 | {...} | | | conditionals.ps1:34:28:45:1 | exit {...} (normal) | conditionals.ps1:34:28:45:1 | exit {...} | | -| conditionals.ps1:34:28:45:1 | {...} | conditionals.ps1:35:11:35:18 | myBool1 | | +| conditionals.ps1:34:28:45:1 | {...} | conditionals.ps1:35:11:35:18 | mybool1 | | | conditionals.ps1:35:5:44:5 | {...} | conditionals.ps1:37:5:44:5 | [Stmt] if (...) {...} else {...} | | -| conditionals.ps1:35:11:35:18 | myBool1 | conditionals.ps1:35:21:35:28 | myBool2 | | -| conditionals.ps1:35:21:35:28 | myBool2 | conditionals.ps1:34:28:45:1 | [synth] pipeline | | +| conditionals.ps1:35:11:35:18 | mybool1 | conditionals.ps1:35:21:35:28 | mybool2 | | +| conditionals.ps1:35:21:35:28 | mybool2 | conditionals.ps1:34:28:45:1 | [synth] pipeline | | | conditionals.ps1:37:5:44:5 | [Stmt] if (...) {...} else {...} | conditionals.ps1:37:8:37:15 | myBool1 | | | conditionals.ps1:37:5:44:5 | if (...) {...} else {...} | conditionals.ps1:34:28:45:1 | exit {...} (normal) | | | conditionals.ps1:37:8:37:15 | myBool1 | conditionals.ps1:37:22:37:29 | myBool2 | false, true | @@ -80,10 +80,10 @@ | conditionals.ps1:47:23:55:1 | [synth] pipeline | conditionals.ps1:48:5:54:13 | {...} | | | conditionals.ps1:47:23:55:1 | enter {...} | conditionals.ps1:47:23:55:1 | {...} | | | conditionals.ps1:47:23:55:1 | exit {...} (normal) | conditionals.ps1:47:23:55:1 | exit {...} | | -| conditionals.ps1:47:23:55:1 | {...} | conditionals.ps1:48:11:48:18 | myBool1 | | +| conditionals.ps1:47:23:55:1 | {...} | conditionals.ps1:48:11:48:18 | mybool1 | | | conditionals.ps1:48:5:54:13 | {...} | conditionals.ps1:50:5:53:5 | [Stmt] if (...) {...} | | -| conditionals.ps1:48:11:48:18 | myBool1 | conditionals.ps1:48:21:48:28 | myBool2 | | -| conditionals.ps1:48:21:48:28 | myBool2 | conditionals.ps1:47:23:55:1 | [synth] pipeline | | +| conditionals.ps1:48:11:48:18 | mybool1 | conditionals.ps1:48:21:48:28 | mybool2 | | +| conditionals.ps1:48:21:48:28 | mybool2 | conditionals.ps1:47:23:55:1 | [synth] pipeline | | | conditionals.ps1:50:5:53:5 | [Stmt] if (...) {...} | conditionals.ps1:50:8:50:15 | myBool1 | | | conditionals.ps1:50:5:53:5 | if (...) {...} | conditionals.ps1:54:5:54:13 | return ... | | | conditionals.ps1:50:8:50:15 | myBool1 | conditionals.ps1:50:21:50:28 | myBool2 | false, true | @@ -100,10 +100,10 @@ | conditionals.ps1:57:28:68:1 | [synth] pipeline | conditionals.ps1:58:5:67:5 | {...} | | | conditionals.ps1:57:28:68:1 | enter {...} | conditionals.ps1:57:28:68:1 | {...} | | | conditionals.ps1:57:28:68:1 | exit {...} (normal) | conditionals.ps1:57:28:68:1 | exit {...} | | -| conditionals.ps1:57:28:68:1 | {...} | conditionals.ps1:58:11:58:18 | myBool1 | | +| conditionals.ps1:57:28:68:1 | {...} | conditionals.ps1:58:11:58:18 | mybool1 | | | conditionals.ps1:58:5:67:5 | {...} | conditionals.ps1:60:5:67:5 | [Stmt] if (...) {...} else {...} | | -| conditionals.ps1:58:11:58:18 | myBool1 | conditionals.ps1:58:21:58:28 | myBool2 | | -| conditionals.ps1:58:21:58:28 | myBool2 | conditionals.ps1:57:28:68:1 | [synth] pipeline | | +| conditionals.ps1:58:11:58:18 | mybool1 | conditionals.ps1:58:21:58:28 | mybool2 | | +| conditionals.ps1:58:21:58:28 | mybool2 | conditionals.ps1:57:28:68:1 | [synth] pipeline | | | conditionals.ps1:60:5:67:5 | [Stmt] if (...) {...} else {...} | conditionals.ps1:60:8:60:15 | myBool1 | | | conditionals.ps1:60:5:67:5 | if (...) {...} else {...} | conditionals.ps1:57:28:68:1 | exit {...} (normal) | | | conditionals.ps1:60:8:60:15 | myBool1 | conditionals.ps1:60:21:60:28 | myBool2 | false, true | @@ -121,10 +121,10 @@ | conditionals.ps1:70:23:82:1 | [synth] pipeline | conditionals.ps1:71:5:81:13 | {...} | | | conditionals.ps1:70:23:82:1 | enter {...} | conditionals.ps1:70:23:82:1 | {...} | | | conditionals.ps1:70:23:82:1 | exit {...} (normal) | conditionals.ps1:70:23:82:1 | exit {...} | | -| conditionals.ps1:70:23:82:1 | {...} | conditionals.ps1:71:11:71:18 | myBool1 | | +| conditionals.ps1:70:23:82:1 | {...} | conditionals.ps1:71:11:71:18 | mybool1 | | | conditionals.ps1:71:5:81:13 | {...} | conditionals.ps1:73:5:80:5 | [Stmt] if (...) {...} | | -| conditionals.ps1:71:11:71:18 | myBool1 | conditionals.ps1:71:21:71:28 | myBool2 | | -| conditionals.ps1:71:21:71:28 | myBool2 | conditionals.ps1:70:23:82:1 | [synth] pipeline | | +| conditionals.ps1:71:11:71:18 | mybool1 | conditionals.ps1:71:21:71:28 | mybool2 | | +| conditionals.ps1:71:21:71:28 | mybool2 | conditionals.ps1:70:23:82:1 | [synth] pipeline | | | conditionals.ps1:73:5:80:5 | [Stmt] if (...) {...} | conditionals.ps1:73:8:73:15 | myBool1 | | | conditionals.ps1:73:5:80:5 | if (...) {...} | conditionals.ps1:81:5:81:13 | return ... | | | conditionals.ps1:73:8:73:15 | myBool1 | conditionals.ps1:73:5:80:5 | if (...) {...} | false | @@ -138,10 +138,10 @@ | conditionals.ps1:84:28:99:1 | [synth] pipeline | conditionals.ps1:85:5:98:5 | {...} | | | conditionals.ps1:84:28:99:1 | enter {...} | conditionals.ps1:84:28:99:1 | {...} | | | conditionals.ps1:84:28:99:1 | exit {...} (normal) | conditionals.ps1:84:28:99:1 | exit {...} | | -| conditionals.ps1:84:28:99:1 | {...} | conditionals.ps1:85:11:85:18 | myBool1 | | +| conditionals.ps1:84:28:99:1 | {...} | conditionals.ps1:85:11:85:18 | mybool1 | | | conditionals.ps1:85:5:98:5 | {...} | conditionals.ps1:87:5:98:5 | [Stmt] if (...) {...} else {...} | | -| conditionals.ps1:85:11:85:18 | myBool1 | conditionals.ps1:85:21:85:28 | myBool2 | | -| conditionals.ps1:85:21:85:28 | myBool2 | conditionals.ps1:84:28:99:1 | [synth] pipeline | | +| conditionals.ps1:85:11:85:18 | mybool1 | conditionals.ps1:85:21:85:28 | mybool2 | | +| conditionals.ps1:85:21:85:28 | mybool2 | conditionals.ps1:84:28:99:1 | [synth] pipeline | | | conditionals.ps1:87:5:98:5 | [Stmt] if (...) {...} else {...} | conditionals.ps1:87:8:87:15 | myBool1 | | | conditionals.ps1:87:5:98:5 | if (...) {...} else {...} | conditionals.ps1:84:28:99:1 | exit {...} (normal) | | | conditionals.ps1:87:8:87:15 | myBool1 | conditionals.ps1:88:5:90:5 | {...} | true | @@ -202,11 +202,11 @@ | conditionals.ps1:115:21:115:21 | 2 | conditionals.ps1:110:34:121:1 | exit {...} (normal) | | | conditionals.ps1:116:9:116:16 | default: | conditionals.ps1:110:34:121:1 | exit {...} (normal) | false | | conditionals.ps1:116:9:116:16 | default: | conditionals.ps1:116:18:119:9 | {...} | true | -| conditionals.ps1:116:18:119:9 | {...} | conditionals.ps1:117:13:117:33 | [Stmt] Call to Write-Output | | +| conditionals.ps1:116:18:119:9 | {...} | conditionals.ps1:117:13:117:33 | [Stmt] Call to write-output | | | conditionals.ps1:117:13:117:24 | Write-Output | conditionals.ps1:117:26:117:33 | Error! | | -| conditionals.ps1:117:13:117:33 | Call to Write-Output | conditionals.ps1:118:13:118:20 | return ... | | -| conditionals.ps1:117:13:117:33 | [Stmt] Call to Write-Output | conditionals.ps1:117:13:117:24 | Write-Output | | -| conditionals.ps1:117:26:117:33 | Error! | conditionals.ps1:117:13:117:33 | Call to Write-Output | | +| conditionals.ps1:117:13:117:33 | Call to write-output | conditionals.ps1:118:13:118:20 | return ... | | +| conditionals.ps1:117:13:117:33 | [Stmt] Call to write-output | conditionals.ps1:117:13:117:24 | Write-Output | | +| conditionals.ps1:117:26:117:33 | Error! | conditionals.ps1:117:13:117:33 | Call to write-output | | | conditionals.ps1:118:13:118:20 | return ... | conditionals.ps1:118:20:118:20 | 3 | | | conditionals.ps1:118:20:118:20 | 3 | conditionals.ps1:110:34:121:1 | exit {...} (normal) | | | conditionals.ps1:123:1:129:1 | def of test-switch-assign | conditionals.ps1:1:1:129:1 | exit {...} (normal) | | @@ -498,11 +498,11 @@ | try.ps1:1:25:8:1 | {...} | try.ps1:1:25:8:1 | [synth] pipeline | | | try.ps1:2:5:6:5 | try {...} | try.ps1:2:9:4:5 | {...} | | | try.ps1:2:5:7:12 | {...} | try.ps1:2:5:6:5 | try {...} | | -| try.ps1:2:9:4:5 | {...} | try.ps1:3:9:3:29 | [Stmt] Call to Write-Output | | +| try.ps1:2:9:4:5 | {...} | try.ps1:3:9:3:29 | [Stmt] Call to write-output | | | try.ps1:3:9:3:20 | Write-Output | try.ps1:3:22:3:29 | Hello! | | -| try.ps1:3:9:3:29 | Call to Write-Output | try.ps1:7:5:7:12 | return ... | | -| try.ps1:3:9:3:29 | [Stmt] Call to Write-Output | try.ps1:3:9:3:20 | Write-Output | | -| try.ps1:3:22:3:29 | Hello! | try.ps1:3:9:3:29 | Call to Write-Output | | +| try.ps1:3:9:3:29 | Call to write-output | try.ps1:7:5:7:12 | return ... | | +| try.ps1:3:9:3:29 | [Stmt] Call to write-output | try.ps1:3:9:3:20 | Write-Output | | +| try.ps1:3:22:3:29 | Hello! | try.ps1:3:9:3:29 | Call to write-output | | | try.ps1:7:5:7:12 | return ... | try.ps1:7:12:7:12 | 1 | | | try.ps1:7:12:7:12 | 1 | try.ps1:1:25:8:1 | exit {...} (normal) | | | try.ps1:10:1:19:1 | def of test-try-with-throw-catch | try.ps1:21:1:30:1 | def of test-try-with-throw-catch-with-throw | | @@ -566,11 +566,11 @@ | try.ps1:43:36:50:1 | {...} | try.ps1:43:36:50:1 | [synth] pipeline | | | try.ps1:44:5:48:5 | try {...} | try.ps1:44:9:46:5 | {...} | | | try.ps1:44:5:49:12 | {...} | try.ps1:44:5:48:5 | try {...} | | -| try.ps1:44:9:46:5 | {...} | try.ps1:45:9:45:29 | [Stmt] Call to Write-Output | | +| try.ps1:44:9:46:5 | {...} | try.ps1:45:9:45:29 | [Stmt] Call to write-output | | | try.ps1:45:9:45:20 | Write-Output | try.ps1:45:22:45:29 | Hello! | | -| try.ps1:45:9:45:29 | Call to Write-Output | try.ps1:49:5:49:12 | return ... | | -| try.ps1:45:9:45:29 | [Stmt] Call to Write-Output | try.ps1:45:9:45:20 | Write-Output | | -| try.ps1:45:22:45:29 | Hello! | try.ps1:45:9:45:29 | Call to Write-Output | | +| try.ps1:45:9:45:29 | Call to write-output | try.ps1:49:5:49:12 | return ... | | +| try.ps1:45:9:45:29 | [Stmt] Call to write-output | try.ps1:45:9:45:20 | Write-Output | | +| try.ps1:45:22:45:29 | Hello! | try.ps1:45:9:45:29 | Call to write-output | | | try.ps1:49:5:49:12 | return ... | try.ps1:49:12:49:12 | 1 | | | try.ps1:49:12:49:12 | 1 | try.ps1:43:36:50:1 | exit {...} (normal) | | | try.ps1:52:1:59:1 | def of test-try-catch-specific-1 | try.ps1:61:1:70:1 | def of test-try-two-catch-specific-1 | | @@ -580,11 +580,11 @@ | try.ps1:52:36:59:1 | {...} | try.ps1:52:36:59:1 | [synth] pipeline | | | try.ps1:53:5:57:5 | try {...} | try.ps1:53:9:55:5 | {...} | | | try.ps1:53:5:58:12 | {...} | try.ps1:53:5:57:5 | try {...} | | -| try.ps1:53:9:55:5 | {...} | try.ps1:54:9:54:29 | [Stmt] Call to Write-Output | | +| try.ps1:53:9:55:5 | {...} | try.ps1:54:9:54:29 | [Stmt] Call to write-output | | | try.ps1:54:9:54:20 | Write-Output | try.ps1:54:22:54:29 | Hello! | | -| try.ps1:54:9:54:29 | Call to Write-Output | try.ps1:58:5:58:12 | return ... | | -| try.ps1:54:9:54:29 | [Stmt] Call to Write-Output | try.ps1:54:9:54:20 | Write-Output | | -| try.ps1:54:22:54:29 | Hello! | try.ps1:54:9:54:29 | Call to Write-Output | | +| try.ps1:54:9:54:29 | Call to write-output | try.ps1:58:5:58:12 | return ... | | +| try.ps1:54:9:54:29 | [Stmt] Call to write-output | try.ps1:54:9:54:20 | Write-Output | | +| try.ps1:54:22:54:29 | Hello! | try.ps1:54:9:54:29 | Call to write-output | | | try.ps1:58:5:58:12 | return ... | try.ps1:58:12:58:12 | 1 | | | try.ps1:58:12:58:12 | 1 | try.ps1:52:36:59:1 | exit {...} (normal) | | | try.ps1:61:1:70:1 | def of test-try-two-catch-specific-1 | try.ps1:72:1:79:1 | def of test-try-catch-specific-2 | | @@ -594,11 +594,11 @@ | try.ps1:61:40:70:1 | {...} | try.ps1:61:40:70:1 | [synth] pipeline | | | try.ps1:62:5:68:5 | try {...} | try.ps1:62:9:64:5 | {...} | | | try.ps1:62:5:69:12 | {...} | try.ps1:62:5:68:5 | try {...} | | -| try.ps1:62:9:64:5 | {...} | try.ps1:63:9:63:29 | [Stmt] Call to Write-Output | | +| try.ps1:62:9:64:5 | {...} | try.ps1:63:9:63:29 | [Stmt] Call to write-output | | | try.ps1:63:9:63:20 | Write-Output | try.ps1:63:22:63:29 | Hello! | | -| try.ps1:63:9:63:29 | Call to Write-Output | try.ps1:69:5:69:12 | return ... | | -| try.ps1:63:9:63:29 | [Stmt] Call to Write-Output | try.ps1:63:9:63:20 | Write-Output | | -| try.ps1:63:22:63:29 | Hello! | try.ps1:63:9:63:29 | Call to Write-Output | | +| try.ps1:63:9:63:29 | Call to write-output | try.ps1:69:5:69:12 | return ... | | +| try.ps1:63:9:63:29 | [Stmt] Call to write-output | try.ps1:63:9:63:20 | Write-Output | | +| try.ps1:63:22:63:29 | Hello! | try.ps1:63:9:63:29 | Call to write-output | | | try.ps1:69:5:69:12 | return ... | try.ps1:69:12:69:12 | 2 | | | try.ps1:69:12:69:12 | 2 | try.ps1:61:40:70:1 | exit {...} (normal) | | | try.ps1:72:1:79:1 | def of test-try-catch-specific-2 | try.ps1:81:1:90:1 | def of test-try-two-catch-specific-2 | | @@ -608,11 +608,11 @@ | try.ps1:72:36:79:1 | {...} | try.ps1:72:36:79:1 | [synth] pipeline | | | try.ps1:73:5:77:5 | try {...} | try.ps1:73:9:75:5 | {...} | | | try.ps1:73:5:78:12 | {...} | try.ps1:73:5:77:5 | try {...} | | -| try.ps1:73:9:75:5 | {...} | try.ps1:74:9:74:29 | [Stmt] Call to Write-Output | | +| try.ps1:73:9:75:5 | {...} | try.ps1:74:9:74:29 | [Stmt] Call to write-output | | | try.ps1:74:9:74:20 | Write-Output | try.ps1:74:22:74:29 | Hello! | | -| try.ps1:74:9:74:29 | Call to Write-Output | try.ps1:78:5:78:12 | return ... | | -| try.ps1:74:9:74:29 | [Stmt] Call to Write-Output | try.ps1:74:9:74:20 | Write-Output | | -| try.ps1:74:22:74:29 | Hello! | try.ps1:74:9:74:29 | Call to Write-Output | | +| try.ps1:74:9:74:29 | Call to write-output | try.ps1:78:5:78:12 | return ... | | +| try.ps1:74:9:74:29 | [Stmt] Call to write-output | try.ps1:74:9:74:20 | Write-Output | | +| try.ps1:74:22:74:29 | Hello! | try.ps1:74:9:74:29 | Call to write-output | | | try.ps1:78:5:78:12 | return ... | try.ps1:78:12:78:12 | 1 | | | try.ps1:78:12:78:12 | 1 | try.ps1:72:36:79:1 | exit {...} (normal) | | | try.ps1:81:1:90:1 | def of test-try-two-catch-specific-2 | try.ps1:92:1:103:1 | def of test-try-three-catch-specific-2 | | @@ -622,11 +622,11 @@ | try.ps1:81:40:90:1 | {...} | try.ps1:81:40:90:1 | [synth] pipeline | | | try.ps1:82:5:88:5 | try {...} | try.ps1:82:9:84:5 | {...} | | | try.ps1:82:5:89:12 | {...} | try.ps1:82:5:88:5 | try {...} | | -| try.ps1:82:9:84:5 | {...} | try.ps1:83:9:83:29 | [Stmt] Call to Write-Output | | +| try.ps1:82:9:84:5 | {...} | try.ps1:83:9:83:29 | [Stmt] Call to write-output | | | try.ps1:83:9:83:20 | Write-Output | try.ps1:83:22:83:29 | Hello! | | -| try.ps1:83:9:83:29 | Call to Write-Output | try.ps1:89:5:89:12 | return ... | | -| try.ps1:83:9:83:29 | [Stmt] Call to Write-Output | try.ps1:83:9:83:20 | Write-Output | | -| try.ps1:83:22:83:29 | Hello! | try.ps1:83:9:83:29 | Call to Write-Output | | +| try.ps1:83:9:83:29 | Call to write-output | try.ps1:89:5:89:12 | return ... | | +| try.ps1:83:9:83:29 | [Stmt] Call to write-output | try.ps1:83:9:83:20 | Write-Output | | +| try.ps1:83:22:83:29 | Hello! | try.ps1:83:9:83:29 | Call to write-output | | | try.ps1:89:5:89:12 | return ... | try.ps1:89:12:89:12 | 2 | | | try.ps1:89:12:89:12 | 2 | try.ps1:81:40:90:1 | exit {...} (normal) | | | try.ps1:92:1:103:1 | def of test-try-three-catch-specific-2 | try.ps1:105:1:114:1 | def of test-try-catch-finally | | @@ -636,11 +636,11 @@ | try.ps1:92:42:103:1 | {...} | try.ps1:92:42:103:1 | [synth] pipeline | | | try.ps1:93:5:101:5 | try {...} | try.ps1:93:9:95:5 | {...} | | | try.ps1:93:5:102:12 | {...} | try.ps1:93:5:101:5 | try {...} | | -| try.ps1:93:9:95:5 | {...} | try.ps1:94:9:94:29 | [Stmt] Call to Write-Output | | +| try.ps1:93:9:95:5 | {...} | try.ps1:94:9:94:29 | [Stmt] Call to write-output | | | try.ps1:94:9:94:20 | Write-Output | try.ps1:94:22:94:29 | Hello! | | -| try.ps1:94:9:94:29 | Call to Write-Output | try.ps1:102:5:102:12 | return ... | | -| try.ps1:94:9:94:29 | [Stmt] Call to Write-Output | try.ps1:94:9:94:20 | Write-Output | | -| try.ps1:94:22:94:29 | Hello! | try.ps1:94:9:94:29 | Call to Write-Output | | +| try.ps1:94:9:94:29 | Call to write-output | try.ps1:102:5:102:12 | return ... | | +| try.ps1:94:9:94:29 | [Stmt] Call to write-output | try.ps1:94:9:94:20 | Write-Output | | +| try.ps1:94:22:94:29 | Hello! | try.ps1:94:9:94:29 | Call to write-output | | | try.ps1:102:5:102:12 | return ... | try.ps1:102:12:102:12 | 3 | | | try.ps1:102:12:102:12 | 3 | try.ps1:92:42:103:1 | exit {...} (normal) | | | try.ps1:105:1:114:1 | def of test-try-catch-finally | try.ps1:116:1:123:1 | def of test-try-finally | | @@ -650,16 +650,16 @@ | try.ps1:105:33:114:1 | {...} | try.ps1:105:33:114:1 | [synth] pipeline | | | try.ps1:106:5:112:5 | try {...} | try.ps1:106:9:108:5 | {...} | | | try.ps1:106:5:113:12 | {...} | try.ps1:106:5:112:5 | try {...} | | -| try.ps1:106:9:108:5 | {...} | try.ps1:107:9:107:29 | [Stmt] Call to Write-Output | | +| try.ps1:106:9:108:5 | {...} | try.ps1:107:9:107:29 | [Stmt] Call to write-output | | | try.ps1:107:9:107:20 | Write-Output | try.ps1:107:22:107:29 | Hello! | | -| try.ps1:107:9:107:29 | Call to Write-Output | try.ps1:110:15:112:5 | {...} | | -| try.ps1:107:9:107:29 | [Stmt] Call to Write-Output | try.ps1:107:9:107:20 | Write-Output | | -| try.ps1:107:22:107:29 | Hello! | try.ps1:107:9:107:29 | Call to Write-Output | | -| try.ps1:110:15:112:5 | {...} | try.ps1:111:9:111:31 | [Stmt] Call to Write-Output | | +| try.ps1:107:9:107:29 | Call to write-output | try.ps1:110:15:112:5 | {...} | | +| try.ps1:107:9:107:29 | [Stmt] Call to write-output | try.ps1:107:9:107:20 | Write-Output | | +| try.ps1:107:22:107:29 | Hello! | try.ps1:107:9:107:29 | Call to write-output | | +| try.ps1:110:15:112:5 | {...} | try.ps1:111:9:111:31 | [Stmt] Call to write-output | | | try.ps1:111:9:111:20 | Write-Output | try.ps1:111:22:111:31 | Finally! | | -| try.ps1:111:9:111:31 | Call to Write-Output | try.ps1:113:5:113:12 | return ... | | -| try.ps1:111:9:111:31 | [Stmt] Call to Write-Output | try.ps1:111:9:111:20 | Write-Output | | -| try.ps1:111:22:111:31 | Finally! | try.ps1:111:9:111:31 | Call to Write-Output | | +| try.ps1:111:9:111:31 | Call to write-output | try.ps1:113:5:113:12 | return ... | | +| try.ps1:111:9:111:31 | [Stmt] Call to write-output | try.ps1:111:9:111:20 | Write-Output | | +| try.ps1:111:22:111:31 | Finally! | try.ps1:111:9:111:31 | Call to write-output | | | try.ps1:113:5:113:12 | return ... | try.ps1:113:12:113:12 | 1 | | | try.ps1:113:12:113:12 | 1 | try.ps1:105:33:114:1 | exit {...} (normal) | | | try.ps1:116:1:123:1 | def of test-try-finally | try.ps1:125:1:134:1 | def of test-try-finally-catch-specific-1 | | @@ -669,16 +669,16 @@ | try.ps1:116:27:123:1 | {...} | try.ps1:116:27:123:1 | [synth] pipeline | | | try.ps1:117:5:121:5 | try {...} | try.ps1:117:9:119:5 | {...} | | | try.ps1:117:5:122:12 | {...} | try.ps1:117:5:121:5 | try {...} | | -| try.ps1:117:9:119:5 | {...} | try.ps1:118:9:118:29 | [Stmt] Call to Write-Output | | +| try.ps1:117:9:119:5 | {...} | try.ps1:118:9:118:29 | [Stmt] Call to write-output | | | try.ps1:118:9:118:20 | Write-Output | try.ps1:118:22:118:29 | Hello! | | -| try.ps1:118:9:118:29 | Call to Write-Output | try.ps1:119:15:121:5 | {...} | | -| try.ps1:118:9:118:29 | [Stmt] Call to Write-Output | try.ps1:118:9:118:20 | Write-Output | | -| try.ps1:118:22:118:29 | Hello! | try.ps1:118:9:118:29 | Call to Write-Output | | -| try.ps1:119:15:121:5 | {...} | try.ps1:120:9:120:31 | [Stmt] Call to Write-Output | | +| try.ps1:118:9:118:29 | Call to write-output | try.ps1:119:15:121:5 | {...} | | +| try.ps1:118:9:118:29 | [Stmt] Call to write-output | try.ps1:118:9:118:20 | Write-Output | | +| try.ps1:118:22:118:29 | Hello! | try.ps1:118:9:118:29 | Call to write-output | | +| try.ps1:119:15:121:5 | {...} | try.ps1:120:9:120:31 | [Stmt] Call to write-output | | | try.ps1:120:9:120:20 | Write-Output | try.ps1:120:22:120:31 | Finally! | | -| try.ps1:120:9:120:31 | Call to Write-Output | try.ps1:122:5:122:12 | return ... | | -| try.ps1:120:9:120:31 | [Stmt] Call to Write-Output | try.ps1:120:9:120:20 | Write-Output | | -| try.ps1:120:22:120:31 | Finally! | try.ps1:120:9:120:31 | Call to Write-Output | | +| try.ps1:120:9:120:31 | Call to write-output | try.ps1:122:5:122:12 | return ... | | +| try.ps1:120:9:120:31 | [Stmt] Call to write-output | try.ps1:120:9:120:20 | Write-Output | | +| try.ps1:120:22:120:31 | Finally! | try.ps1:120:9:120:31 | Call to write-output | | | try.ps1:122:5:122:12 | return ... | try.ps1:122:12:122:12 | 1 | | | try.ps1:122:12:122:12 | 1 | try.ps1:116:27:123:1 | exit {...} (normal) | | | try.ps1:125:1:134:1 | def of test-try-finally-catch-specific-1 | try.ps1:136:1:147:1 | def of test-nested-try-inner-finally | | @@ -688,16 +688,16 @@ | try.ps1:125:44:134:1 | {...} | try.ps1:125:44:134:1 | [synth] pipeline | | | try.ps1:126:5:132:5 | try {...} | try.ps1:126:9:128:5 | {...} | | | try.ps1:126:5:133:12 | {...} | try.ps1:126:5:132:5 | try {...} | | -| try.ps1:126:9:128:5 | {...} | try.ps1:127:9:127:29 | [Stmt] Call to Write-Output | | +| try.ps1:126:9:128:5 | {...} | try.ps1:127:9:127:29 | [Stmt] Call to write-output | | | try.ps1:127:9:127:20 | Write-Output | try.ps1:127:22:127:29 | Hello! | | -| try.ps1:127:9:127:29 | Call to Write-Output | try.ps1:130:15:132:5 | {...} | | -| try.ps1:127:9:127:29 | [Stmt] Call to Write-Output | try.ps1:127:9:127:20 | Write-Output | | -| try.ps1:127:22:127:29 | Hello! | try.ps1:127:9:127:29 | Call to Write-Output | | -| try.ps1:130:15:132:5 | {...} | try.ps1:131:9:131:31 | [Stmt] Call to Write-Output | | +| try.ps1:127:9:127:29 | Call to write-output | try.ps1:130:15:132:5 | {...} | | +| try.ps1:127:9:127:29 | [Stmt] Call to write-output | try.ps1:127:9:127:20 | Write-Output | | +| try.ps1:127:22:127:29 | Hello! | try.ps1:127:9:127:29 | Call to write-output | | +| try.ps1:130:15:132:5 | {...} | try.ps1:131:9:131:31 | [Stmt] Call to write-output | | | try.ps1:131:9:131:20 | Write-Output | try.ps1:131:22:131:31 | Finally! | | -| try.ps1:131:9:131:31 | Call to Write-Output | try.ps1:133:5:133:12 | return ... | | -| try.ps1:131:9:131:31 | [Stmt] Call to Write-Output | try.ps1:131:9:131:20 | Write-Output | | -| try.ps1:131:22:131:31 | Finally! | try.ps1:131:9:131:31 | Call to Write-Output | | +| try.ps1:131:9:131:31 | Call to write-output | try.ps1:133:5:133:12 | return ... | | +| try.ps1:131:9:131:31 | [Stmt] Call to write-output | try.ps1:131:9:131:20 | Write-Output | | +| try.ps1:131:22:131:31 | Finally! | try.ps1:131:9:131:31 | Call to write-output | | | try.ps1:133:5:133:12 | return ... | try.ps1:133:12:133:12 | 1 | | | try.ps1:133:12:133:12 | 1 | try.ps1:125:44:134:1 | exit {...} (normal) | | | try.ps1:136:1:147:1 | def of test-nested-try-inner-finally | try.ps1:149:1:162:1 | def of test-nested-try-inner-finally | | @@ -709,11 +709,11 @@ | try.ps1:137:5:146:12 | {...} | try.ps1:137:5:145:5 | try {...} | | | try.ps1:137:9:143:5 | {...} | try.ps1:138:9:142:9 | try {...} | | | try.ps1:138:9:142:9 | try {...} | try.ps1:138:13:140:9 | {...} | | -| try.ps1:138:13:140:9 | {...} | try.ps1:139:13:139:33 | [Stmt] Call to Write-Output | | +| try.ps1:138:13:140:9 | {...} | try.ps1:139:13:139:33 | [Stmt] Call to write-output | | | try.ps1:139:13:139:24 | Write-Output | try.ps1:139:26:139:33 | Hello! | | -| try.ps1:139:13:139:33 | Call to Write-Output | try.ps1:146:5:146:12 | return ... | | -| try.ps1:139:13:139:33 | [Stmt] Call to Write-Output | try.ps1:139:13:139:24 | Write-Output | | -| try.ps1:139:26:139:33 | Hello! | try.ps1:139:13:139:33 | Call to Write-Output | | +| try.ps1:139:13:139:33 | Call to write-output | try.ps1:146:5:146:12 | return ... | | +| try.ps1:139:13:139:33 | [Stmt] Call to write-output | try.ps1:139:13:139:24 | Write-Output | | +| try.ps1:139:26:139:33 | Hello! | try.ps1:139:13:139:33 | Call to write-output | | | try.ps1:146:5:146:12 | return ... | try.ps1:146:12:146:12 | 1 | | | try.ps1:146:12:146:12 | 1 | try.ps1:136:40:147:1 | exit {...} (normal) | | | try.ps1:149:1:162:1 | def of test-nested-try-inner-finally | try.ps1:164:1:177:1 | def of test-nested-try-outer-finally | | @@ -725,16 +725,16 @@ | try.ps1:150:5:161:12 | {...} | try.ps1:150:5:160:5 | try {...} | | | try.ps1:150:9:158:5 | {...} | try.ps1:151:9:157:9 | try {...} | | | try.ps1:151:9:157:9 | try {...} | try.ps1:151:13:153:9 | {...} | | -| try.ps1:151:13:153:9 | {...} | try.ps1:152:13:152:33 | [Stmt] Call to Write-Output | | +| try.ps1:151:13:153:9 | {...} | try.ps1:152:13:152:33 | [Stmt] Call to write-output | | | try.ps1:152:13:152:24 | Write-Output | try.ps1:152:26:152:33 | Hello! | | -| try.ps1:152:13:152:33 | Call to Write-Output | try.ps1:155:19:157:9 | {...} | | -| try.ps1:152:13:152:33 | [Stmt] Call to Write-Output | try.ps1:152:13:152:24 | Write-Output | | -| try.ps1:152:26:152:33 | Hello! | try.ps1:152:13:152:33 | Call to Write-Output | | -| try.ps1:155:19:157:9 | {...} | try.ps1:156:13:156:35 | [Stmt] Call to Write-Output | | +| try.ps1:152:13:152:33 | Call to write-output | try.ps1:155:19:157:9 | {...} | | +| try.ps1:152:13:152:33 | [Stmt] Call to write-output | try.ps1:152:13:152:24 | Write-Output | | +| try.ps1:152:26:152:33 | Hello! | try.ps1:152:13:152:33 | Call to write-output | | +| try.ps1:155:19:157:9 | {...} | try.ps1:156:13:156:35 | [Stmt] Call to write-output | | | try.ps1:156:13:156:24 | Write-Output | try.ps1:156:26:156:35 | Finally! | | -| try.ps1:156:13:156:35 | Call to Write-Output | try.ps1:161:5:161:12 | return ... | | -| try.ps1:156:13:156:35 | [Stmt] Call to Write-Output | try.ps1:156:13:156:24 | Write-Output | | -| try.ps1:156:26:156:35 | Finally! | try.ps1:156:13:156:35 | Call to Write-Output | | +| try.ps1:156:13:156:35 | Call to write-output | try.ps1:161:5:161:12 | return ... | | +| try.ps1:156:13:156:35 | [Stmt] Call to write-output | try.ps1:156:13:156:24 | Write-Output | | +| try.ps1:156:26:156:35 | Finally! | try.ps1:156:13:156:35 | Call to write-output | | | try.ps1:161:5:161:12 | return ... | try.ps1:161:12:161:12 | 1 | | | try.ps1:161:12:161:12 | 1 | try.ps1:149:40:162:1 | exit {...} (normal) | | | try.ps1:164:1:177:1 | def of test-nested-try-outer-finally | try.ps1:179:1:194:1 | def of test-nested-try-inner-outer-finally | | @@ -746,16 +746,16 @@ | try.ps1:165:5:176:12 | {...} | try.ps1:165:5:175:5 | try {...} | | | try.ps1:165:9:171:5 | {...} | try.ps1:166:9:170:9 | try {...} | | | try.ps1:166:9:170:9 | try {...} | try.ps1:166:13:168:9 | {...} | | -| try.ps1:166:13:168:9 | {...} | try.ps1:167:13:167:33 | [Stmt] Call to Write-Output | | +| try.ps1:166:13:168:9 | {...} | try.ps1:167:13:167:33 | [Stmt] Call to write-output | | | try.ps1:167:13:167:24 | Write-Output | try.ps1:167:26:167:33 | Hello! | | -| try.ps1:167:13:167:33 | Call to Write-Output | try.ps1:173:15:175:5 | {...} | | -| try.ps1:167:13:167:33 | [Stmt] Call to Write-Output | try.ps1:167:13:167:24 | Write-Output | | -| try.ps1:167:26:167:33 | Hello! | try.ps1:167:13:167:33 | Call to Write-Output | | -| try.ps1:173:15:175:5 | {...} | try.ps1:174:9:174:31 | [Stmt] Call to Write-Output | | +| try.ps1:167:13:167:33 | Call to write-output | try.ps1:173:15:175:5 | {...} | | +| try.ps1:167:13:167:33 | [Stmt] Call to write-output | try.ps1:167:13:167:24 | Write-Output | | +| try.ps1:167:26:167:33 | Hello! | try.ps1:167:13:167:33 | Call to write-output | | +| try.ps1:173:15:175:5 | {...} | try.ps1:174:9:174:31 | [Stmt] Call to write-output | | | try.ps1:174:9:174:20 | Write-Output | try.ps1:174:22:174:31 | Finally! | | -| try.ps1:174:9:174:31 | Call to Write-Output | try.ps1:176:5:176:12 | return ... | | -| try.ps1:174:9:174:31 | [Stmt] Call to Write-Output | try.ps1:174:9:174:20 | Write-Output | | -| try.ps1:174:22:174:31 | Finally! | try.ps1:174:9:174:31 | Call to Write-Output | | +| try.ps1:174:9:174:31 | Call to write-output | try.ps1:176:5:176:12 | return ... | | +| try.ps1:174:9:174:31 | [Stmt] Call to write-output | try.ps1:174:9:174:20 | Write-Output | | +| try.ps1:174:22:174:31 | Finally! | try.ps1:174:9:174:31 | Call to write-output | | | try.ps1:176:5:176:12 | return ... | try.ps1:176:12:176:12 | 1 | | | try.ps1:176:12:176:12 | 1 | try.ps1:164:40:177:1 | exit {...} (normal) | | | try.ps1:179:1:194:1 | def of test-nested-try-inner-outer-finally | try.ps1:1:1:194:1 | exit {...} (normal) | | @@ -767,20 +767,20 @@ | try.ps1:180:5:193:12 | {...} | try.ps1:180:5:192:5 | try {...} | | | try.ps1:180:9:188:5 | {...} | try.ps1:181:9:187:9 | try {...} | | | try.ps1:181:9:187:9 | try {...} | try.ps1:181:13:183:9 | {...} | | -| try.ps1:181:13:183:9 | {...} | try.ps1:182:13:182:33 | [Stmt] Call to Write-Output | | +| try.ps1:181:13:183:9 | {...} | try.ps1:182:13:182:33 | [Stmt] Call to write-output | | | try.ps1:182:13:182:24 | Write-Output | try.ps1:182:26:182:33 | Hello! | | -| try.ps1:182:13:182:33 | Call to Write-Output | try.ps1:185:19:187:9 | {...} | | -| try.ps1:182:13:182:33 | [Stmt] Call to Write-Output | try.ps1:182:13:182:24 | Write-Output | | -| try.ps1:182:26:182:33 | Hello! | try.ps1:182:13:182:33 | Call to Write-Output | | -| try.ps1:185:19:187:9 | {...} | try.ps1:186:13:186:35 | [Stmt] Call to Write-Output | | +| try.ps1:182:13:182:33 | Call to write-output | try.ps1:185:19:187:9 | {...} | | +| try.ps1:182:13:182:33 | [Stmt] Call to write-output | try.ps1:182:13:182:24 | Write-Output | | +| try.ps1:182:26:182:33 | Hello! | try.ps1:182:13:182:33 | Call to write-output | | +| try.ps1:185:19:187:9 | {...} | try.ps1:186:13:186:35 | [Stmt] Call to write-output | | | try.ps1:186:13:186:24 | Write-Output | try.ps1:186:26:186:35 | Finally! | | -| try.ps1:186:13:186:35 | Call to Write-Output | try.ps1:190:15:192:5 | {...} | | -| try.ps1:186:13:186:35 | [Stmt] Call to Write-Output | try.ps1:186:13:186:24 | Write-Output | | -| try.ps1:186:26:186:35 | Finally! | try.ps1:186:13:186:35 | Call to Write-Output | | -| try.ps1:190:15:192:5 | {...} | try.ps1:191:9:191:31 | [Stmt] Call to Write-Output | | +| try.ps1:186:13:186:35 | Call to write-output | try.ps1:190:15:192:5 | {...} | | +| try.ps1:186:13:186:35 | [Stmt] Call to write-output | try.ps1:186:13:186:24 | Write-Output | | +| try.ps1:186:26:186:35 | Finally! | try.ps1:186:13:186:35 | Call to write-output | | +| try.ps1:190:15:192:5 | {...} | try.ps1:191:9:191:31 | [Stmt] Call to write-output | | | try.ps1:191:9:191:20 | Write-Output | try.ps1:191:22:191:31 | Finally! | | -| try.ps1:191:9:191:31 | Call to Write-Output | try.ps1:193:5:193:12 | return ... | | -| try.ps1:191:9:191:31 | [Stmt] Call to Write-Output | try.ps1:191:9:191:20 | Write-Output | | -| try.ps1:191:22:191:31 | Finally! | try.ps1:191:9:191:31 | Call to Write-Output | | +| try.ps1:191:9:191:31 | Call to write-output | try.ps1:193:5:193:12 | return ... | | +| try.ps1:191:9:191:31 | [Stmt] Call to write-output | try.ps1:191:9:191:20 | Write-Output | | +| try.ps1:191:22:191:31 | Finally! | try.ps1:191:9:191:31 | Call to write-output | | | try.ps1:193:5:193:12 | return ... | try.ps1:193:12:193:12 | 1 | | | try.ps1:193:12:193:12 | 1 | try.ps1:179:46:194:1 | exit {...} (normal) | | diff --git a/powershell/ql/test/library-tests/dataflow/fields/test.expected b/powershell/ql/test/library-tests/dataflow/fields/test.expected index 0f9350477142..d30663ac3f93 100644 --- a/powershell/ql/test/library-tests/dataflow/fields/test.expected +++ b/powershell/ql/test/library-tests/dataflow/fields/test.expected @@ -1,45 +1,45 @@ models edges | test.ps1:3:1:3:2 | [post] a [f] | test.ps1:4:6:4:7 | a [f] | provenance | | -| test.ps1:3:8:3:17 | Call to Source | test.ps1:3:1:3:2 | [post] a [f] | provenance | | +| test.ps1:3:8:3:17 | Call to source | test.ps1:3:1:3:2 | [post] a [f] | provenance | | | test.ps1:4:6:4:7 | a [f] | test.ps1:4:6:4:9 | f | provenance | | | test.ps1:10:1:10:5 | [post] arr1 [element 3] | test.ps1:11:6:11:10 | arr1 [element 3] | provenance | | -| test.ps1:10:12:10:21 | Call to Source | test.ps1:10:1:10:5 | [post] arr1 [element 3] | provenance | | +| test.ps1:10:12:10:21 | Call to source | test.ps1:10:1:10:5 | [post] arr1 [element 3] | provenance | | | test.ps1:11:6:11:10 | arr1 [element 3] | test.ps1:11:6:11:13 | ...[...] | provenance | | | test.ps1:14:1:14:5 | [post] arr2 [unknown] | test.ps1:15:6:15:10 | arr2 [unknown] | provenance | | -| test.ps1:14:19:14:28 | Call to Source | test.ps1:14:1:14:5 | [post] arr2 [unknown] | provenance | | +| test.ps1:14:19:14:28 | Call to source | test.ps1:14:1:14:5 | [post] arr2 [unknown] | provenance | | | test.ps1:15:6:15:10 | arr2 [unknown] | test.ps1:15:6:15:13 | ...[...] | provenance | | | test.ps1:17:1:17:5 | [post] arr3 [element 3] | test.ps1:18:6:18:10 | arr3 [element 3] | provenance | | -| test.ps1:17:12:17:21 | Call to Source | test.ps1:17:1:17:5 | [post] arr3 [element 3] | provenance | | +| test.ps1:17:12:17:21 | Call to source | test.ps1:17:1:17:5 | [post] arr3 [element 3] | provenance | | | test.ps1:18:6:18:10 | arr3 [element 3] | test.ps1:18:6:18:20 | ...[...] | provenance | | | test.ps1:20:1:20:5 | [post] arr4 [unknown] | test.ps1:21:6:21:10 | arr4 [unknown] | provenance | | -| test.ps1:20:20:20:29 | Call to Source | test.ps1:20:1:20:5 | [post] arr4 [unknown] | provenance | | +| test.ps1:20:20:20:29 | Call to source | test.ps1:20:1:20:5 | [post] arr4 [unknown] | provenance | | | test.ps1:21:6:21:10 | arr4 [unknown] | test.ps1:21:6:21:21 | ...[...] | provenance | | | test.ps1:23:1:23:5 | [post] arr5 [unknown, element 1] | test.ps1:24:6:24:10 | arr5 [unknown, element 1] | provenance | | | test.ps1:23:1:23:16 | [post] ...[...] [element 1] | test.ps1:23:1:23:5 | [post] arr5 [unknown, element 1] | provenance | | -| test.ps1:23:23:23:32 | Call to Source | test.ps1:23:1:23:16 | [post] ...[...] [element 1] | provenance | | +| test.ps1:23:23:23:32 | Call to source | test.ps1:23:1:23:16 | [post] ...[...] [element 1] | provenance | | | test.ps1:24:6:24:10 | arr5 [unknown, element 1] | test.ps1:24:6:24:21 | ...[...] [element 1] | provenance | | | test.ps1:24:6:24:21 | ...[...] [element 1] | test.ps1:24:6:24:24 | ...[...] | provenance | | | test.ps1:27:1:27:5 | [post] arr6 [element 1, unknown] | test.ps1:28:6:28:10 | arr6 [element 1, unknown] | provenance | | | test.ps1:27:1:27:8 | [post] ...[...] [unknown] | test.ps1:27:1:27:5 | [post] arr6 [element 1, unknown] | provenance | | -| test.ps1:27:23:27:32 | Call to Source | test.ps1:27:1:27:8 | [post] ...[...] [unknown] | provenance | | +| test.ps1:27:23:27:32 | Call to source | test.ps1:27:1:27:8 | [post] ...[...] [unknown] | provenance | | | test.ps1:28:6:28:10 | arr6 [element 1, unknown] | test.ps1:28:6:28:13 | ...[...] [unknown] | provenance | | | test.ps1:28:6:28:13 | ...[...] [unknown] | test.ps1:28:6:28:24 | ...[...] | provenance | | | test.ps1:31:1:31:5 | [post] arr7 [unknown, unknown] | test.ps1:32:6:32:10 | arr7 [unknown, unknown] | provenance | | | test.ps1:31:1:31:5 | [post] arr7 [unknown, unknown] | test.ps1:33:6:33:10 | arr7 [unknown, unknown] | provenance | | | test.ps1:31:1:31:16 | [post] ...[...] [unknown] | test.ps1:31:1:31:5 | [post] arr7 [unknown, unknown] | provenance | | -| test.ps1:31:31:31:40 | Call to Source | test.ps1:31:1:31:16 | [post] ...[...] [unknown] | provenance | | +| test.ps1:31:31:31:40 | Call to source | test.ps1:31:1:31:16 | [post] ...[...] [unknown] | provenance | | | test.ps1:32:6:32:10 | arr7 [unknown, unknown] | test.ps1:32:6:32:13 | ...[...] [unknown] | provenance | | | test.ps1:32:6:32:13 | ...[...] [unknown] | test.ps1:32:6:32:16 | ...[...] | provenance | | | test.ps1:33:6:33:10 | arr7 [unknown, unknown] | test.ps1:33:6:33:21 | ...[...] [unknown] | provenance | | | test.ps1:33:6:33:21 | ...[...] [unknown] | test.ps1:33:6:33:32 | ...[...] | provenance | | -| test.ps1:35:6:35:16 | Call to Source | test.ps1:37:15:37:16 | x | provenance | | +| test.ps1:35:6:35:16 | Call to source | test.ps1:37:15:37:16 | x | provenance | | | test.ps1:37:9:37:16 | ...,... [element 2] | test.ps1:40:6:40:10 | arr8 [element 2] | provenance | | | test.ps1:37:9:37:16 | ...,... [element 2] | test.ps1:41:6:41:10 | arr8 [element 2] | provenance | | | test.ps1:37:15:37:16 | x | test.ps1:37:9:37:16 | ...,... [element 2] | provenance | | | test.ps1:40:6:40:10 | arr8 [element 2] | test.ps1:40:6:40:13 | ...[...] | provenance | | | test.ps1:41:6:41:10 | arr8 [element 2] | test.ps1:41:6:41:20 | ...[...] | provenance | | -| test.ps1:43:6:43:16 | Call to Source | test.ps1:45:17:45:18 | y | provenance | | +| test.ps1:43:6:43:16 | Call to source | test.ps1:45:17:45:18 | y | provenance | | | test.ps1:45:9:45:19 | @(...) [element 2] | test.ps1:48:6:48:10 | arr9 [element 2] | provenance | | | test.ps1:45:9:45:19 | @(...) [element 2] | test.ps1:49:6:49:10 | arr9 [element 2] | provenance | | | test.ps1:45:17:45:18 | y | test.ps1:45:9:45:19 | @(...) [element 2] | provenance | | @@ -48,11 +48,11 @@ edges | test.ps1:54:5:56:5 | this [field] | test.ps1:55:14:55:24 | this [field] | provenance | | | test.ps1:55:14:55:24 | this [field] | test.ps1:55:14:55:24 | field | provenance | | | test.ps1:61:1:61:8 | [post] myClass [field] | test.ps1:63:1:63:8 | myClass [field] | provenance | | -| test.ps1:61:18:61:28 | Call to Source | test.ps1:61:1:61:8 | [post] myClass [field] | provenance | | +| test.ps1:61:18:61:28 | Call to source | test.ps1:61:1:61:8 | [post] myClass [field] | provenance | | | test.ps1:63:1:63:8 | myClass [field] | test.ps1:54:5:56:5 | this [field] | provenance | | -| test.ps1:66:10:66:20 | Call to Source | test.ps1:69:5:69:6 | x | provenance | | -| test.ps1:67:10:67:20 | Call to Source | test.ps1:70:5:70:6 | y | provenance | | -| test.ps1:68:10:68:20 | Call to Source | test.ps1:70:9:70:10 | z | provenance | | +| test.ps1:66:10:66:20 | Call to source | test.ps1:69:5:69:6 | x | provenance | | +| test.ps1:67:10:67:20 | Call to source | test.ps1:70:5:70:6 | y | provenance | | +| test.ps1:68:10:68:20 | Call to source | test.ps1:70:9:70:10 | z | provenance | | | test.ps1:69:5:69:6 | x | test.ps1:73:6:73:12 | Call to produce [unknown index] | provenance | | | test.ps1:70:5:70:6 | y | test.ps1:73:6:73:12 | Call to produce [unknown index] | provenance | | | test.ps1:70:9:70:10 | z | test.ps1:73:6:73:12 | Call to produce [unknown index] | provenance | | @@ -64,62 +64,62 @@ edges | test.ps1:76:6:76:7 | x [unknown index] | test.ps1:76:6:76:10 | ...[...] | provenance | | | test.ps1:78:9:81:1 | ${...} [element a] | test.ps1:83:6:83:10 | hash [element a] | provenance | | | test.ps1:78:9:81:1 | ${...} [element a] | test.ps1:87:6:87:10 | hash [element a] | provenance | | -| test.ps1:79:7:79:17 | Call to Source | test.ps1:78:9:81:1 | ${...} [element a] | provenance | | +| test.ps1:79:7:79:17 | Call to source | test.ps1:78:9:81:1 | ${...} [element a] | provenance | | | test.ps1:83:6:83:10 | hash [element a] | test.ps1:83:6:83:15 | ...[...] | provenance | | | test.ps1:87:6:87:10 | hash [element a] | test.ps1:87:6:87:15 | ...[...] | provenance | | | test.ps1:88:1:88:5 | [post] hash [b] | test.ps1:89:6:89:10 | hash [b] | provenance | | -| test.ps1:88:11:88:21 | Call to Source | test.ps1:88:1:88:5 | [post] hash [b] | provenance | | +| test.ps1:88:11:88:21 | Call to source | test.ps1:88:1:88:5 | [post] hash [b] | provenance | | | test.ps1:89:6:89:10 | hash [b] | test.ps1:89:6:89:12 | b | provenance | | nodes | test.ps1:3:1:3:2 | [post] a [f] | semmle.label | [post] a [f] | -| test.ps1:3:8:3:17 | Call to Source | semmle.label | Call to Source | +| test.ps1:3:8:3:17 | Call to source | semmle.label | Call to source | | test.ps1:4:6:4:7 | a [f] | semmle.label | a [f] | | test.ps1:4:6:4:9 | f | semmle.label | f | | test.ps1:10:1:10:5 | [post] arr1 [element 3] | semmle.label | [post] arr1 [element 3] | -| test.ps1:10:12:10:21 | Call to Source | semmle.label | Call to Source | +| test.ps1:10:12:10:21 | Call to source | semmle.label | Call to source | | test.ps1:11:6:11:10 | arr1 [element 3] | semmle.label | arr1 [element 3] | | test.ps1:11:6:11:13 | ...[...] | semmle.label | ...[...] | | test.ps1:14:1:14:5 | [post] arr2 [unknown] | semmle.label | [post] arr2 [unknown] | -| test.ps1:14:19:14:28 | Call to Source | semmle.label | Call to Source | +| test.ps1:14:19:14:28 | Call to source | semmle.label | Call to source | | test.ps1:15:6:15:10 | arr2 [unknown] | semmle.label | arr2 [unknown] | | test.ps1:15:6:15:13 | ...[...] | semmle.label | ...[...] | | test.ps1:17:1:17:5 | [post] arr3 [element 3] | semmle.label | [post] arr3 [element 3] | -| test.ps1:17:12:17:21 | Call to Source | semmle.label | Call to Source | +| test.ps1:17:12:17:21 | Call to source | semmle.label | Call to source | | test.ps1:18:6:18:10 | arr3 [element 3] | semmle.label | arr3 [element 3] | | test.ps1:18:6:18:20 | ...[...] | semmle.label | ...[...] | | test.ps1:20:1:20:5 | [post] arr4 [unknown] | semmle.label | [post] arr4 [unknown] | -| test.ps1:20:20:20:29 | Call to Source | semmle.label | Call to Source | +| test.ps1:20:20:20:29 | Call to source | semmle.label | Call to source | | test.ps1:21:6:21:10 | arr4 [unknown] | semmle.label | arr4 [unknown] | | test.ps1:21:6:21:21 | ...[...] | semmle.label | ...[...] | | test.ps1:23:1:23:5 | [post] arr5 [unknown, element 1] | semmle.label | [post] arr5 [unknown, element 1] | | test.ps1:23:1:23:16 | [post] ...[...] [element 1] | semmle.label | [post] ...[...] [element 1] | -| test.ps1:23:23:23:32 | Call to Source | semmle.label | Call to Source | +| test.ps1:23:23:23:32 | Call to source | semmle.label | Call to source | | test.ps1:24:6:24:10 | arr5 [unknown, element 1] | semmle.label | arr5 [unknown, element 1] | | test.ps1:24:6:24:21 | ...[...] [element 1] | semmle.label | ...[...] [element 1] | | test.ps1:24:6:24:24 | ...[...] | semmle.label | ...[...] | | test.ps1:27:1:27:5 | [post] arr6 [element 1, unknown] | semmle.label | [post] arr6 [element 1, unknown] | | test.ps1:27:1:27:8 | [post] ...[...] [unknown] | semmle.label | [post] ...[...] [unknown] | -| test.ps1:27:23:27:32 | Call to Source | semmle.label | Call to Source | +| test.ps1:27:23:27:32 | Call to source | semmle.label | Call to source | | test.ps1:28:6:28:10 | arr6 [element 1, unknown] | semmle.label | arr6 [element 1, unknown] | | test.ps1:28:6:28:13 | ...[...] [unknown] | semmle.label | ...[...] [unknown] | | test.ps1:28:6:28:24 | ...[...] | semmle.label | ...[...] | | test.ps1:31:1:31:5 | [post] arr7 [unknown, unknown] | semmle.label | [post] arr7 [unknown, unknown] | | test.ps1:31:1:31:16 | [post] ...[...] [unknown] | semmle.label | [post] ...[...] [unknown] | -| test.ps1:31:31:31:40 | Call to Source | semmle.label | Call to Source | +| test.ps1:31:31:31:40 | Call to source | semmle.label | Call to source | | test.ps1:32:6:32:10 | arr7 [unknown, unknown] | semmle.label | arr7 [unknown, unknown] | | test.ps1:32:6:32:13 | ...[...] [unknown] | semmle.label | ...[...] [unknown] | | test.ps1:32:6:32:16 | ...[...] | semmle.label | ...[...] | | test.ps1:33:6:33:10 | arr7 [unknown, unknown] | semmle.label | arr7 [unknown, unknown] | | test.ps1:33:6:33:21 | ...[...] [unknown] | semmle.label | ...[...] [unknown] | | test.ps1:33:6:33:32 | ...[...] | semmle.label | ...[...] | -| test.ps1:35:6:35:16 | Call to Source | semmle.label | Call to Source | +| test.ps1:35:6:35:16 | Call to source | semmle.label | Call to source | | test.ps1:37:9:37:16 | ...,... [element 2] | semmle.label | ...,... [element 2] | | test.ps1:37:15:37:16 | x | semmle.label | x | | test.ps1:40:6:40:10 | arr8 [element 2] | semmle.label | arr8 [element 2] | | test.ps1:40:6:40:13 | ...[...] | semmle.label | ...[...] | | test.ps1:41:6:41:10 | arr8 [element 2] | semmle.label | arr8 [element 2] | | test.ps1:41:6:41:20 | ...[...] | semmle.label | ...[...] | -| test.ps1:43:6:43:16 | Call to Source | semmle.label | Call to Source | +| test.ps1:43:6:43:16 | Call to source | semmle.label | Call to source | | test.ps1:45:9:45:19 | @(...) [element 2] | semmle.label | @(...) [element 2] | | test.ps1:45:17:45:18 | y | semmle.label | y | | test.ps1:48:6:48:10 | arr9 [element 2] | semmle.label | arr9 [element 2] | @@ -130,11 +130,11 @@ nodes | test.ps1:55:14:55:24 | field | semmle.label | field | | test.ps1:55:14:55:24 | this [field] | semmle.label | this [field] | | test.ps1:61:1:61:8 | [post] myClass [field] | semmle.label | [post] myClass [field] | -| test.ps1:61:18:61:28 | Call to Source | semmle.label | Call to Source | +| test.ps1:61:18:61:28 | Call to source | semmle.label | Call to source | | test.ps1:63:1:63:8 | myClass [field] | semmle.label | myClass [field] | -| test.ps1:66:10:66:20 | Call to Source | semmle.label | Call to Source | -| test.ps1:67:10:67:20 | Call to Source | semmle.label | Call to Source | -| test.ps1:68:10:68:20 | Call to Source | semmle.label | Call to Source | +| test.ps1:66:10:66:20 | Call to source | semmle.label | Call to source | +| test.ps1:67:10:67:20 | Call to source | semmle.label | Call to source | +| test.ps1:68:10:68:20 | Call to source | semmle.label | Call to source | | test.ps1:69:5:69:6 | x | semmle.label | x | | test.ps1:70:5:70:6 | y | semmle.label | y | | test.ps1:70:9:70:10 | z | semmle.label | z | @@ -146,41 +146,41 @@ nodes | test.ps1:76:6:76:7 | x [unknown index] | semmle.label | x [unknown index] | | test.ps1:76:6:76:10 | ...[...] | semmle.label | ...[...] | | test.ps1:78:9:81:1 | ${...} [element a] | semmle.label | ${...} [element a] | -| test.ps1:79:7:79:17 | Call to Source | semmle.label | Call to Source | +| test.ps1:79:7:79:17 | Call to source | semmle.label | Call to source | | test.ps1:83:6:83:10 | hash [element a] | semmle.label | hash [element a] | | test.ps1:83:6:83:15 | ...[...] | semmle.label | ...[...] | | test.ps1:87:6:87:10 | hash [element a] | semmle.label | hash [element a] | | test.ps1:87:6:87:15 | ...[...] | semmle.label | ...[...] | | test.ps1:88:1:88:5 | [post] hash [b] | semmle.label | [post] hash [b] | -| test.ps1:88:11:88:21 | Call to Source | semmle.label | Call to Source | +| test.ps1:88:11:88:21 | Call to source | semmle.label | Call to source | | test.ps1:89:6:89:10 | hash [b] | semmle.label | hash [b] | | test.ps1:89:6:89:12 | b | semmle.label | b | subpaths testFailures #select -| test.ps1:4:6:4:9 | f | test.ps1:3:8:3:17 | Call to Source | test.ps1:4:6:4:9 | f | $@ | test.ps1:3:8:3:17 | Call to Source | Call to Source | -| test.ps1:11:6:11:13 | ...[...] | test.ps1:10:12:10:21 | Call to Source | test.ps1:11:6:11:13 | ...[...] | $@ | test.ps1:10:12:10:21 | Call to Source | Call to Source | -| test.ps1:15:6:15:13 | ...[...] | test.ps1:14:19:14:28 | Call to Source | test.ps1:15:6:15:13 | ...[...] | $@ | test.ps1:14:19:14:28 | Call to Source | Call to Source | -| test.ps1:18:6:18:20 | ...[...] | test.ps1:17:12:17:21 | Call to Source | test.ps1:18:6:18:20 | ...[...] | $@ | test.ps1:17:12:17:21 | Call to Source | Call to Source | -| test.ps1:21:6:21:21 | ...[...] | test.ps1:20:20:20:29 | Call to Source | test.ps1:21:6:21:21 | ...[...] | $@ | test.ps1:20:20:20:29 | Call to Source | Call to Source | -| test.ps1:24:6:24:24 | ...[...] | test.ps1:23:23:23:32 | Call to Source | test.ps1:24:6:24:24 | ...[...] | $@ | test.ps1:23:23:23:32 | Call to Source | Call to Source | -| test.ps1:28:6:28:24 | ...[...] | test.ps1:27:23:27:32 | Call to Source | test.ps1:28:6:28:24 | ...[...] | $@ | test.ps1:27:23:27:32 | Call to Source | Call to Source | -| test.ps1:32:6:32:16 | ...[...] | test.ps1:31:31:31:40 | Call to Source | test.ps1:32:6:32:16 | ...[...] | $@ | test.ps1:31:31:31:40 | Call to Source | Call to Source | -| test.ps1:33:6:33:32 | ...[...] | test.ps1:31:31:31:40 | Call to Source | test.ps1:33:6:33:32 | ...[...] | $@ | test.ps1:31:31:31:40 | Call to Source | Call to Source | -| test.ps1:40:6:40:13 | ...[...] | test.ps1:35:6:35:16 | Call to Source | test.ps1:40:6:40:13 | ...[...] | $@ | test.ps1:35:6:35:16 | Call to Source | Call to Source | -| test.ps1:41:6:41:20 | ...[...] | test.ps1:35:6:35:16 | Call to Source | test.ps1:41:6:41:20 | ...[...] | $@ | test.ps1:35:6:35:16 | Call to Source | Call to Source | -| test.ps1:48:6:48:13 | ...[...] | test.ps1:43:6:43:16 | Call to Source | test.ps1:48:6:48:13 | ...[...] | $@ | test.ps1:43:6:43:16 | Call to Source | Call to Source | -| test.ps1:49:6:49:20 | ...[...] | test.ps1:43:6:43:16 | Call to Source | test.ps1:49:6:49:20 | ...[...] | $@ | test.ps1:43:6:43:16 | Call to Source | Call to Source | -| test.ps1:55:14:55:24 | field | test.ps1:61:18:61:28 | Call to Source | test.ps1:55:14:55:24 | field | $@ | test.ps1:61:18:61:28 | Call to Source | Call to Source | -| test.ps1:74:6:74:10 | ...[...] | test.ps1:66:10:66:20 | Call to Source | test.ps1:74:6:74:10 | ...[...] | $@ | test.ps1:66:10:66:20 | Call to Source | Call to Source | -| test.ps1:74:6:74:10 | ...[...] | test.ps1:67:10:67:20 | Call to Source | test.ps1:74:6:74:10 | ...[...] | $@ | test.ps1:67:10:67:20 | Call to Source | Call to Source | -| test.ps1:74:6:74:10 | ...[...] | test.ps1:68:10:68:20 | Call to Source | test.ps1:74:6:74:10 | ...[...] | $@ | test.ps1:68:10:68:20 | Call to Source | Call to Source | -| test.ps1:75:6:75:10 | ...[...] | test.ps1:66:10:66:20 | Call to Source | test.ps1:75:6:75:10 | ...[...] | $@ | test.ps1:66:10:66:20 | Call to Source | Call to Source | -| test.ps1:75:6:75:10 | ...[...] | test.ps1:67:10:67:20 | Call to Source | test.ps1:75:6:75:10 | ...[...] | $@ | test.ps1:67:10:67:20 | Call to Source | Call to Source | -| test.ps1:75:6:75:10 | ...[...] | test.ps1:68:10:68:20 | Call to Source | test.ps1:75:6:75:10 | ...[...] | $@ | test.ps1:68:10:68:20 | Call to Source | Call to Source | -| test.ps1:76:6:76:10 | ...[...] | test.ps1:66:10:66:20 | Call to Source | test.ps1:76:6:76:10 | ...[...] | $@ | test.ps1:66:10:66:20 | Call to Source | Call to Source | -| test.ps1:76:6:76:10 | ...[...] | test.ps1:67:10:67:20 | Call to Source | test.ps1:76:6:76:10 | ...[...] | $@ | test.ps1:67:10:67:20 | Call to Source | Call to Source | -| test.ps1:76:6:76:10 | ...[...] | test.ps1:68:10:68:20 | Call to Source | test.ps1:76:6:76:10 | ...[...] | $@ | test.ps1:68:10:68:20 | Call to Source | Call to Source | -| test.ps1:83:6:83:15 | ...[...] | test.ps1:79:7:79:17 | Call to Source | test.ps1:83:6:83:15 | ...[...] | $@ | test.ps1:79:7:79:17 | Call to Source | Call to Source | -| test.ps1:87:6:87:15 | ...[...] | test.ps1:79:7:79:17 | Call to Source | test.ps1:87:6:87:15 | ...[...] | $@ | test.ps1:79:7:79:17 | Call to Source | Call to Source | -| test.ps1:89:6:89:12 | b | test.ps1:88:11:88:21 | Call to Source | test.ps1:89:6:89:12 | b | $@ | test.ps1:88:11:88:21 | Call to Source | Call to Source | +| test.ps1:4:6:4:9 | f | test.ps1:3:8:3:17 | Call to source | test.ps1:4:6:4:9 | f | $@ | test.ps1:3:8:3:17 | Call to source | Call to source | +| test.ps1:11:6:11:13 | ...[...] | test.ps1:10:12:10:21 | Call to source | test.ps1:11:6:11:13 | ...[...] | $@ | test.ps1:10:12:10:21 | Call to source | Call to source | +| test.ps1:15:6:15:13 | ...[...] | test.ps1:14:19:14:28 | Call to source | test.ps1:15:6:15:13 | ...[...] | $@ | test.ps1:14:19:14:28 | Call to source | Call to source | +| test.ps1:18:6:18:20 | ...[...] | test.ps1:17:12:17:21 | Call to source | test.ps1:18:6:18:20 | ...[...] | $@ | test.ps1:17:12:17:21 | Call to source | Call to source | +| test.ps1:21:6:21:21 | ...[...] | test.ps1:20:20:20:29 | Call to source | test.ps1:21:6:21:21 | ...[...] | $@ | test.ps1:20:20:20:29 | Call to source | Call to source | +| test.ps1:24:6:24:24 | ...[...] | test.ps1:23:23:23:32 | Call to source | test.ps1:24:6:24:24 | ...[...] | $@ | test.ps1:23:23:23:32 | Call to source | Call to source | +| test.ps1:28:6:28:24 | ...[...] | test.ps1:27:23:27:32 | Call to source | test.ps1:28:6:28:24 | ...[...] | $@ | test.ps1:27:23:27:32 | Call to source | Call to source | +| test.ps1:32:6:32:16 | ...[...] | test.ps1:31:31:31:40 | Call to source | test.ps1:32:6:32:16 | ...[...] | $@ | test.ps1:31:31:31:40 | Call to source | Call to source | +| test.ps1:33:6:33:32 | ...[...] | test.ps1:31:31:31:40 | Call to source | test.ps1:33:6:33:32 | ...[...] | $@ | test.ps1:31:31:31:40 | Call to source | Call to source | +| test.ps1:40:6:40:13 | ...[...] | test.ps1:35:6:35:16 | Call to source | test.ps1:40:6:40:13 | ...[...] | $@ | test.ps1:35:6:35:16 | Call to source | Call to source | +| test.ps1:41:6:41:20 | ...[...] | test.ps1:35:6:35:16 | Call to source | test.ps1:41:6:41:20 | ...[...] | $@ | test.ps1:35:6:35:16 | Call to source | Call to source | +| test.ps1:48:6:48:13 | ...[...] | test.ps1:43:6:43:16 | Call to source | test.ps1:48:6:48:13 | ...[...] | $@ | test.ps1:43:6:43:16 | Call to source | Call to source | +| test.ps1:49:6:49:20 | ...[...] | test.ps1:43:6:43:16 | Call to source | test.ps1:49:6:49:20 | ...[...] | $@ | test.ps1:43:6:43:16 | Call to source | Call to source | +| test.ps1:55:14:55:24 | field | test.ps1:61:18:61:28 | Call to source | test.ps1:55:14:55:24 | field | $@ | test.ps1:61:18:61:28 | Call to source | Call to source | +| test.ps1:74:6:74:10 | ...[...] | test.ps1:66:10:66:20 | Call to source | test.ps1:74:6:74:10 | ...[...] | $@ | test.ps1:66:10:66:20 | Call to source | Call to source | +| test.ps1:74:6:74:10 | ...[...] | test.ps1:67:10:67:20 | Call to source | test.ps1:74:6:74:10 | ...[...] | $@ | test.ps1:67:10:67:20 | Call to source | Call to source | +| test.ps1:74:6:74:10 | ...[...] | test.ps1:68:10:68:20 | Call to source | test.ps1:74:6:74:10 | ...[...] | $@ | test.ps1:68:10:68:20 | Call to source | Call to source | +| test.ps1:75:6:75:10 | ...[...] | test.ps1:66:10:66:20 | Call to source | test.ps1:75:6:75:10 | ...[...] | $@ | test.ps1:66:10:66:20 | Call to source | Call to source | +| test.ps1:75:6:75:10 | ...[...] | test.ps1:67:10:67:20 | Call to source | test.ps1:75:6:75:10 | ...[...] | $@ | test.ps1:67:10:67:20 | Call to source | Call to source | +| test.ps1:75:6:75:10 | ...[...] | test.ps1:68:10:68:20 | Call to source | test.ps1:75:6:75:10 | ...[...] | $@ | test.ps1:68:10:68:20 | Call to source | Call to source | +| test.ps1:76:6:76:10 | ...[...] | test.ps1:66:10:66:20 | Call to source | test.ps1:76:6:76:10 | ...[...] | $@ | test.ps1:66:10:66:20 | Call to source | Call to source | +| test.ps1:76:6:76:10 | ...[...] | test.ps1:67:10:67:20 | Call to source | test.ps1:76:6:76:10 | ...[...] | $@ | test.ps1:67:10:67:20 | Call to source | Call to source | +| test.ps1:76:6:76:10 | ...[...] | test.ps1:68:10:68:20 | Call to source | test.ps1:76:6:76:10 | ...[...] | $@ | test.ps1:68:10:68:20 | Call to source | Call to source | +| test.ps1:83:6:83:15 | ...[...] | test.ps1:79:7:79:17 | Call to source | test.ps1:83:6:83:15 | ...[...] | $@ | test.ps1:79:7:79:17 | Call to source | Call to source | +| test.ps1:87:6:87:15 | ...[...] | test.ps1:79:7:79:17 | Call to source | test.ps1:87:6:87:15 | ...[...] | $@ | test.ps1:79:7:79:17 | Call to source | Call to source | +| test.ps1:89:6:89:12 | b | test.ps1:88:11:88:21 | Call to source | test.ps1:89:6:89:12 | b | $@ | test.ps1:88:11:88:21 | Call to source | Call to source | diff --git a/powershell/ql/test/library-tests/dataflow/local/flow.expected b/powershell/ql/test/library-tests/dataflow/local/flow.expected index dd5d6f834b31..78b46b5d7994 100644 --- a/powershell/ql/test/library-tests/dataflow/local/flow.expected +++ b/powershell/ql/test/library-tests/dataflow/local/flow.expected @@ -1,39 +1,39 @@ | test.ps1:1:1:1:3 | a1 | test.ps1:2:6:2:8 | a1 | | test.ps1:1:1:24:22 | implicit unwrapping of {...} | test.ps1:1:1:24:22 | return value for {...} | | test.ps1:1:1:24:22 | pre-return value for {...} | test.ps1:1:1:24:22 | implicit unwrapping of {...} | -| test.ps1:1:7:1:12 | Call to Source | test.ps1:1:1:1:3 | a1 | -| test.ps1:2:1:2:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:2:1:2:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:1:7:1:12 | Call to source | test.ps1:1:1:1:3 | a1 | +| test.ps1:2:1:2:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:2:1:2:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:4:1:4:2 | b | test.ps1:5:4:5:5 | b | -| test.ps1:4:6:4:12 | Call to GetBool | test.ps1:4:1:4:2 | b | +| test.ps1:4:6:4:12 | Call to getbool | test.ps1:4:1:4:2 | b | | test.ps1:5:4:5:5 | b | test.ps1:10:14:10:15 | b | | test.ps1:6:5:6:7 | a2 | test.ps1:8:6:8:8 | a2 | -| test.ps1:6:11:6:16 | Call to Source | test.ps1:6:5:6:7 | a2 | -| test.ps1:8:1:8:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:8:1:8:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:6:11:6:16 | Call to source | test.ps1:6:5:6:7 | a2 | +| test.ps1:8:1:8:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:8:1:8:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:10:1:10:2 | c | test.ps1:11:6:11:7 | c | | test.ps1:10:6:10:15 | [...]... | test.ps1:10:1:10:2 | c | | test.ps1:10:14:10:15 | b | test.ps1:10:6:10:15 | [...]... | -| test.ps1:11:1:11:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:11:1:11:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:11:1:11:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:11:1:11:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:11:6:11:7 | [post] c | test.ps1:13:7:13:8 | c | | test.ps1:11:6:11:7 | c | test.ps1:13:7:13:8 | c | | test.ps1:13:1:13:2 | d | test.ps1:14:6:14:7 | d | | test.ps1:13:6:13:9 | (...) | test.ps1:13:1:13:2 | d | | test.ps1:13:7:13:8 | c | test.ps1:13:6:13:9 | (...) | -| test.ps1:14:1:14:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:14:1:14:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:14:1:14:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:14:1:14:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:14:6:14:7 | [post] d | test.ps1:16:6:16:7 | d | | test.ps1:14:6:14:7 | d | test.ps1:16:6:16:7 | d | | test.ps1:16:1:16:2 | e | test.ps1:17:6:17:7 | e | | test.ps1:16:6:16:11 | ...+... | test.ps1:16:1:16:2 | e | -| test.ps1:17:1:17:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:17:1:17:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:17:1:17:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:17:1:17:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:19:1:19:2 | f | test.ps1:21:25:21:26 | f | -| test.ps1:19:6:19:11 | Call to Source | test.ps1:19:1:19:2 | f | -| test.ps1:21:1:21:27 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:21:1:21:27 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:19:6:19:11 | Call to source | test.ps1:19:1:19:2 | f | +| test.ps1:21:1:21:27 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:21:1:21:27 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:23:1:23:6 | input | test.ps1:24:17:24:22 | input | -| test.ps1:23:10:23:32 | Call to Read-Host | test.ps1:23:1:23:6 | input | -| test.ps1:24:1:24:22 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:24:1:24:22 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:23:10:23:32 | Call to read-host | test.ps1:23:1:23:6 | input | +| test.ps1:24:1:24:22 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:24:1:24:22 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | diff --git a/powershell/ql/test/library-tests/dataflow/local/taint.expected b/powershell/ql/test/library-tests/dataflow/local/taint.expected index 1d2bd8ef34b3..0c68ed5dd894 100644 --- a/powershell/ql/test/library-tests/dataflow/local/taint.expected +++ b/powershell/ql/test/library-tests/dataflow/local/taint.expected @@ -2,42 +2,42 @@ | test.ps1:1:1:24:22 | implicit unwrapping of {...} | test.ps1:1:1:24:22 | return value for {...} | | test.ps1:1:1:24:22 | pre-return value for {...} | test.ps1:1:1:24:22 | implicit unwrapping of {...} | | test.ps1:1:1:24:22 | pre-return value for {...} | test.ps1:1:1:24:22 | implicit unwrapping of {...} | -| test.ps1:1:7:1:12 | Call to Source | test.ps1:1:1:1:3 | a1 | -| test.ps1:2:1:2:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:2:1:2:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:1:7:1:12 | Call to source | test.ps1:1:1:1:3 | a1 | +| test.ps1:2:1:2:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:2:1:2:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:4:1:4:2 | b | test.ps1:5:4:5:5 | b | -| test.ps1:4:6:4:12 | Call to GetBool | test.ps1:4:1:4:2 | b | +| test.ps1:4:6:4:12 | Call to getbool | test.ps1:4:1:4:2 | b | | test.ps1:5:4:5:5 | b | test.ps1:10:14:10:15 | b | | test.ps1:6:5:6:7 | a2 | test.ps1:8:6:8:8 | a2 | -| test.ps1:6:11:6:16 | Call to Source | test.ps1:6:5:6:7 | a2 | -| test.ps1:8:1:8:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:8:1:8:8 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:6:11:6:16 | Call to source | test.ps1:6:5:6:7 | a2 | +| test.ps1:8:1:8:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:8:1:8:8 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:10:1:10:2 | c | test.ps1:11:6:11:7 | c | | test.ps1:10:6:10:15 | [...]... | test.ps1:10:1:10:2 | c | | test.ps1:10:14:10:15 | b | test.ps1:10:6:10:15 | [...]... | -| test.ps1:11:1:11:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:11:1:11:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:11:1:11:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:11:1:11:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:11:6:11:7 | [post] c | test.ps1:13:7:13:8 | c | | test.ps1:11:6:11:7 | c | test.ps1:13:7:13:8 | c | | test.ps1:13:1:13:2 | d | test.ps1:14:6:14:7 | d | | test.ps1:13:6:13:9 | (...) | test.ps1:13:1:13:2 | d | | test.ps1:13:7:13:8 | c | test.ps1:13:6:13:9 | (...) | -| test.ps1:14:1:14:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:14:1:14:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:14:1:14:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:14:1:14:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:14:6:14:7 | [post] d | test.ps1:16:6:16:7 | d | | test.ps1:14:6:14:7 | d | test.ps1:16:6:16:7 | d | | test.ps1:16:1:16:2 | e | test.ps1:17:6:17:7 | e | | test.ps1:16:6:16:7 | d | test.ps1:16:6:16:11 | ...+... | | test.ps1:16:6:16:11 | ...+... | test.ps1:16:1:16:2 | e | | test.ps1:16:11:16:11 | 1 | test.ps1:16:6:16:11 | ...+... | -| test.ps1:17:1:17:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:17:1:17:7 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:17:1:17:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:17:1:17:7 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:19:1:19:2 | f | test.ps1:21:25:21:26 | f | -| test.ps1:19:6:19:11 | Call to Source | test.ps1:19:1:19:2 | f | -| test.ps1:21:1:21:27 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:21:1:21:27 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:19:6:19:11 | Call to source | test.ps1:19:1:19:2 | f | +| test.ps1:21:1:21:27 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:21:1:21:27 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | | test.ps1:21:25:21:26 | f | test.ps1:21:6:21:27 | here is a string: $f | | test.ps1:23:1:23:6 | input | test.ps1:24:17:24:22 | input | -| test.ps1:23:10:23:32 | Call to Read-Host | test.ps1:23:1:23:6 | input | -| test.ps1:24:1:24:22 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | -| test.ps1:24:1:24:22 | Call to Sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:23:10:23:32 | Call to read-host | test.ps1:23:1:23:6 | input | +| test.ps1:24:1:24:22 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | +| test.ps1:24:1:24:22 | Call to sink | test.ps1:1:1:24:22 | pre-return value for {...} | diff --git a/powershell/ql/test/library-tests/dataflow/mad/flow.expected b/powershell/ql/test/library-tests/dataflow/mad/flow.expected index df796ccd7119..c1025f2bd751 100644 --- a/powershell/ql/test/library-tests/dataflow/mad/flow.expected +++ b/powershell/ql/test/library-tests/dataflow/mad/flow.expected @@ -5,19 +5,19 @@ edges | file://:0:0:0:0 | [summary param] pos(0, {}) in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | file://:0:0:0:0 | [summary] to write: ReturnValue in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | provenance | | | file://:0:0:0:0 | [summary] read: Argument[pipeline].Element[?] in microsoft.powershell.utility!;Method[join-string] | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | provenance | | | file://:0:0:0:0 | [summary] read: Argument[pipeline].Element[?] in microsoft.powershell.utility!;Method[join-string] | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | provenance | | -| test.ps1:1:6:1:15 | Call to Source | test.ps1:2:94:2:95 | x | provenance | | -| test.ps1:2:6:2:96 | Call to EscapeSingleQuotedStringContent | test.ps1:3:6:3:7 | y | provenance | | +| test.ps1:1:6:1:15 | Call to source | test.ps1:2:94:2:95 | x | provenance | | +| test.ps1:2:6:2:96 | Call to escapesinglequotedstringcontent | test.ps1:3:6:3:7 | y | provenance | | | test.ps1:2:94:2:95 | x | file://:0:0:0:0 | [summary param] pos(0, {}) in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | provenance | | -| test.ps1:2:94:2:95 | x | test.ps1:2:6:2:96 | Call to EscapeSingleQuotedStringContent | provenance | | -| test.ps1:5:6:5:15 | Call to Source | test.ps1:7:6:7:7 | x | provenance | | -| test.ps1:6:6:6:15 | Call to Source | test.ps1:7:10:7:11 | y | provenance | | +| test.ps1:2:94:2:95 | x | test.ps1:2:6:2:96 | Call to escapesinglequotedstringcontent | provenance | | +| test.ps1:5:6:5:15 | Call to source | test.ps1:7:6:7:7 | x | provenance | | +| test.ps1:6:6:6:15 | Call to source | test.ps1:7:10:7:11 | y | provenance | | | test.ps1:7:6:7:7 | x | test.ps1:7:6:7:11 | ...,... [element 0] | provenance | | | test.ps1:7:6:7:11 | ...,... [element 0] | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 0] | provenance | | -| test.ps1:7:6:7:11 | ...,... [element 0] | test.ps1:7:15:7:25 | Call to Join-String | provenance | | +| test.ps1:7:6:7:11 | ...,... [element 0] | test.ps1:7:15:7:25 | Call to join-string | provenance | | | test.ps1:7:6:7:11 | ...,... [element 1] | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 1] | provenance | | -| test.ps1:7:6:7:11 | ...,... [element 1] | test.ps1:7:15:7:25 | Call to Join-String | provenance | | +| test.ps1:7:6:7:11 | ...,... [element 1] | test.ps1:7:15:7:25 | Call to join-string | provenance | | | test.ps1:7:10:7:11 | y | test.ps1:7:6:7:11 | ...,... [element 1] | provenance | | -| test.ps1:7:15:7:25 | Call to Join-String | test.ps1:8:6:8:7 | z | provenance | | +| test.ps1:7:15:7:25 | Call to join-string | test.ps1:8:6:8:7 | z | provenance | | nodes | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 0] | semmle.label | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 0] | | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 1] | semmle.label | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 1] | @@ -27,24 +27,24 @@ nodes | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | semmle.label | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | semmle.label | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | | file://:0:0:0:0 | [summary] to write: ReturnValue in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | semmle.label | [summary] to write: ReturnValue in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | -| test.ps1:1:6:1:15 | Call to Source | semmle.label | Call to Source | -| test.ps1:2:6:2:96 | Call to EscapeSingleQuotedStringContent | semmle.label | Call to EscapeSingleQuotedStringContent | +| test.ps1:1:6:1:15 | Call to source | semmle.label | Call to source | +| test.ps1:2:6:2:96 | Call to escapesinglequotedstringcontent | semmle.label | Call to escapesinglequotedstringcontent | | test.ps1:2:94:2:95 | x | semmle.label | x | | test.ps1:3:6:3:7 | y | semmle.label | y | -| test.ps1:5:6:5:15 | Call to Source | semmle.label | Call to Source | -| test.ps1:6:6:6:15 | Call to Source | semmle.label | Call to Source | +| test.ps1:5:6:5:15 | Call to source | semmle.label | Call to source | +| test.ps1:6:6:6:15 | Call to source | semmle.label | Call to source | | test.ps1:7:6:7:7 | x | semmle.label | x | | test.ps1:7:6:7:11 | ...,... [element 0] | semmle.label | ...,... [element 0] | | test.ps1:7:6:7:11 | ...,... [element 1] | semmle.label | ...,... [element 1] | | test.ps1:7:10:7:11 | y | semmle.label | y | -| test.ps1:7:15:7:25 | Call to Join-String | semmle.label | Call to Join-String | +| test.ps1:7:15:7:25 | Call to join-string | semmle.label | Call to join-string | | test.ps1:8:6:8:7 | z | semmle.label | z | subpaths -| test.ps1:2:94:2:95 | x | file://:0:0:0:0 | [summary param] pos(0, {}) in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | file://:0:0:0:0 | [summary] to write: ReturnValue in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | test.ps1:2:6:2:96 | Call to EscapeSingleQuotedStringContent | -| test.ps1:7:6:7:11 | ...,... [element 0] | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 0] | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | test.ps1:7:15:7:25 | Call to Join-String | -| test.ps1:7:6:7:11 | ...,... [element 1] | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 1] | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | test.ps1:7:15:7:25 | Call to Join-String | +| test.ps1:2:94:2:95 | x | file://:0:0:0:0 | [summary param] pos(0, {}) in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | file://:0:0:0:0 | [summary] to write: ReturnValue in system.management.automation.language.codegeneration!;Method[escapesinglequotedstringcontent] | test.ps1:2:6:2:96 | Call to escapesinglequotedstringcontent | +| test.ps1:7:6:7:11 | ...,... [element 0] | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 0] | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | test.ps1:7:15:7:25 | Call to join-string | +| test.ps1:7:6:7:11 | ...,... [element 1] | file://:0:0:0:0 | [summary param] pipeline in microsoft.powershell.utility!;Method[join-string] [element 1] | file://:0:0:0:0 | [summary] to write: ReturnValue in microsoft.powershell.utility!;Method[join-string] | test.ps1:7:15:7:25 | Call to join-string | testFailures #select -| test.ps1:3:6:3:7 | y | test.ps1:1:6:1:15 | Call to Source | test.ps1:3:6:3:7 | y | $@ | test.ps1:1:6:1:15 | Call to Source | Call to Source | -| test.ps1:8:6:8:7 | z | test.ps1:5:6:5:15 | Call to Source | test.ps1:8:6:8:7 | z | $@ | test.ps1:5:6:5:15 | Call to Source | Call to Source | -| test.ps1:8:6:8:7 | z | test.ps1:6:6:6:15 | Call to Source | test.ps1:8:6:8:7 | z | $@ | test.ps1:6:6:6:15 | Call to Source | Call to Source | +| test.ps1:3:6:3:7 | y | test.ps1:1:6:1:15 | Call to source | test.ps1:3:6:3:7 | y | $@ | test.ps1:1:6:1:15 | Call to source | Call to source | +| test.ps1:8:6:8:7 | z | test.ps1:5:6:5:15 | Call to source | test.ps1:8:6:8:7 | z | $@ | test.ps1:5:6:5:15 | Call to source | Call to source | +| test.ps1:8:6:8:7 | z | test.ps1:6:6:6:15 | Call to source | test.ps1:8:6:8:7 | z | $@ | test.ps1:6:6:6:15 | Call to source | Call to source | diff --git a/powershell/ql/test/library-tests/dataflow/params/test.expected b/powershell/ql/test/library-tests/dataflow/params/test.expected index d4009c646e9a..a14731c90c21 100644 --- a/powershell/ql/test/library-tests/dataflow/params/test.expected +++ b/powershell/ql/test/library-tests/dataflow/params/test.expected @@ -1,81 +1,77 @@ models edges -| global.ps1:1:7:1:22 | Source1 | global.ps1:3:6:3:13 | Source1 | provenance | | -| global.ps1:1:25:1:40 | Source2 | global.ps1:4:6:4:13 | Source2 | provenance | | -| global.ps1:1:43:1:58 | Source3 | global.ps1:5:6:5:13 | Source3 | provenance | | -| global.ps1:1:61:1:76 | Source4 | global.ps1:6:6:6:13 | Source4 | provenance | | | test.ps1:1:14:1:15 | a | test.ps1:2:10:2:11 | a | provenance | | -| test.ps1:5:6:5:15 | Call to Source | test.ps1:6:5:6:6 | x | provenance | | +| test.ps1:5:6:5:15 | Call to source | test.ps1:6:5:6:6 | x | provenance | | | test.ps1:6:5:6:6 | x | test.ps1:1:14:1:15 | a | provenance | | | test.ps1:8:20:8:21 | x | test.ps1:9:10:9:11 | x | provenance | | | test.ps1:8:24:8:25 | y | test.ps1:10:10:10:11 | y | provenance | | | test.ps1:8:28:8:29 | z | test.ps1:11:10:11:11 | z | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:18:11:18:16 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:19:22:19:27 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:20:14:20:19 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:21:11:21:16 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:22:22:22:27 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:23:22:23:27 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:24:14:24:19 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:25:11:25:16 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:26:22:26:27 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:27:22:27:27 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:28:14:28:19 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:29:11:29:16 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:30:32:30:37 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:31:32:31:37 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:32:14:32:19 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:33:11:33:16 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:34:32:34:37 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:35:32:35:37 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:36:32:36:37 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:37:24:37:29 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:38:21:38:26 | first | provenance | | -| test.ps1:14:10:14:19 | Call to Source | test.ps1:39:32:39:37 | first | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:18:18:18:24 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:19:11:19:17 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:20:21:20:27 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:21:21:21:27 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:22:14:22:20 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:23:11:23:17 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:24:21:24:27 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:25:21:25:27 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:26:14:26:20 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:27:11:27:17 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:28:31:28:37 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:29:21:29:27 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:30:14:30:20 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:31:11:31:17 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:32:31:32:37 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:33:31:33:37 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:34:14:34:20 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:35:24:35:30 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:36:21:36:27 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:37:31:37:37 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:38:31:38:37 | second | provenance | | -| test.ps1:15:11:15:20 | Call to Source | test.ps1:39:24:39:30 | second | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:18:26:18:31 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:19:29:19:34 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:20:29:20:34 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:21:29:21:34 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:22:29:22:34 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:23:32:23:37 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:24:32:24:37 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:25:32:25:37 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:26:32:26:37 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:27:32:27:37 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:28:24:28:29 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:29:32:29:37 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:30:25:30:30 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:31:22:31:27 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:32:24:32:29 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:33:21:33:26 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:34:25:34:30 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:35:14:35:19 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:36:14:36:19 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:37:14:37:19 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:38:14:38:19 | third | provenance | | -| test.ps1:16:10:16:19 | Call to Source | test.ps1:39:14:39:19 | third | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:18:11:18:16 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:19:22:19:27 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:20:14:20:19 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:21:11:21:16 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:22:22:22:27 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:23:22:23:27 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:24:14:24:19 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:25:11:25:16 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:26:22:26:27 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:27:22:27:27 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:28:14:28:19 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:29:11:29:16 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:30:32:30:37 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:31:32:31:37 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:32:14:32:19 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:33:11:33:16 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:34:32:34:37 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:35:32:35:37 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:36:32:36:37 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:37:24:37:29 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:38:21:38:26 | first | provenance | | +| test.ps1:14:10:14:19 | Call to source | test.ps1:39:32:39:37 | first | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:18:18:18:24 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:19:11:19:17 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:20:21:20:27 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:21:21:21:27 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:22:14:22:20 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:23:11:23:17 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:24:21:24:27 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:25:21:25:27 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:26:14:26:20 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:27:11:27:17 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:28:31:28:37 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:29:21:29:27 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:30:14:30:20 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:31:11:31:17 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:32:31:32:37 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:33:31:33:37 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:34:14:34:20 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:35:24:35:30 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:36:21:36:27 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:37:31:37:37 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:38:31:38:37 | second | provenance | | +| test.ps1:15:11:15:20 | Call to source | test.ps1:39:24:39:30 | second | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:18:26:18:31 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:19:29:19:34 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:20:29:20:34 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:21:29:21:34 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:22:29:22:34 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:23:32:23:37 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:24:32:24:37 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:25:32:25:37 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:26:32:26:37 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:27:32:27:37 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:28:24:28:29 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:29:32:29:37 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:30:25:30:30 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:31:22:31:27 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:32:24:32:29 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:33:21:33:26 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:34:25:34:30 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:35:14:35:19 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:36:14:36:19 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:37:14:37:19 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:38:14:38:19 | third | provenance | | +| test.ps1:16:10:16:19 | Call to source | test.ps1:39:14:39:19 | third | provenance | | | test.ps1:18:11:18:16 | first | test.ps1:8:20:8:21 | x | provenance | | | test.ps1:18:18:18:24 | second | test.ps1:8:24:8:25 | y | provenance | | | test.ps1:18:26:18:31 | third | test.ps1:8:28:8:29 | z | provenance | | @@ -142,21 +138,13 @@ edges | test.ps1:39:14:39:19 | third | test.ps1:8:28:8:29 | z | provenance | | | test.ps1:39:24:39:30 | second | test.ps1:8:24:8:25 | y | provenance | | | test.ps1:39:32:39:37 | first | test.ps1:8:20:8:21 | x | provenance | | -| test.ps1:43:11:43:20 | UserInput | test.ps1:44:10:44:19 | UserInput | provenance | | -| test.ps1:47:10:47:19 | Call to Source | test.ps1:48:46:48:51 | input | provenance | | -| test.ps1:48:46:48:51 | input | test.ps1:43:11:43:20 | UserInput | provenance | | +| test.ps1:43:11:43:20 | userinput | test.ps1:44:10:44:19 | UserInput | provenance | | +| test.ps1:47:10:47:19 | Call to source | test.ps1:48:46:48:51 | input | provenance | | +| test.ps1:48:46:48:51 | input | test.ps1:43:11:43:20 | userinput | provenance | | nodes -| global.ps1:1:7:1:22 | Source1 | semmle.label | Source1 | -| global.ps1:1:25:1:40 | Source2 | semmle.label | Source2 | -| global.ps1:1:43:1:58 | Source3 | semmle.label | Source3 | -| global.ps1:1:61:1:76 | Source4 | semmle.label | Source4 | -| global.ps1:3:6:3:13 | Source1 | semmle.label | Source1 | -| global.ps1:4:6:4:13 | Source2 | semmle.label | Source2 | -| global.ps1:5:6:5:13 | Source3 | semmle.label | Source3 | -| global.ps1:6:6:6:13 | Source4 | semmle.label | Source4 | | test.ps1:1:14:1:15 | a | semmle.label | a | | test.ps1:2:10:2:11 | a | semmle.label | a | -| test.ps1:5:6:5:15 | Call to Source | semmle.label | Call to Source | +| test.ps1:5:6:5:15 | Call to source | semmle.label | Call to source | | test.ps1:6:5:6:6 | x | semmle.label | x | | test.ps1:8:20:8:21 | x | semmle.label | x | | test.ps1:8:24:8:25 | y | semmle.label | y | @@ -164,9 +152,9 @@ nodes | test.ps1:9:10:9:11 | x | semmle.label | x | | test.ps1:10:10:10:11 | y | semmle.label | y | | test.ps1:11:10:11:11 | z | semmle.label | z | -| test.ps1:14:10:14:19 | Call to Source | semmle.label | Call to Source | -| test.ps1:15:11:15:20 | Call to Source | semmle.label | Call to Source | -| test.ps1:16:10:16:19 | Call to Source | semmle.label | Call to Source | +| test.ps1:14:10:14:19 | Call to source | semmle.label | Call to source | +| test.ps1:15:11:15:20 | Call to source | semmle.label | Call to source | +| test.ps1:16:10:16:19 | Call to source | semmle.label | Call to source | | test.ps1:18:11:18:16 | first | semmle.label | first | | test.ps1:18:18:18:24 | second | semmle.label | second | | test.ps1:18:26:18:31 | third | semmle.label | third | @@ -233,19 +221,19 @@ nodes | test.ps1:39:14:39:19 | third | semmle.label | third | | test.ps1:39:24:39:30 | second | semmle.label | second | | test.ps1:39:32:39:37 | first | semmle.label | first | -| test.ps1:43:11:43:20 | UserInput | semmle.label | UserInput | +| test.ps1:43:11:43:20 | userinput | semmle.label | userinput | | test.ps1:44:10:44:19 | UserInput | semmle.label | UserInput | -| test.ps1:47:10:47:19 | Call to Source | semmle.label | Call to Source | +| test.ps1:47:10:47:19 | Call to source | semmle.label | Call to source | | test.ps1:48:46:48:51 | input | semmle.label | input | subpaths testFailures +| global.ps1:3:15:3:32 | # $ hasValueFlow=1 | Missing result: hasValueFlow=1 | +| global.ps1:4:15:4:32 | # $ hasValueFlow=2 | Missing result: hasValueFlow=2 | +| global.ps1:5:15:5:32 | # $ hasValueFlow=3 | Missing result: hasValueFlow=3 | +| global.ps1:6:15:6:32 | # $ hasValueFlow=4 | Missing result: hasValueFlow=4 | #select -| global.ps1:3:6:3:13 | Source1 | global.ps1:1:7:1:22 | Source1 | global.ps1:3:6:3:13 | Source1 | $@ | global.ps1:1:7:1:22 | Source1 | Source1 | -| global.ps1:4:6:4:13 | Source2 | global.ps1:1:25:1:40 | Source2 | global.ps1:4:6:4:13 | Source2 | $@ | global.ps1:1:25:1:40 | Source2 | Source2 | -| global.ps1:5:6:5:13 | Source3 | global.ps1:1:43:1:58 | Source3 | global.ps1:5:6:5:13 | Source3 | $@ | global.ps1:1:43:1:58 | Source3 | Source3 | -| global.ps1:6:6:6:13 | Source4 | global.ps1:1:61:1:76 | Source4 | global.ps1:6:6:6:13 | Source4 | $@ | global.ps1:1:61:1:76 | Source4 | Source4 | -| test.ps1:2:10:2:11 | a | test.ps1:5:6:5:15 | Call to Source | test.ps1:2:10:2:11 | a | $@ | test.ps1:5:6:5:15 | Call to Source | Call to Source | -| test.ps1:9:10:9:11 | x | test.ps1:14:10:14:19 | Call to Source | test.ps1:9:10:9:11 | x | $@ | test.ps1:14:10:14:19 | Call to Source | Call to Source | -| test.ps1:10:10:10:11 | y | test.ps1:15:11:15:20 | Call to Source | test.ps1:10:10:10:11 | y | $@ | test.ps1:15:11:15:20 | Call to Source | Call to Source | -| test.ps1:11:10:11:11 | z | test.ps1:16:10:16:19 | Call to Source | test.ps1:11:10:11:11 | z | $@ | test.ps1:16:10:16:19 | Call to Source | Call to Source | -| test.ps1:44:10:44:19 | UserInput | test.ps1:47:10:47:19 | Call to Source | test.ps1:44:10:44:19 | UserInput | $@ | test.ps1:47:10:47:19 | Call to Source | Call to Source | +| test.ps1:2:10:2:11 | a | test.ps1:5:6:5:15 | Call to source | test.ps1:2:10:2:11 | a | $@ | test.ps1:5:6:5:15 | Call to source | Call to source | +| test.ps1:9:10:9:11 | x | test.ps1:14:10:14:19 | Call to source | test.ps1:9:10:9:11 | x | $@ | test.ps1:14:10:14:19 | Call to source | Call to source | +| test.ps1:10:10:10:11 | y | test.ps1:15:11:15:20 | Call to source | test.ps1:10:10:10:11 | y | $@ | test.ps1:15:11:15:20 | Call to source | Call to source | +| test.ps1:11:10:11:11 | z | test.ps1:16:10:16:19 | Call to source | test.ps1:11:10:11:11 | z | $@ | test.ps1:16:10:16:19 | Call to source | Call to source | +| test.ps1:44:10:44:19 | UserInput | test.ps1:47:10:47:19 | Call to source | test.ps1:44:10:44:19 | UserInput | $@ | test.ps1:47:10:47:19 | Call to source | Call to source | diff --git a/powershell/ql/test/library-tests/dataflow/pipeline/test.expected b/powershell/ql/test/library-tests/dataflow/pipeline/test.expected index b80489a6fae6..d446cea80050 100644 --- a/powershell/ql/test/library-tests/dataflow/pipeline/test.expected +++ b/powershell/ql/test/library-tests/dataflow/pipeline/test.expected @@ -1,8 +1,8 @@ models edges -| test.ps1:2:10:2:19 | Call to Source | test.ps1:5:5:5:6 | x | provenance | | -| test.ps1:3:10:3:19 | Call to Source | test.ps1:6:5:6:6 | y | provenance | | -| test.ps1:4:10:4:19 | Call to Source | test.ps1:6:9:6:10 | z | provenance | | +| test.ps1:2:10:2:19 | Call to source | test.ps1:5:5:5:6 | x | provenance | | +| test.ps1:3:10:3:19 | Call to source | test.ps1:6:5:6:6 | y | provenance | | +| test.ps1:4:10:4:19 | Call to source | test.ps1:6:9:6:10 | z | provenance | | | test.ps1:5:5:5:6 | x | test.ps1:17:1:17:7 | Call to produce [unknown index] | provenance | | | test.ps1:6:5:6:6 | y | test.ps1:17:1:17:7 | Call to produce [unknown index] | provenance | | | test.ps1:6:9:6:10 | z | test.ps1:17:1:17:7 | Call to produce [unknown index] | provenance | | @@ -13,8 +13,8 @@ edges | test.ps1:12:5:14:5 | x [element 1] | test.ps1:13:9:13:15 | __pipeline_iterator | provenance | | | test.ps1:12:5:14:5 | x [unknown index] | test.ps1:13:9:13:15 | __pipeline_iterator | provenance | | | test.ps1:17:1:17:7 | Call to produce [unknown index] | test.ps1:10:11:10:43 | x [unknown index] | provenance | | -| test.ps1:19:6:19:15 | Call to Source | test.ps1:21:1:21:2 | x | provenance | | -| test.ps1:20:6:20:15 | Call to Source | test.ps1:21:5:21:6 | y | provenance | | +| test.ps1:19:6:19:15 | Call to source | test.ps1:21:1:21:2 | x | provenance | | +| test.ps1:20:6:20:15 | Call to source | test.ps1:21:5:21:6 | y | provenance | | | test.ps1:21:1:21:2 | x | test.ps1:21:1:21:6 | ...,... [element 0] | provenance | | | test.ps1:21:1:21:6 | ...,... [element 0] | test.ps1:10:11:10:43 | x [element 0] | provenance | | | test.ps1:21:1:21:6 | ...,... [element 1] | test.ps1:10:11:10:43 | x [element 1] | provenance | | @@ -23,8 +23,8 @@ edges | test.ps1:23:38:27:1 | [synth] pipeline [element 1] | test.ps1:24:5:26:5 | [synth] pipeline [element 1] | provenance | | | test.ps1:24:5:26:5 | [synth] pipeline [element 0] | test.ps1:25:9:25:15 | __pipeline_iterator | provenance | | | test.ps1:24:5:26:5 | [synth] pipeline [element 1] | test.ps1:25:9:25:15 | __pipeline_iterator | provenance | | -| test.ps1:29:6:29:15 | Call to Source | test.ps1:31:1:31:2 | x | provenance | | -| test.ps1:30:6:30:15 | Call to Source | test.ps1:31:5:31:6 | y | provenance | | +| test.ps1:29:6:29:15 | Call to source | test.ps1:31:1:31:2 | x | provenance | | +| test.ps1:30:6:30:15 | Call to source | test.ps1:31:5:31:6 | y | provenance | | | test.ps1:31:1:31:2 | x | test.ps1:31:1:31:6 | ...,... [element 0] | provenance | | | test.ps1:31:1:31:6 | ...,... [element 0] | test.ps1:23:38:27:1 | [synth] pipeline [element 0] | provenance | | | test.ps1:31:1:31:6 | ...,... [element 1] | test.ps1:23:38:27:1 | [synth] pipeline [element 1] | provenance | | @@ -40,17 +40,17 @@ edges | test.ps1:50:1:50:105 | ...,... [element 1, element x] | test.ps1:43:11:43:57 | x [element 1, element x] | provenance | | | test.ps1:50:1:50:105 | ...,... [element 2, element x] | test.ps1:43:11:43:57 | x [element 2, element x] | provenance | | | test.ps1:50:17:50:33 | ${...} [element x] | test.ps1:50:1:50:33 | [...]... [element x] | provenance | | -| test.ps1:50:23:50:32 | Call to Source | test.ps1:50:17:50:33 | ${...} [element x] | provenance | | +| test.ps1:50:23:50:32 | Call to source | test.ps1:50:17:50:33 | ${...} [element x] | provenance | | | test.ps1:50:36:50:69 | [...]... [element x] | test.ps1:50:1:50:105 | ...,... [element 1, element x] | provenance | | | test.ps1:50:52:50:69 | ${...} [element x] | test.ps1:50:36:50:69 | [...]... [element x] | provenance | | -| test.ps1:50:58:50:68 | Call to Source | test.ps1:50:52:50:69 | ${...} [element x] | provenance | | +| test.ps1:50:58:50:68 | Call to source | test.ps1:50:52:50:69 | ${...} [element x] | provenance | | | test.ps1:50:72:50:105 | [...]... [element x] | test.ps1:50:1:50:105 | ...,... [element 2, element x] | provenance | | | test.ps1:50:88:50:105 | ${...} [element x] | test.ps1:50:72:50:105 | [...]... [element x] | provenance | | -| test.ps1:50:94:50:104 | Call to Source | test.ps1:50:88:50:105 | ${...} [element x] | provenance | | +| test.ps1:50:94:50:104 | Call to source | test.ps1:50:88:50:105 | ${...} [element x] | provenance | | nodes -| test.ps1:2:10:2:19 | Call to Source | semmle.label | Call to Source | -| test.ps1:3:10:3:19 | Call to Source | semmle.label | Call to Source | -| test.ps1:4:10:4:19 | Call to Source | semmle.label | Call to Source | +| test.ps1:2:10:2:19 | Call to source | semmle.label | Call to source | +| test.ps1:3:10:3:19 | Call to source | semmle.label | Call to source | +| test.ps1:4:10:4:19 | Call to source | semmle.label | Call to source | | test.ps1:5:5:5:6 | x | semmle.label | x | | test.ps1:6:5:6:6 | y | semmle.label | y | | test.ps1:6:9:6:10 | z | semmle.label | z | @@ -62,8 +62,8 @@ nodes | test.ps1:12:5:14:5 | x [unknown index] | semmle.label | x [unknown index] | | test.ps1:13:9:13:15 | __pipeline_iterator | semmle.label | __pipeline_iterator | | test.ps1:17:1:17:7 | Call to produce [unknown index] | semmle.label | Call to produce [unknown index] | -| test.ps1:19:6:19:15 | Call to Source | semmle.label | Call to Source | -| test.ps1:20:6:20:15 | Call to Source | semmle.label | Call to Source | +| test.ps1:19:6:19:15 | Call to source | semmle.label | Call to source | +| test.ps1:20:6:20:15 | Call to source | semmle.label | Call to source | | test.ps1:21:1:21:2 | x | semmle.label | x | | test.ps1:21:1:21:6 | ...,... [element 0] | semmle.label | ...,... [element 0] | | test.ps1:21:1:21:6 | ...,... [element 1] | semmle.label | ...,... [element 1] | @@ -73,8 +73,8 @@ nodes | test.ps1:24:5:26:5 | [synth] pipeline [element 0] | semmle.label | [synth] pipeline [element 0] | | test.ps1:24:5:26:5 | [synth] pipeline [element 1] | semmle.label | [synth] pipeline [element 1] | | test.ps1:25:9:25:15 | __pipeline_iterator | semmle.label | __pipeline_iterator | -| test.ps1:29:6:29:15 | Call to Source | semmle.label | Call to Source | -| test.ps1:30:6:30:15 | Call to Source | semmle.label | Call to Source | +| test.ps1:29:6:29:15 | Call to source | semmle.label | Call to source | +| test.ps1:30:6:30:15 | Call to source | semmle.label | Call to source | | test.ps1:31:1:31:2 | x | semmle.label | x | | test.ps1:31:1:31:6 | ...,... [element 0] | semmle.label | ...,... [element 0] | | test.ps1:31:1:31:6 | ...,... [element 1] | semmle.label | ...,... [element 1] | @@ -91,23 +91,23 @@ nodes | test.ps1:50:1:50:105 | ...,... [element 1, element x] | semmle.label | ...,... [element 1, element x] | | test.ps1:50:1:50:105 | ...,... [element 2, element x] | semmle.label | ...,... [element 2, element x] | | test.ps1:50:17:50:33 | ${...} [element x] | semmle.label | ${...} [element x] | -| test.ps1:50:23:50:32 | Call to Source | semmle.label | Call to Source | +| test.ps1:50:23:50:32 | Call to source | semmle.label | Call to source | | test.ps1:50:36:50:69 | [...]... [element x] | semmle.label | [...]... [element x] | | test.ps1:50:52:50:69 | ${...} [element x] | semmle.label | ${...} [element x] | -| test.ps1:50:58:50:68 | Call to Source | semmle.label | Call to Source | +| test.ps1:50:58:50:68 | Call to source | semmle.label | Call to source | | test.ps1:50:72:50:105 | [...]... [element x] | semmle.label | [...]... [element x] | | test.ps1:50:88:50:105 | ${...} [element x] | semmle.label | ${...} [element x] | -| test.ps1:50:94:50:104 | Call to Source | semmle.label | Call to Source | +| test.ps1:50:94:50:104 | Call to source | semmle.label | Call to source | subpaths testFailures #select -| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:2:10:2:19 | Call to Source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:2:10:2:19 | Call to Source | Call to Source | -| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:3:10:3:19 | Call to Source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:3:10:3:19 | Call to Source | Call to Source | -| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:4:10:4:19 | Call to Source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:4:10:4:19 | Call to Source | Call to Source | -| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:19:6:19:15 | Call to Source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:19:6:19:15 | Call to Source | Call to Source | -| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:20:6:20:15 | Call to Source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:20:6:20:15 | Call to Source | Call to Source | -| test.ps1:25:9:25:15 | __pipeline_iterator | test.ps1:29:6:29:15 | Call to Source | test.ps1:25:9:25:15 | __pipeline_iterator | $@ | test.ps1:29:6:29:15 | Call to Source | Call to Source | -| test.ps1:25:9:25:15 | __pipeline_iterator | test.ps1:30:6:30:15 | Call to Source | test.ps1:25:9:25:15 | __pipeline_iterator | $@ | test.ps1:30:6:30:15 | Call to Source | Call to Source | -| test.ps1:46:9:46:15 | __pipeline_iterator for x | test.ps1:50:23:50:32 | Call to Source | test.ps1:46:9:46:15 | __pipeline_iterator for x | $@ | test.ps1:50:23:50:32 | Call to Source | Call to Source | -| test.ps1:46:9:46:15 | __pipeline_iterator for x | test.ps1:50:58:50:68 | Call to Source | test.ps1:46:9:46:15 | __pipeline_iterator for x | $@ | test.ps1:50:58:50:68 | Call to Source | Call to Source | -| test.ps1:46:9:46:15 | __pipeline_iterator for x | test.ps1:50:94:50:104 | Call to Source | test.ps1:46:9:46:15 | __pipeline_iterator for x | $@ | test.ps1:50:94:50:104 | Call to Source | Call to Source | +| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:2:10:2:19 | Call to source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:2:10:2:19 | Call to source | Call to source | +| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:3:10:3:19 | Call to source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:3:10:3:19 | Call to source | Call to source | +| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:4:10:4:19 | Call to source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:4:10:4:19 | Call to source | Call to source | +| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:19:6:19:15 | Call to source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:19:6:19:15 | Call to source | Call to source | +| test.ps1:13:9:13:15 | __pipeline_iterator | test.ps1:20:6:20:15 | Call to source | test.ps1:13:9:13:15 | __pipeline_iterator | $@ | test.ps1:20:6:20:15 | Call to source | Call to source | +| test.ps1:25:9:25:15 | __pipeline_iterator | test.ps1:29:6:29:15 | Call to source | test.ps1:25:9:25:15 | __pipeline_iterator | $@ | test.ps1:29:6:29:15 | Call to source | Call to source | +| test.ps1:25:9:25:15 | __pipeline_iterator | test.ps1:30:6:30:15 | Call to source | test.ps1:25:9:25:15 | __pipeline_iterator | $@ | test.ps1:30:6:30:15 | Call to source | Call to source | +| test.ps1:46:9:46:15 | __pipeline_iterator for x | test.ps1:50:23:50:32 | Call to source | test.ps1:46:9:46:15 | __pipeline_iterator for x | $@ | test.ps1:50:23:50:32 | Call to source | Call to source | +| test.ps1:46:9:46:15 | __pipeline_iterator for x | test.ps1:50:58:50:68 | Call to source | test.ps1:46:9:46:15 | __pipeline_iterator for x | $@ | test.ps1:50:58:50:68 | Call to source | Call to source | +| test.ps1:46:9:46:15 | __pipeline_iterator for x | test.ps1:50:94:50:104 | Call to source | test.ps1:46:9:46:15 | __pipeline_iterator for x | $@ | test.ps1:50:94:50:104 | Call to source | Call to source | diff --git a/powershell/ql/test/library-tests/dataflow/returns/test.expected b/powershell/ql/test/library-tests/dataflow/returns/test.expected index 6de78912cc4f..fdfb0fcbff00 100644 --- a/powershell/ql/test/library-tests/dataflow/returns/test.expected +++ b/powershell/ql/test/library-tests/dataflow/returns/test.expected @@ -1,53 +1,53 @@ models edges -| test.ps1:2:5:2:14 | Call to Source | test.ps1:5:6:5:19 | Call to callSourceOnce | provenance | | -| test.ps1:5:6:5:19 | Call to callSourceOnce | test.ps1:6:6:6:7 | x | provenance | | -| test.ps1:9:5:9:14 | Call to Source | test.ps1:13:6:13:20 | Call to callSourceTwice [unknown index] | provenance | | -| test.ps1:10:5:10:14 | Call to Source | test.ps1:13:6:13:20 | Call to callSourceTwice [unknown index] | provenance | | -| test.ps1:13:6:13:20 | Call to callSourceTwice [unknown index] | test.ps1:15:6:15:7 | x [unknown index] | provenance | | -| test.ps1:13:6:13:20 | Call to callSourceTwice [unknown index] | test.ps1:16:6:16:7 | x [unknown index] | provenance | | +| test.ps1:2:5:2:14 | Call to source | test.ps1:5:6:5:19 | Call to callsourceonce | provenance | | +| test.ps1:5:6:5:19 | Call to callsourceonce | test.ps1:6:6:6:7 | x | provenance | | +| test.ps1:9:5:9:14 | Call to source | test.ps1:13:6:13:20 | Call to callsourcetwice [unknown index] | provenance | | +| test.ps1:10:5:10:14 | Call to source | test.ps1:13:6:13:20 | Call to callsourcetwice [unknown index] | provenance | | +| test.ps1:13:6:13:20 | Call to callsourcetwice [unknown index] | test.ps1:15:6:15:7 | x [unknown index] | provenance | | +| test.ps1:13:6:13:20 | Call to callsourcetwice [unknown index] | test.ps1:16:6:16:7 | x [unknown index] | provenance | | | test.ps1:15:6:15:7 | x [unknown index] | test.ps1:15:6:15:10 | ...[...] | provenance | | | test.ps1:16:6:16:7 | x [unknown index] | test.ps1:16:6:16:10 | ...[...] | provenance | | -| test.ps1:19:12:19:21 | Call to Source | test.ps1:22:6:22:18 | Call to returnSource1 | provenance | | -| test.ps1:22:6:22:18 | Call to returnSource1 | test.ps1:23:6:23:7 | x | provenance | | -| test.ps1:26:10:26:19 | Call to Source | test.ps1:27:5:27:6 | x | provenance | | -| test.ps1:27:5:27:6 | x | test.ps1:32:6:32:18 | Call to returnSource2 [unknown index] | provenance | | -| test.ps1:28:10:28:19 | Call to Source | test.ps1:29:12:29:13 | y | provenance | | -| test.ps1:29:12:29:13 | y | test.ps1:32:6:32:18 | Call to returnSource2 [unknown index] | provenance | | -| test.ps1:32:6:32:18 | Call to returnSource2 [unknown index] | test.ps1:33:6:33:7 | x [unknown index] | provenance | | -| test.ps1:32:6:32:18 | Call to returnSource2 [unknown index] | test.ps1:34:6:34:7 | x [unknown index] | provenance | | +| test.ps1:19:12:19:21 | Call to source | test.ps1:22:6:22:18 | Call to returnsource1 | provenance | | +| test.ps1:22:6:22:18 | Call to returnsource1 | test.ps1:23:6:23:7 | x | provenance | | +| test.ps1:26:10:26:19 | Call to source | test.ps1:27:5:27:6 | x | provenance | | +| test.ps1:27:5:27:6 | x | test.ps1:32:6:32:18 | Call to returnsource2 [unknown index] | provenance | | +| test.ps1:28:10:28:19 | Call to source | test.ps1:29:12:29:13 | y | provenance | | +| test.ps1:29:12:29:13 | y | test.ps1:32:6:32:18 | Call to returnsource2 [unknown index] | provenance | | +| test.ps1:32:6:32:18 | Call to returnsource2 [unknown index] | test.ps1:33:6:33:7 | x [unknown index] | provenance | | +| test.ps1:32:6:32:18 | Call to returnsource2 [unknown index] | test.ps1:34:6:34:7 | x [unknown index] | provenance | | | test.ps1:33:6:33:7 | x [unknown index] | test.ps1:33:6:33:10 | ...[...] | provenance | | | test.ps1:34:6:34:7 | x [unknown index] | test.ps1:34:6:34:10 | ...[...] | provenance | | -| test.ps1:38:9:38:18 | Call to Source | test.ps1:42:6:42:21 | Call to callSourceInLoop [unknown index] | provenance | | -| test.ps1:42:6:42:21 | Call to callSourceInLoop [unknown index] | test.ps1:43:6:43:7 | x [unknown index] | provenance | | -| test.ps1:42:6:42:21 | Call to callSourceInLoop [unknown index] | test.ps1:44:6:44:7 | x [unknown index] | provenance | | +| test.ps1:38:9:38:18 | Call to source | test.ps1:42:6:42:21 | Call to callsourceinloop [unknown index] | provenance | | +| test.ps1:42:6:42:21 | Call to callsourceinloop [unknown index] | test.ps1:43:6:43:7 | x [unknown index] | provenance | | +| test.ps1:42:6:42:21 | Call to callsourceinloop [unknown index] | test.ps1:44:6:44:7 | x [unknown index] | provenance | | | test.ps1:43:6:43:7 | x [unknown index] | test.ps1:43:6:43:10 | ...[...] | provenance | | | test.ps1:44:6:44:7 | x [unknown index] | test.ps1:44:6:44:10 | ...[...] | provenance | | nodes -| test.ps1:2:5:2:14 | Call to Source | semmle.label | Call to Source | -| test.ps1:5:6:5:19 | Call to callSourceOnce | semmle.label | Call to callSourceOnce | +| test.ps1:2:5:2:14 | Call to source | semmle.label | Call to source | +| test.ps1:5:6:5:19 | Call to callsourceonce | semmle.label | Call to callsourceonce | | test.ps1:6:6:6:7 | x | semmle.label | x | -| test.ps1:9:5:9:14 | Call to Source | semmle.label | Call to Source | -| test.ps1:10:5:10:14 | Call to Source | semmle.label | Call to Source | -| test.ps1:13:6:13:20 | Call to callSourceTwice [unknown index] | semmle.label | Call to callSourceTwice [unknown index] | +| test.ps1:9:5:9:14 | Call to source | semmle.label | Call to source | +| test.ps1:10:5:10:14 | Call to source | semmle.label | Call to source | +| test.ps1:13:6:13:20 | Call to callsourcetwice [unknown index] | semmle.label | Call to callsourcetwice [unknown index] | | test.ps1:15:6:15:7 | x [unknown index] | semmle.label | x [unknown index] | | test.ps1:15:6:15:10 | ...[...] | semmle.label | ...[...] | | test.ps1:16:6:16:7 | x [unknown index] | semmle.label | x [unknown index] | | test.ps1:16:6:16:10 | ...[...] | semmle.label | ...[...] | -| test.ps1:19:12:19:21 | Call to Source | semmle.label | Call to Source | -| test.ps1:22:6:22:18 | Call to returnSource1 | semmle.label | Call to returnSource1 | +| test.ps1:19:12:19:21 | Call to source | semmle.label | Call to source | +| test.ps1:22:6:22:18 | Call to returnsource1 | semmle.label | Call to returnsource1 | | test.ps1:23:6:23:7 | x | semmle.label | x | -| test.ps1:26:10:26:19 | Call to Source | semmle.label | Call to Source | +| test.ps1:26:10:26:19 | Call to source | semmle.label | Call to source | | test.ps1:27:5:27:6 | x | semmle.label | x | -| test.ps1:28:10:28:19 | Call to Source | semmle.label | Call to Source | +| test.ps1:28:10:28:19 | Call to source | semmle.label | Call to source | | test.ps1:29:12:29:13 | y | semmle.label | y | -| test.ps1:32:6:32:18 | Call to returnSource2 [unknown index] | semmle.label | Call to returnSource2 [unknown index] | +| test.ps1:32:6:32:18 | Call to returnsource2 [unknown index] | semmle.label | Call to returnsource2 [unknown index] | | test.ps1:33:6:33:7 | x [unknown index] | semmle.label | x [unknown index] | | test.ps1:33:6:33:10 | ...[...] | semmle.label | ...[...] | | test.ps1:34:6:34:7 | x [unknown index] | semmle.label | x [unknown index] | | test.ps1:34:6:34:10 | ...[...] | semmle.label | ...[...] | -| test.ps1:38:9:38:18 | Call to Source | semmle.label | Call to Source | -| test.ps1:42:6:42:21 | Call to callSourceInLoop [unknown index] | semmle.label | Call to callSourceInLoop [unknown index] | +| test.ps1:38:9:38:18 | Call to source | semmle.label | Call to source | +| test.ps1:42:6:42:21 | Call to callsourceinloop [unknown index] | semmle.label | Call to callsourceinloop [unknown index] | | test.ps1:43:6:43:7 | x [unknown index] | semmle.label | x [unknown index] | | test.ps1:43:6:43:10 | ...[...] | semmle.label | ...[...] | | test.ps1:44:6:44:7 | x [unknown index] | semmle.label | x [unknown index] | @@ -55,15 +55,15 @@ nodes subpaths testFailures #select -| test.ps1:6:6:6:7 | x | test.ps1:2:5:2:14 | Call to Source | test.ps1:6:6:6:7 | x | $@ | test.ps1:2:5:2:14 | Call to Source | Call to Source | -| test.ps1:15:6:15:10 | ...[...] | test.ps1:9:5:9:14 | Call to Source | test.ps1:15:6:15:10 | ...[...] | $@ | test.ps1:9:5:9:14 | Call to Source | Call to Source | -| test.ps1:15:6:15:10 | ...[...] | test.ps1:10:5:10:14 | Call to Source | test.ps1:15:6:15:10 | ...[...] | $@ | test.ps1:10:5:10:14 | Call to Source | Call to Source | -| test.ps1:16:6:16:10 | ...[...] | test.ps1:9:5:9:14 | Call to Source | test.ps1:16:6:16:10 | ...[...] | $@ | test.ps1:9:5:9:14 | Call to Source | Call to Source | -| test.ps1:16:6:16:10 | ...[...] | test.ps1:10:5:10:14 | Call to Source | test.ps1:16:6:16:10 | ...[...] | $@ | test.ps1:10:5:10:14 | Call to Source | Call to Source | -| test.ps1:23:6:23:7 | x | test.ps1:19:12:19:21 | Call to Source | test.ps1:23:6:23:7 | x | $@ | test.ps1:19:12:19:21 | Call to Source | Call to Source | -| test.ps1:33:6:33:10 | ...[...] | test.ps1:26:10:26:19 | Call to Source | test.ps1:33:6:33:10 | ...[...] | $@ | test.ps1:26:10:26:19 | Call to Source | Call to Source | -| test.ps1:33:6:33:10 | ...[...] | test.ps1:28:10:28:19 | Call to Source | test.ps1:33:6:33:10 | ...[...] | $@ | test.ps1:28:10:28:19 | Call to Source | Call to Source | -| test.ps1:34:6:34:10 | ...[...] | test.ps1:26:10:26:19 | Call to Source | test.ps1:34:6:34:10 | ...[...] | $@ | test.ps1:26:10:26:19 | Call to Source | Call to Source | -| test.ps1:34:6:34:10 | ...[...] | test.ps1:28:10:28:19 | Call to Source | test.ps1:34:6:34:10 | ...[...] | $@ | test.ps1:28:10:28:19 | Call to Source | Call to Source | -| test.ps1:43:6:43:10 | ...[...] | test.ps1:38:9:38:18 | Call to Source | test.ps1:43:6:43:10 | ...[...] | $@ | test.ps1:38:9:38:18 | Call to Source | Call to Source | -| test.ps1:44:6:44:10 | ...[...] | test.ps1:38:9:38:18 | Call to Source | test.ps1:44:6:44:10 | ...[...] | $@ | test.ps1:38:9:38:18 | Call to Source | Call to Source | +| test.ps1:6:6:6:7 | x | test.ps1:2:5:2:14 | Call to source | test.ps1:6:6:6:7 | x | $@ | test.ps1:2:5:2:14 | Call to source | Call to source | +| test.ps1:15:6:15:10 | ...[...] | test.ps1:9:5:9:14 | Call to source | test.ps1:15:6:15:10 | ...[...] | $@ | test.ps1:9:5:9:14 | Call to source | Call to source | +| test.ps1:15:6:15:10 | ...[...] | test.ps1:10:5:10:14 | Call to source | test.ps1:15:6:15:10 | ...[...] | $@ | test.ps1:10:5:10:14 | Call to source | Call to source | +| test.ps1:16:6:16:10 | ...[...] | test.ps1:9:5:9:14 | Call to source | test.ps1:16:6:16:10 | ...[...] | $@ | test.ps1:9:5:9:14 | Call to source | Call to source | +| test.ps1:16:6:16:10 | ...[...] | test.ps1:10:5:10:14 | Call to source | test.ps1:16:6:16:10 | ...[...] | $@ | test.ps1:10:5:10:14 | Call to source | Call to source | +| test.ps1:23:6:23:7 | x | test.ps1:19:12:19:21 | Call to source | test.ps1:23:6:23:7 | x | $@ | test.ps1:19:12:19:21 | Call to source | Call to source | +| test.ps1:33:6:33:10 | ...[...] | test.ps1:26:10:26:19 | Call to source | test.ps1:33:6:33:10 | ...[...] | $@ | test.ps1:26:10:26:19 | Call to source | Call to source | +| test.ps1:33:6:33:10 | ...[...] | test.ps1:28:10:28:19 | Call to source | test.ps1:33:6:33:10 | ...[...] | $@ | test.ps1:28:10:28:19 | Call to source | Call to source | +| test.ps1:34:6:34:10 | ...[...] | test.ps1:26:10:26:19 | Call to source | test.ps1:34:6:34:10 | ...[...] | $@ | test.ps1:26:10:26:19 | Call to source | Call to source | +| test.ps1:34:6:34:10 | ...[...] | test.ps1:28:10:28:19 | Call to source | test.ps1:34:6:34:10 | ...[...] | $@ | test.ps1:28:10:28:19 | Call to source | Call to source | +| test.ps1:43:6:43:10 | ...[...] | test.ps1:38:9:38:18 | Call to source | test.ps1:43:6:43:10 | ...[...] | $@ | test.ps1:38:9:38:18 | Call to source | Call to source | +| test.ps1:44:6:44:10 | ...[...] | test.ps1:38:9:38:18 | Call to source | test.ps1:44:6:44:10 | ...[...] | $@ | test.ps1:38:9:38:18 | Call to source | Call to source | diff --git a/powershell/ql/test/library-tests/dataflow/typetracking/test.ql b/powershell/ql/test/library-tests/dataflow/typetracking/test.ql index b6874e7e4372..3a8c9e995399 100644 --- a/powershell/ql/test/library-tests/dataflow/typetracking/test.ql +++ b/powershell/ql/test/library-tests/dataflow/typetracking/test.ql @@ -14,7 +14,7 @@ module TypeTrackingTest implements TestSig { tag = "type" and n = trackInstance(value, _) and isArgumentNode(n, c, _) and - c.asCall().hasName("Sink") + c.asCall().matchesName("Sink") ) } } diff --git a/powershell/ql/test/query-tests/security/ConvertToSecureStringAsPlainText/ConvertToSecureStringAsPlainText.expected b/powershell/ql/test/query-tests/security/ConvertToSecureStringAsPlainText/ConvertToSecureStringAsPlainText.expected index b4c57fada788..fbc89dbb524d 100644 --- a/powershell/ql/test/query-tests/security/ConvertToSecureStringAsPlainText/ConvertToSecureStringAsPlainText.expected +++ b/powershell/ql/test/query-tests/security/ConvertToSecureStringAsPlainText/ConvertToSecureStringAsPlainText.expected @@ -1 +1 @@ -| test.ps1:2:19:2:79 | Call to ConvertTo-SecureString | Use of AsPlainText parameter in ConvertTo-SecureString call | +| test.ps1:2:19:2:79 | Call to convertto-securestring | Use of AsPlainText parameter in ConvertTo-SecureString call | diff --git a/powershell/ql/test/query-tests/security/UsernameOrPasswordParameter/UsernameOrPasswordParameter.expected b/powershell/ql/test/query-tests/security/UsernameOrPasswordParameter/UsernameOrPasswordParameter.expected index 4f7b31c151d2..6861f82a7cea 100644 --- a/powershell/ql/test/query-tests/security/UsernameOrPasswordParameter/UsernameOrPasswordParameter.expected +++ b/powershell/ql/test/query-tests/security/UsernameOrPasswordParameter/UsernameOrPasswordParameter.expected @@ -1,2 +1,2 @@ -| test.ps1:6:9:7:17 | Username | Do not use username or password parameters. | -| test.ps1:8:9:9:17 | Password | Do not use username or password parameters. | +| test.ps1:6:9:7:17 | username | Do not use username or password parameters. | +| test.ps1:8:9:9:17 | password | Do not use username or password parameters. | diff --git a/powershell/ql/test/query-tests/security/cwe-078/CommandInjection/CommandInjection.expected b/powershell/ql/test/query-tests/security/cwe-078/CommandInjection/CommandInjection.expected index e8e97671e550..170202930186 100644 --- a/powershell/ql/test/query-tests/security/cwe-078/CommandInjection/CommandInjection.expected +++ b/powershell/ql/test/query-tests/security/cwe-078/CommandInjection/CommandInjection.expected @@ -1,100 +1,100 @@ edges -| test.ps1:3:11:3:20 | UserInput | test.ps1:4:23:4:52 | Get-Process -Name $UserInput | provenance | | -| test.ps1:9:11:9:20 | UserInput | test.ps1:10:9:10:38 | Get-Process -Name $UserInput | provenance | | -| test.ps1:15:11:15:20 | UserInput | test.ps1:16:50:16:79 | Get-Process -Name $UserInput | provenance | | -| test.ps1:21:11:21:20 | UserInput | test.ps1:22:41:22:70 | Get-Process -Name $UserInput | provenance | | -| test.ps1:21:11:21:20 | UserInput | test.ps1:22:60:22:69 | UserInput | provenance | | -| test.ps1:27:11:27:20 | UserInput | test.ps1:28:38:28:67 | Get-Process -Name $UserInput | provenance | | -| test.ps1:27:11:27:20 | UserInput | test.ps1:28:57:28:66 | UserInput | provenance | | -| test.ps1:33:11:33:20 | UserInput | test.ps1:34:14:34:46 | public class Foo { $UserInput } | provenance | | -| test.ps1:39:11:39:20 | UserInput | test.ps1:40:30:40:62 | public class Foo { $UserInput } | provenance | | -| test.ps1:45:11:45:20 | UserInput | test.ps1:48:30:48:34 | code | provenance | | -| test.ps1:73:11:73:20 | UserInput | test.ps1:75:25:75:54 | Get-Process -Name $UserInput | provenance | | -| test.ps1:80:11:80:20 | UserInput | test.ps1:82:16:82:45 | Get-Process -Name $UserInput | provenance | | -| test.ps1:87:11:87:20 | UserInput | test.ps1:89:12:89:28 | ping $UserInput | provenance | | -| test.ps1:94:11:94:20 | UserInput | test.ps1:98:33:98:62 | Get-Process -Name $UserInput | provenance | | -| test.ps1:104:11:104:20 | UserInput | test.ps1:108:58:108:87 | Get-Process -Name $UserInput | provenance | | -| test.ps1:114:11:114:20 | UserInput | test.ps1:116:34:116:43 | UserInput | provenance | | -| test.ps1:121:11:121:20 | UserInput | test.ps1:123:28:123:37 | UserInput | provenance | | -| test.ps1:128:11:128:20 | UserInput | test.ps1:130:28:130:37 | UserInput | provenance | | -| test.ps1:136:11:136:20 | UserInput | test.ps1:139:50:139:59 | UserInput | provenance | | -| test.ps1:144:11:144:20 | UserInput | test.ps1:147:63:147:72 | UserInput | provenance | | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:154:46:154:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:155:46:155:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:156:46:156:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:157:46:157:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:158:46:158:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:159:46:159:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:160:46:160:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:161:46:161:51 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:163:48:163:53 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:164:48:164:53 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:165:48:165:53 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:166:41:166:46 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:167:41:167:46 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:168:36:168:41 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:169:36:169:41 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:170:36:170:41 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:172:42:172:47 | input | provenance | Src:MaD:11464 | -| test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:173:42:173:47 | input | provenance | Src:MaD:11464 | -| test.ps1:154:46:154:51 | input | test.ps1:3:11:3:20 | UserInput | provenance | | -| test.ps1:155:46:155:51 | input | test.ps1:9:11:9:20 | UserInput | provenance | | -| test.ps1:156:46:156:51 | input | test.ps1:15:11:15:20 | UserInput | provenance | | -| test.ps1:157:46:157:51 | input | test.ps1:21:11:21:20 | UserInput | provenance | | -| test.ps1:158:46:158:51 | input | test.ps1:27:11:27:20 | UserInput | provenance | | -| test.ps1:159:46:159:51 | input | test.ps1:33:11:33:20 | UserInput | provenance | | -| test.ps1:160:46:160:51 | input | test.ps1:39:11:39:20 | UserInput | provenance | | -| test.ps1:161:46:161:51 | input | test.ps1:45:11:45:20 | UserInput | provenance | | -| test.ps1:163:48:163:53 | input | test.ps1:73:11:73:20 | UserInput | provenance | | -| test.ps1:164:48:164:53 | input | test.ps1:80:11:80:20 | UserInput | provenance | | -| test.ps1:165:48:165:53 | input | test.ps1:87:11:87:20 | UserInput | provenance | | -| test.ps1:166:41:166:46 | input | test.ps1:94:11:94:20 | UserInput | provenance | | -| test.ps1:167:41:167:46 | input | test.ps1:104:11:104:20 | UserInput | provenance | | -| test.ps1:168:36:168:41 | input | test.ps1:114:11:114:20 | UserInput | provenance | | -| test.ps1:169:36:169:41 | input | test.ps1:121:11:121:20 | UserInput | provenance | | -| test.ps1:170:36:170:41 | input | test.ps1:128:11:128:20 | UserInput | provenance | | -| test.ps1:172:42:172:47 | input | test.ps1:136:11:136:20 | UserInput | provenance | | -| test.ps1:173:42:173:47 | input | test.ps1:144:11:144:20 | UserInput | provenance | | +| test.ps1:3:11:3:20 | userinput | test.ps1:4:23:4:52 | Get-Process -Name $UserInput | provenance | | +| test.ps1:9:11:9:20 | userinput | test.ps1:10:9:10:38 | Get-Process -Name $UserInput | provenance | | +| test.ps1:15:11:15:20 | userinput | test.ps1:16:50:16:79 | Get-Process -Name $UserInput | provenance | | +| test.ps1:21:11:21:20 | userinput | test.ps1:22:41:22:70 | Get-Process -Name $UserInput | provenance | | +| test.ps1:21:11:21:20 | userinput | test.ps1:22:60:22:69 | UserInput | provenance | | +| test.ps1:27:11:27:20 | userinput | test.ps1:28:38:28:67 | Get-Process -Name $UserInput | provenance | | +| test.ps1:27:11:27:20 | userinput | test.ps1:28:57:28:66 | UserInput | provenance | | +| test.ps1:33:11:33:20 | userinput | test.ps1:34:14:34:46 | public class Foo { $UserInput } | provenance | | +| test.ps1:39:11:39:20 | userinput | test.ps1:40:30:40:62 | public class Foo { $UserInput } | provenance | | +| test.ps1:45:11:45:20 | userinput | test.ps1:48:30:48:34 | code | provenance | | +| test.ps1:73:11:73:20 | userinput | test.ps1:75:25:75:54 | Get-Process -Name $UserInput | provenance | | +| test.ps1:80:11:80:20 | userinput | test.ps1:82:16:82:45 | Get-Process -Name $UserInput | provenance | | +| test.ps1:87:11:87:20 | userinput | test.ps1:89:12:89:28 | ping $UserInput | provenance | | +| test.ps1:94:11:94:20 | userinput | test.ps1:98:33:98:62 | Get-Process -Name $UserInput | provenance | | +| test.ps1:104:11:104:20 | userinput | test.ps1:108:58:108:87 | Get-Process -Name $UserInput | provenance | | +| test.ps1:114:11:114:20 | userinput | test.ps1:116:34:116:43 | UserInput | provenance | | +| test.ps1:121:11:121:20 | userinput | test.ps1:123:28:123:37 | UserInput | provenance | | +| test.ps1:128:11:128:20 | userinput | test.ps1:130:28:130:37 | UserInput | provenance | | +| test.ps1:136:11:136:20 | userinput | test.ps1:139:50:139:59 | UserInput | provenance | | +| test.ps1:144:11:144:20 | userinput | test.ps1:147:63:147:72 | UserInput | provenance | | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:154:46:154:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:155:46:155:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:156:46:156:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:157:46:157:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:158:46:158:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:159:46:159:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:160:46:160:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:161:46:161:51 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:163:48:163:53 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:164:48:164:53 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:165:48:165:53 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:166:41:166:46 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:167:41:167:46 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:168:36:168:41 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:169:36:169:41 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:170:36:170:41 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:172:42:172:47 | input | provenance | Src:MaD:11464 | +| test.ps1:152:10:152:32 | Call to read-host | test.ps1:173:42:173:47 | input | provenance | Src:MaD:11464 | +| test.ps1:154:46:154:51 | input | test.ps1:3:11:3:20 | userinput | provenance | | +| test.ps1:155:46:155:51 | input | test.ps1:9:11:9:20 | userinput | provenance | | +| test.ps1:156:46:156:51 | input | test.ps1:15:11:15:20 | userinput | provenance | | +| test.ps1:157:46:157:51 | input | test.ps1:21:11:21:20 | userinput | provenance | | +| test.ps1:158:46:158:51 | input | test.ps1:27:11:27:20 | userinput | provenance | | +| test.ps1:159:46:159:51 | input | test.ps1:33:11:33:20 | userinput | provenance | | +| test.ps1:160:46:160:51 | input | test.ps1:39:11:39:20 | userinput | provenance | | +| test.ps1:161:46:161:51 | input | test.ps1:45:11:45:20 | userinput | provenance | | +| test.ps1:163:48:163:53 | input | test.ps1:73:11:73:20 | userinput | provenance | | +| test.ps1:164:48:164:53 | input | test.ps1:80:11:80:20 | userinput | provenance | | +| test.ps1:165:48:165:53 | input | test.ps1:87:11:87:20 | userinput | provenance | | +| test.ps1:166:41:166:46 | input | test.ps1:94:11:94:20 | userinput | provenance | | +| test.ps1:167:41:167:46 | input | test.ps1:104:11:104:20 | userinput | provenance | | +| test.ps1:168:36:168:41 | input | test.ps1:114:11:114:20 | userinput | provenance | | +| test.ps1:169:36:169:41 | input | test.ps1:121:11:121:20 | userinput | provenance | | +| test.ps1:170:36:170:41 | input | test.ps1:128:11:128:20 | userinput | provenance | | +| test.ps1:172:42:172:47 | input | test.ps1:136:11:136:20 | userinput | provenance | | +| test.ps1:173:42:173:47 | input | test.ps1:144:11:144:20 | userinput | provenance | | nodes -| test.ps1:3:11:3:20 | UserInput | semmle.label | UserInput | +| test.ps1:3:11:3:20 | userinput | semmle.label | userinput | | test.ps1:4:23:4:52 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | -| test.ps1:9:11:9:20 | UserInput | semmle.label | UserInput | +| test.ps1:9:11:9:20 | userinput | semmle.label | userinput | | test.ps1:10:9:10:38 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | -| test.ps1:15:11:15:20 | UserInput | semmle.label | UserInput | +| test.ps1:15:11:15:20 | userinput | semmle.label | userinput | | test.ps1:16:50:16:79 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | -| test.ps1:21:11:21:20 | UserInput | semmle.label | UserInput | +| test.ps1:21:11:21:20 | userinput | semmle.label | userinput | | test.ps1:22:41:22:70 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | | test.ps1:22:60:22:69 | UserInput | semmle.label | UserInput | -| test.ps1:27:11:27:20 | UserInput | semmle.label | UserInput | +| test.ps1:27:11:27:20 | userinput | semmle.label | userinput | | test.ps1:28:38:28:67 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | | test.ps1:28:57:28:66 | UserInput | semmle.label | UserInput | -| test.ps1:33:11:33:20 | UserInput | semmle.label | UserInput | +| test.ps1:33:11:33:20 | userinput | semmle.label | userinput | | test.ps1:34:14:34:46 | public class Foo { $UserInput } | semmle.label | public class Foo { $UserInput } | -| test.ps1:39:11:39:20 | UserInput | semmle.label | UserInput | +| test.ps1:39:11:39:20 | userinput | semmle.label | userinput | | test.ps1:40:30:40:62 | public class Foo { $UserInput } | semmle.label | public class Foo { $UserInput } | -| test.ps1:45:11:45:20 | UserInput | semmle.label | UserInput | +| test.ps1:45:11:45:20 | userinput | semmle.label | userinput | | test.ps1:48:30:48:34 | code | semmle.label | code | -| test.ps1:73:11:73:20 | UserInput | semmle.label | UserInput | +| test.ps1:73:11:73:20 | userinput | semmle.label | userinput | | test.ps1:75:25:75:54 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | -| test.ps1:80:11:80:20 | UserInput | semmle.label | UserInput | +| test.ps1:80:11:80:20 | userinput | semmle.label | userinput | | test.ps1:82:16:82:45 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | -| test.ps1:87:11:87:20 | UserInput | semmle.label | UserInput | +| test.ps1:87:11:87:20 | userinput | semmle.label | userinput | | test.ps1:89:12:89:28 | ping $UserInput | semmle.label | ping $UserInput | -| test.ps1:94:11:94:20 | UserInput | semmle.label | UserInput | +| test.ps1:94:11:94:20 | userinput | semmle.label | userinput | | test.ps1:98:33:98:62 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | -| test.ps1:104:11:104:20 | UserInput | semmle.label | UserInput | +| test.ps1:104:11:104:20 | userinput | semmle.label | userinput | | test.ps1:108:58:108:87 | Get-Process -Name $UserInput | semmle.label | Get-Process -Name $UserInput | -| test.ps1:114:11:114:20 | UserInput | semmle.label | UserInput | +| test.ps1:114:11:114:20 | userinput | semmle.label | userinput | | test.ps1:116:34:116:43 | UserInput | semmle.label | UserInput | -| test.ps1:121:11:121:20 | UserInput | semmle.label | UserInput | +| test.ps1:121:11:121:20 | userinput | semmle.label | userinput | | test.ps1:123:28:123:37 | UserInput | semmle.label | UserInput | -| test.ps1:128:11:128:20 | UserInput | semmle.label | UserInput | +| test.ps1:128:11:128:20 | userinput | semmle.label | userinput | | test.ps1:130:28:130:37 | UserInput | semmle.label | UserInput | -| test.ps1:136:11:136:20 | UserInput | semmle.label | UserInput | +| test.ps1:136:11:136:20 | userinput | semmle.label | userinput | | test.ps1:139:50:139:59 | UserInput | semmle.label | UserInput | -| test.ps1:144:11:144:20 | UserInput | semmle.label | UserInput | +| test.ps1:144:11:144:20 | userinput | semmle.label | userinput | | test.ps1:147:63:147:72 | UserInput | semmle.label | UserInput | -| test.ps1:152:10:152:32 | Call to Read-Host | semmle.label | Call to Read-Host | +| test.ps1:152:10:152:32 | Call to read-host | semmle.label | Call to read-host | | test.ps1:154:46:154:51 | input | semmle.label | input | | test.ps1:155:46:155:51 | input | semmle.label | input | | test.ps1:156:46:156:51 | input | semmle.label | input | @@ -115,23 +115,23 @@ nodes | test.ps1:173:42:173:47 | input | semmle.label | input | subpaths #select -| test.ps1:4:23:4:52 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:4:23:4:52 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:10:9:10:38 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:10:9:10:38 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:16:50:16:79 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:16:50:16:79 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:22:41:22:70 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:22:41:22:70 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:22:60:22:69 | UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:22:60:22:69 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:28:38:28:67 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:28:38:28:67 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:28:57:28:66 | UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:28:57:28:66 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:34:14:34:46 | public class Foo { $UserInput } | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:34:14:34:46 | public class Foo { $UserInput } | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:40:30:40:62 | public class Foo { $UserInput } | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:40:30:40:62 | public class Foo { $UserInput } | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:48:30:48:34 | code | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:48:30:48:34 | code | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:75:25:75:54 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:75:25:75:54 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:82:16:82:45 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:82:16:82:45 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:89:12:89:28 | ping $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:89:12:89:28 | ping $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:98:33:98:62 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:98:33:98:62 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:108:58:108:87 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:108:58:108:87 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:116:34:116:43 | UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:116:34:116:43 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:123:28:123:37 | UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:123:28:123:37 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:130:28:130:37 | UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:130:28:130:37 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:139:50:139:59 | UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:139:50:139:59 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | -| test.ps1:147:63:147:72 | UserInput | test.ps1:152:10:152:32 | Call to Read-Host | test.ps1:147:63:147:72 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to Read-Host | user-provided value | +| test.ps1:4:23:4:52 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:4:23:4:52 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:10:9:10:38 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:10:9:10:38 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:16:50:16:79 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:16:50:16:79 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:22:41:22:70 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:22:41:22:70 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:22:60:22:69 | UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:22:60:22:69 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:28:38:28:67 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:28:38:28:67 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:28:57:28:66 | UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:28:57:28:66 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:34:14:34:46 | public class Foo { $UserInput } | test.ps1:152:10:152:32 | Call to read-host | test.ps1:34:14:34:46 | public class Foo { $UserInput } | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:40:30:40:62 | public class Foo { $UserInput } | test.ps1:152:10:152:32 | Call to read-host | test.ps1:40:30:40:62 | public class Foo { $UserInput } | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:48:30:48:34 | code | test.ps1:152:10:152:32 | Call to read-host | test.ps1:48:30:48:34 | code | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:75:25:75:54 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:75:25:75:54 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:82:16:82:45 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:82:16:82:45 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:89:12:89:28 | ping $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:89:12:89:28 | ping $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:98:33:98:62 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:98:33:98:62 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:108:58:108:87 | Get-Process -Name $UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:108:58:108:87 | Get-Process -Name $UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:116:34:116:43 | UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:116:34:116:43 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:123:28:123:37 | UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:123:28:123:37 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:130:28:130:37 | UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:130:28:130:37 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:139:50:139:59 | UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:139:50:139:59 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | +| test.ps1:147:63:147:72 | UserInput | test.ps1:152:10:152:32 | Call to read-host | test.ps1:147:63:147:72 | UserInput | This command depends on a $@. | test.ps1:152:10:152:32 | Call to read-host | user-provided value | diff --git a/powershell/ql/test/query-tests/security/cwe-078/DoNotUseInvokeExpression/DoNotUseInvokeExpression.expected b/powershell/ql/test/query-tests/security/cwe-078/DoNotUseInvokeExpression/DoNotUseInvokeExpression.expected index 738c250420e5..3d7443847750 100644 --- a/powershell/ql/test/query-tests/security/cwe-078/DoNotUseInvokeExpression/DoNotUseInvokeExpression.expected +++ b/powershell/ql/test/query-tests/security/cwe-078/DoNotUseInvokeExpression/DoNotUseInvokeExpression.expected @@ -1 +1 @@ -| test.ps1:2:1:2:26 | Call to Invoke-Expression | Do not use Invoke-Expression. It is a command injection risk. | +| test.ps1:2:1:2:26 | Call to invoke-expression | Do not use Invoke-Expression. It is a command injection risk. |