[Soot-list] problem about -process-dir of reading jar file

Bernhard Berger berber at tzi.de
Thu Feb 23 05:15:28 EST 2017


Hi,

Soot makes the same assumptions according to the jar file layout as  any standard java virtual machine. Therefore, you have a) to extract your or b) to repackage your jar files. 

Regards, Bernhard


> Am 23.02.2017 um 10:49 schrieb liujiefeng <liujiefeng at huawei.com>:
> 
> Hi, there.
>  
> I’m trying to use SOOT to analyze a whole jar file in eclipse.
> And I use these sootArgs:
>  
>         String[] sootArgsJar = {
>                 "-cp", "C:\\Users\\xxxxxxx\\workspace-neon\\test.jar",
>                 "-process-dir", "C:\\Users\\xxxxxxx\\workspace-neon\\test.jar", "-pp",
>                 "-w", "-app",
>                 "-keep-line-number",
>                 "-keep-bytecode-offset",
>                 "-p", "cg", "implicit-entry:false",
>                 "-p", "cg.spark", "enabled",
>                 "-p", "cg.spark", "simulate-natives",
>                 "-p", "cg", "safe-forname",
>                 "-p", "cg", "safe-newinstance",
>         };
>  
> but I got some problem as below:
>  
>  
> java.lang.RuntimeException: Class names not equal! test.DatabaseTestSettings$1 != test.bin.test.DatabaseTestSettings$1
>  
>  
> So I look up some Soot command-line options and I found this:
>  
> If subdirectories of dir contain .class or .jimple files, Soot assumes that the subdirectory names correspond to components of the classes' package names. If dir contains subA/subB/MyClass.class, for instance, then Soot assumes MyClass is in package subA.subB.
>  
> And how can I ignore this just to set my soot path to test.jar/test/bin?
> I’ve tried to set -cp and -process-dir to any form like:
>          
>          "C:\\Users\\xxxxxxx\\workspace-neon\\test.jar:test\\bin"
>     "C:\\Users\\xxxxxxx\\workspace-neon\\test.jar;test\\bin”
>     "C:\\Users\\xxxxxxx\\workspace-neon\\test.jar\\test\\bin"
>     Etc..
> It all doesn’t work.
>  
> Looking forward to your reply.
> _______________________________________________
> Soot-list mailing list
> Soot-list at CS.McGill.CA <mailto:Soot-list at CS.McGill.CA>
> https://mailman.CS.McGill.CA/mailman/listinfo/soot-list <https://mailman.cs.mcgill.ca/mailman/listinfo/soot-list>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20170223/d17245fa/attachment-0001.html 


More information about the Soot-list mailing list