[Soot-list] Problems of creating dummy main method for android.
qpj
412832527 at qq.com
Thu Mar 6 08:52:07 EST 2014
Hi Eric and Arzt,
I have been working on extracting a call graph from android app. And as you came up with in soot-infoflow, I should create a dummy main method for android class. As I decompiled the dummyMainClass which is generated by AndroidEntryPointCreator, I got the following one:
dummyMainClass:
import android.os.Bundle;
import com.example.test.MainActivity;
class dummyMainClass
{
public static void dummyMainMethod()
{
int i = 0;
label64:
do
{
MainActivity localMainActivity = new com/example/test/MainActivity;
localMainActivity.<init>();
if (i != 0)
{
localMainActivity.onCreate(new Bundle());
...}}}
Then the problem comes, as I use this stmt in my main method: MainActivity mainActivity = new MainActivity();
the console will throw an error:
A fatal error has been detected by the Java Runtime Environment:
#
# Internal Error (classFileParser.cpp:3161), pid=5908, tid=3008
# Error: ShouldNotReachHere()
#
# JRE version: 7.0-b89
...
I originally thought MainActivity cannot be instantiated, until I saw you instantiate it. So I'd like to ask for help: how you handle this problem. Any detail will be appreciated.
Best Regards.
Xiangxing
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.cs.mcgill.ca/pipermail/soot-list/attachments/20140306/1a5b9775/attachment-0001.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: AndroidEntryPointCreator.java
Type: application/octet-stream
Size: 39932 bytes
Desc: not available
Url : http://mailman.cs.mcgill.ca/pipermail/soot-list/attachments/20140306/1a5b9775/attachment-0001.obj
More information about the Soot-list
mailing list