Open mafga74 opened 7 months ago
Your Android platform directory is wrong. You need to specify the "platforms" directory inside the Android SDK folder, not the root of your Android Studio installation.
The specification of the source/sink definition file seems right, though. Maybe you can set a breakpoint in the parseCommandLineOptions
method in the MainClass
to see what's hapenning. On my machine, the commamd-line tool works. I use absolute paths instead of relative ones, but that shouldn't make a difference.
Thanks for your answer StevenArzt.
Can you help me on what do you exactly mean by "the "platforms" directory inside the Android SDK folder". The apk claims for Android API level 25 that is already installed on Android Studio on the next folder "C:\Users\mafga\AppData\Local\Android\Sdk" (see the attached image). Do you mean to use this folder? I also tried with this path with no better results.
I am using the soot-infoflow-cmd-2.12.0-jar-with-dependencies.jar downloaded from https://repo1.maven.org/maven2/de/fraunhofer/sit/sse/flowdroid/soot-infoflow-cmd/2.12.0/ so I do not have the possibility of using breakpoints yet.
Thanks in advance.
Best regards MAFGA
The platforms directory would then be C:\Users\mafga\AppData\Local\Android\Sdk\platforms
.
Does the SourcesAndSinks.txt
file exist on your hard disk in the folder soot-infoflow-android
?
For me, this command-line works well with the 2.12 command-line JAR:
java -jar .\soot-infoflow-cmd-2.12.0-jar-with-dependencies.jar -s "C:\Users\arzt\Documents\OpenSource\FlowDroid\soot-infoflow-android\SourcesAndSinks.txt" -a "C:\Users\arzt\Documents\Apps\InsecureBankv2.apk" -p "C:\Users\arzt\AppData\Local\Android\Sdk\platforms"
Thank you very much for your help StevenArzt
It works!!! Now it is time to see if I am able to understand the results :-) The problem was what you mentioned about the platform directory.
Best regards MAFGA
Dear all
I am already trying to run an analysis with Flowdroid over an android app but when I execute the next:
java -jar .\soot-infoflow-cmd\target\soot-infoflow-cmd-2.12.0-jar-with-dependencies.jar -a ..\App\OTA_New_tool_V3.0.apk -p "C:\Program Files\Android\Android Studio\" -s .\soot-infoflow-android\SourcesAndSinks.txt
I obtain the following answer:
The data flow analysis has failed. Error message: No source/sink file specified for the data flow analysis java.lang.RuntimeException: No source/sink file specified for the data flow analysis at soot.jimple.infoflow.android.SetupApplication.runInfoflow(SetupApplication.java:1460) at soot.jimple.infoflow.cmd.MainClass.run(MainClass.java:364) at soot.jimple.infoflow.cmd.MainClass.main(MainClass.java:262)
I have no idea about how to solve the situation.
Can anyone help me please?
Thanks in advance MAFGA