If I want to develop static analysis for Android applications, what entrypoints should I use? There are two options I have in mind:
- Use
ActivityThread.main()from./frameworks/base/core/java/android/app/ActivityThread.java(orLooper.loop()from./frameworks/base/core/java/android/os/Looper.java) as entry - Use a made-up
main()which contains only code that callsonCreate(),onPause(),onResume(), and etc.
Are there valid choices? Is there other choice that you think more fit?
The second approach seems more reasonable but is still incomplete. How to model the event handlers (typically
onXXX()) is a difficult problem. A formalism should be provided to describe GUI, event-driven programs. Answer would be updated when more details are gathered.