[Soot-list] InfoFlow Ignores Invokes?

Mathias Ricken mgricken at rice.edu
Fri Apr 16 18:02:00 EDT 2010


Hi!

I'm trying to use the soot.jimple.toolkits.infoflow package to
determine where locals were created. For example, in the method below
I want to find out where the argument to invokeLater came from.

public void startInMethod(Runnable p) {
  Runnable l;
  if (Math.random()*2<1) { l = new Runnable() { ... }; }
  else if (Math.random()*2<1) { l = returnARunnable(); }
  else { l = p; }
  java.awt.EventQueue.invokeLater(l);
}

The set of sources of l, the argument to invokeLater, should be p, new
Runnable() { ... }, and returnARunnable(). I'm getting p and the new
operation as sources, but the return value of invoking
returnARunnable() is being ignored.

In a simpler version of the example above, I'm getting no sources at
all for the l:

public void startInMethod(Runnable p) {
  Runnable l = returnARunnable();
  java.awt.EventQueue.invokeLater(l);
}

Is the infoflow package just not set up to report return values of
method calls as sources (or to inter-procedurally inspect the called
methods), or am I doing something wrong? Is there a better way to do
this in Soot? Ideally, I'd like to find all the new operations that
can potentially be sources for the argument to invokeLater.

I have attached the transformer I'm running and a sample file to this email.

Thanks, and have a great weekend.

--Mathias
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FindArgumentSources.java
Type: text/x-java
Size: 6140 bytes
Desc: not available
Url : http://mailman.cs.mcgill.ca/pipermail/soot-list/attachments/20100416/bb15f5d1/attachment.bin 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: CallGraphs.java
Type: text/x-java
Size: 894 bytes
Desc: not available
Url : http://mailman.cs.mcgill.ca/pipermail/soot-list/attachments/20100416/bb15f5d1/attachment-0001.bin 


More information about the Soot-list mailing list