[Soot-list] Doubts about flowdroid

Sri Shaila G sg001 at ucr.edu
Fri Feb 9 11:00:28 EST 2018


Hi Steven,

I have 2 doubts regarding how flowdroid works.

Firstly, I created a simple android application that makes a function call
to get the deviceID from the phone and passes the value as a string to
another function which will write the value into a logfile. The code
snippet is as follows

TelephonyManager manager = (TelephonyManager)
getSystemService(Context.TELEPHONY_SERVICE);
String deviceid = manager.getDeviceId();
//Device Id is IMEI number
Log.d("msg", "Device id" + deviceid);
System.out.println("msg Device id" + deviceid);
//callFunc
myFunc(deviceid);

public boolean myFunc(String info) {
    Log.d("msg", "Device id" + info);
    System.out.println("msg Device id++++" );
    return true;
}


However, it looks like flowdroid is not able to find the flow from the
source function,

getDeviceId() to the sink function, d("msg", "Device id" + info). I am
wondering why this might be the reason.


Secondly, I had inserted some print statements under the run function
in the IFDSSolver.java file as shown below.

if(icfg.isExitStmt(edge.getTarget())
{
	System.out.println("run(): ExitStmt: "+"edge: factAtSrc: " +
edge.factAtSource()+" getTgt: "+edge.getTarget()+" factAtTgt:
"+edge.factAtTarget());
        processExit(edge);
}

When I look at the output, I saw some statements like the following statements.

run(): ExitStmt: edge: factAtSrc: zero(null_type) <+length> | >> getTgt:
$r0 := @this: com.android.tools.fd.runtime.BootstrapApplication factAtTgt:
_$r1(android.app.Application$OnProvideAssistDataListener) * <+length> | $r1
:= @parameter0: android.app.Application$OnProvideAssistDataListener>>

This statement  does not look like an exit statement. I am wondering
why it is considered as an exit statement. An exit statement is
usually a return statement right?

Thank you so much for any clarifications.

Regards
Shaila
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20180209/59a435ad/attachment-0001.html>


More information about the Soot-list mailing list