[Soot-list] Is there any convenient way to track the uses of a class field?

Bodden, Eric eric.bodden at sit.fraunhofer.de
Thu Dec 11 03:28:48 EST 2014


Hi Tianyin.

> I want to perform a basic data-flow tracking of a set of given variables. When the data-flow goes into a class field, I should keep tracking the uses of that field.
> 
> However, I fail to find the method I can use to get all the uses of a given SootField instance. Is there anything I'm missing?


> One thing I can definitely do is to scan all the Stmt in all the methods in all the classes before the analysis procedure (or do it lazily),  so I can record the uses of the fields in a map. But I feel this's a pretty basic feature and should have been provided already.

Yes, creating such a map would be a good idea. This is not actually a very common use case, so no there is no predefined method for it.

Cheers,
Eric
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 841 bytes
Desc: Message signed with OpenPGP using GPGMail
Url : http://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20141211/e9bba309/attachment.bin 


More information about the Soot-list mailing list