[Soot-list] Can I get the calling context of a source/sink?

润青杨 rainkin1993 at gmail.com
Fri Jun 12 11:47:59 EDT 2015


Hi guys,
    Flowdroid uses Heros to do inter-procedural data analysis. I notice
that during the process of inter-procedural analysis, Flowdroid can get the
calling context of a function, that is to say, where the function is
actually called.
    For example, the API
    getReturnFlowFunction(N callSite, M calleeMethod, N exitStmt, N
returnSite):
    callSite is the statement where the function is called.


    But in the results of Flowdroid, I can't get the calling context of a
source/sink.
    I want to know how to get that?

For example.

ApiTwo sharedApiTwo(ApiOne x)

{

return apiTwo(x);

}

main(){

// context1

a1 = apiOne();

b1 = sharedApiOne(a1);

apiThree(b1);



// context2

a2 = apiOne();

b2 = sharedApiOne(a2);

apiThree(b2);

}



Note that there is a wrapper function sharedApiTwo() for apiTwo().
we will get the following result:

Source

Sink

a1 = apiOne();

return apiTwo(x);

return apiTwo(x);

apiThree(b1);

a2 = apiOne();

return apiTwo(x);

return apiTwo(x);

apiThree(b2);

Take the first source-sink chain for example,
I can't know the function of the sink "return apiTwo(x)" is called in the
statement "b1 = sharedApiOne(a1);"

Thank,
rainkin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20150612/13dd8fa4/attachment-0001.html 


More information about the Soot-list mailing list