Skip to content

General issue - Help needed to get data flow involving variables associated with functions #4487

@SaumoPal97

Description

@SaumoPal97

I am applying local dataflow, global dataflow as well as taint tracking to obtain the variables affecting an expression but I am unable to do so. I found this tutorial on dataflows (https://help.semmle.com/QL/ql-training/java/global-data-flow-java.html#8) and on slide 8, I found a similar problem to the one I am facing.
name = ai.getProxy().getNamespace(); return compileAndExecute(name, context, ....);
So according to taint tracking module, we can say name or the first argument of compileAndExecute(...) is tainted by getProxy(...) and getNamespace(...) but not by ai variable, where source is a method (https://help.semmle.com/QL/ql-training/java/global-data-flow-java.html#10) and sink is the first argument (https://help.semmle.com/QL/ql-training/java/global-data-flow-java.html#12), which makes sense. But on changing the source to be any expr, I am unable to obtain ai variable as source. So I wanted to know how can I get ai as the source while doing taint tracking. I checked the documentation here (https://help.semmle.com/qldoc/java/semmle/code/java/dataflow/TaintTracking.qll/module.TaintTracking$TaintTracking.html) but did not find sufficient help. Any explanation or tutorial will be appreciated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions