From 3f5bf8226bb7f0e24aadf4d48d2404140d26ca5e Mon Sep 17 00:00:00 2001 From: Jean-Marie Mineau Date: Wed, 17 Sep 2025 16:24:22 +0200 Subject: [PATCH] wip --- 5_theseus/4_results.typ | 33 +- 5_theseus/figs/comparision-of-exit-status.svg | 1772 +++++++++-------- 5_theseus/figs/demo_main_main.dot | 228 +++ 5_theseus/figs/demo_raw.dot | 235 +++ 5_theseus/figs/patched_main_main.dot | 315 +++ 5_theseus/figs/patched_raw.dot | 336 ++++ jury.typ | 9 +- main.typ | 4 +- main_french.typ | 2 +- 9 files changed, 2083 insertions(+), 851 deletions(-) create mode 100644 5_theseus/figs/demo_main_main.dot create mode 100644 5_theseus/figs/demo_raw.dot create mode 100644 5_theseus/figs/patched_main_main.dot create mode 100644 5_theseus/figs/patched_raw.dot diff --git a/5_theseus/4_results.typ b/5_theseus/4_results.typ index 3b05af2..65891f2 100644 --- a/5_theseus/4_results.typ +++ b/5_theseus/4_results.typ @@ -1,3 +1,5 @@ +#import "@preview/diagraph:0.3.5": render + #import "../lib.typ": SDK, num, mypercent, ART, ie, APKs, API, #import "../lib.typ": todo, jfl-note #import "X_var.typ": * @@ -170,10 +172,10 @@ public class Main { } ```, caption: [Code of the main class of the application showed by Jadx, before patching], -) +) A first analysis of the contant of the application shows that the application contains one `Activity` that instanciate the class `Main` and call `Main.main()`. -@fig:th-demo-before shows the most of the code of `Main` as returned by Jadx. +@lst:th-demo-before shows the most of the code of `Main` as returned by Jadx. We can see that the class contains another #DEX file encoded in base 64 and loaded in the `InMemoryDexClassLoader` `cl`. A class is then loaded from this class loader, and two methods from this class loader are called. The names of this class and methods are not directly accessible as they have been chipĥered and are decoded just before beeing used at runtime. @@ -185,7 +187,7 @@ This is not particularly surprising considering the obfusctation methods used. Then we run the dynamic analysis we described in @sec:th-dyn on the application and apply the transformation described in @sec:th-trans to add the dynamic informations to it. This time, Flowdroid compute a larger callgraph of 76 edges, and does find a data leak. -Indeed, when looking at the new application with Jadx, we notice a new class `Malicious`, and the code of `Main.main()` is now as shown in @fig:th-demo-after: +Indeed, when looking at the new application with Jadx, we notice a new class `Malicious`, and the code of `Main.main()` is now as shown in @lst:th-demo-after: the method called in the loop is either `Malicious.get_data`, `Malicious.send_data()` or `Method.invoke()`. Although self explanatory, verifying the code of those methods indeed confirm that `get_data()` calls `Utils.source()` and `send_data()` calls `Utils.sink()`. @@ -207,7 +209,30 @@ Although self explanatory, verifying the code of those methods indeed confirm th } ```, caption: [Code of `Main.main()` showed by Jadx, after patching], -) +) + +#figure( + render( + read("figs/demo_main_main.dot"), + width: 100%, + alt: ( + "", + ).join(), + ), + caption: [Call Graph of `Main.main()` view by Androguard before patching], +) + +#figure( + render( + read("figs/patched_main_main.dot"), + width: 100%, + alt: ( + "", + ).join(), + ), + caption: [Call Graph of `Main.main()` view by Androguard after patching], +) + #todo[androgard call graph] diff --git a/5_theseus/figs/comparision-of-exit-status.svg b/5_theseus/figs/comparision-of-exit-status.svg index 6991b0d..8c7e228 100644 --- a/5_theseus/figs/comparision-of-exit-status.svg +++ b/5_theseus/figs/comparision-of-exit-status.svg @@ -1,12 +1,12 @@ - + - 2025-09-06T21:39:01.904334 + 2025-09-15T14:26:24.417367 image/svg+xml @@ -21,997 +21,1061 @@ - - - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - +" clip-path="url(#p0a03c15111)" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> + + + + + + + + + + + + + + + + + + + + + + + + - - + - + - + - + - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1215,22 +1337,22 @@ z - - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + - @@ -1443,22 +1535,22 @@ z - - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + @@ -1613,22 +1705,22 @@ z - - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + @@ -1786,22 +1878,22 @@ z - - + + - + - - + + - + - + - + @@ -1815,22 +1907,22 @@ z - - + + - + - - + + - + - + - + - + + - + - - + + - + - + - + @@ -1881,29 +1973,29 @@ z - - + + - + - + - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + + - + - + - - + - - + - - + - - + - - + +" style="fill: url(#h5fbd823695); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - + - + - - + +" style="fill: url(#h32ff551f15); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - + - + - - + +" style="fill: url(#ha96f6e66c8); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - + - + @@ -2404,17 +2496,17 @@ z - - + +" style="fill: url(#hd7a9398fb1); stroke: #000000; stroke-width: 1.5; stroke-linejoin: miter"/> - + - + @@ -2427,12 +2519,12 @@ z - - + + - + - + - + - + (Activity)V" [accessflags="public constructor", + # classname="Main", + # descriptor="(Activity)V", + # entrypoint=False, + # external=False, + # methodname=""]; + #"Class->getClassLoader()ClassLoader" [classname="Class", + # descriptor="()ClassLoader", + # entrypoint=False, + # external=True, + # methodname=getClassLoader]; + #"Main->(Activity)V" -> "Class->getClassLoader()ClassLoader"; + #"String->getBytes()[B" [classname="String", + # descriptor="()[B", + # entrypoint=False, + # external=True, + # methodname=getBytes]; + #"Main->(Activity)V" -> "String->getBytes()[B"; + #"ByteBuffer->wrap([B)ByteBuffer" [classname="ByteBuffer", + # descriptor="([B)ByteBuffer", + # entrypoint=False, + # external=True, + # methodname=wrap]; + #"Main->(Activity)V" -> "ByteBuffer->wrap([B)ByteBuffer"; + #"SecretKeySpec->([B String)V" [classname="SecretKeySpec", + # descriptor="([B String)V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Main->(Activity)V" -> "SecretKeySpec->([B String)V"; + #"InMemoryDexClassLoader->(ByteBuffer ClassLoader)V" [classname="InMemoryDexClassLoader", + # descriptor="(ByteBuffer ClassLoader)V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Main->(Activity)V" -> "InMemoryDexClassLoader->(ByteBuffer ClassLoader)V"; + #"Object->()V" [classname="Object", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Main->(Activity)V" -> "Object->()V"; + "Base64->decode(String I)[B" [classname="Base64", + descriptor="(String I)[B", + entrypoint=False, + external=True, + methodname=decode]; + #"Main->(Activity)V" -> "Base64->decode(String I)[B"; + "Main->decrypt(String)String" [accessflags=public, + classname="Main", + descriptor="(String)String", + entrypoint=False, + external=False, + methodname=decrypt]; + "Main->decrypt(String)String" -> "Base64->decode(String I)[B"; + "Cipher->init(I Key)V" [classname="Cipher", + descriptor="(I Key)V", + entrypoint=False, + external=True, + methodname=init]; + "Main->decrypt(String)String" -> "Cipher->init(I Key)V"; + "Cipher->doFinal([B)[B" [classname="Cipher", + descriptor="([B)[B", + entrypoint=False, + external=True, + methodname=doFinal]; + "Main->decrypt(String)String" -> "Cipher->doFinal([B)[B"; + "Cipher->getInstance(String)Cipher" [classname="Cipher", + descriptor="(String)Cipher", + entrypoint=False, + external=True, + methodname=getInstance]; + "Main->decrypt(String)String" -> "Cipher->getInstance(String)Cipher"; + "String->([B)V" [classname="String", + descriptor="([B)V", + entrypoint=False, + external=True, + methodname=""]; + "Main->decrypt(String)String" -> "String->([B)V"; + #"Main->encrypt(String)String" [accessflags=public, + # classname="Main", + # descriptor="(String)String", + # entrypoint=False, + # external=False, + # methodname=encrypt]; + #"Main->encrypt(String)String" -> "String->getBytes()[B"; + #"Main->encrypt(String)String" -> "Cipher->init(I Key)V"; + #"Main->encrypt(String)String" -> "Cipher->doFinal([B)[B"; + #"Main->encrypt(String)String" -> "Cipher->getInstance(String)Cipher"; + #"Base64->encodeToString([B I)String" [classname="Base64", + # descriptor="([B I)String", + # entrypoint=False, + # external=True, + # methodname=encodeToString]; + #"Main->encrypt(String)String" -> "Base64->encodeToString([B I)String"; + "Main->main()V" [accessflags=public, + classname="Main", + descriptor="()V", + entrypoint=False, + external=False, + methodname=main]; + "Main->main()V" -> "Main->decrypt(String)String"; + "Method->invoke(Object [Object)Object" [classname="Method", + descriptor="(Object [Object)Object", + entrypoint=False, + external=True, + methodname=invoke]; + "Main->main()V" -> "Method->invoke(Object [Object)Object"; + "ClassLoader->loadClass(String)Class" [classname="ClassLoader", + descriptor="(String)Class", + entrypoint=False, + external=True, + methodname=loadClass]; + "Main->main()V" -> "ClassLoader->loadClass(String)Class"; + "Class->getMethod(String [Class)Method" [classname="Class", + descriptor="(String [Class)Method", + entrypoint=False, + external=True, + methodname=getMethod]; + "Main->main()V" -> "Class->getMethod(String [Class)Method"; + #"MainActivity->()Vg" [accessflags="public constructor", + # classname="MainActivity", + # descriptor="()V", + # entrypoint=False, + # external=False, + # methodname=""]; + #"Activity->()V" [classname="Activity", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"MainActivity->()Vg" -> "Activity->()V"; + #"MainActivity->onCreate(Bundle)V" [accessflags=protected, + # classname="MainActivity", + # descriptor="(Bundle)V", + # entrypoint=False, + # external=False, + # methodname=onCreate]; + #"MainActivity->onCreate(Bundle)V" -> "Main->(Activity)V"; + #"MainActivity->onCreate(Bundle)V" -> "Main->main()V"; + #"Activity->onCreate(Bundle)V" [classname="Activity", + # descriptor="(Bundle)V", + # entrypoint=False, + # external=True, + # methodname=onCreate]; + #"MainActivity->onCreate(Bundle)V" -> "Activity->onCreate(Bundle)V"; + #"Log->i(String String Throwable;)I" [classname="Log", + # descriptor="(String String Throwable;)I", + # entrypoint=False, + # external=True, + # methodname=i]; + #"MainActivity->onCreate(Bundle)V" -> "Log->i(String String Throwable;)I"; + #"Utils->()V" [accessflags="public constructor", + # classname="Utils", + # descriptor="()V", + # entrypoint=False, + # external=False, + # methodname=""]; + #"Utils->()V" -> "Object->()V"; + #"Utils->popup(Activity String String)V" [accessflags="public static", + # classname="Utils", + # descriptor="(Activity String String)V", + # entrypoint=False, + # external=False, + # methodname=popup]; + #"AlertDialog$Builder->setTitle(CharSequence)AlertDialog$Builder" [classname="AlertDialog$Builder", + # descriptor="(CharSequence)AlertDialog$Builder", + # entrypoint=False, + # external=True, + # methodname=setTitle]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->setTitle(CharSequence)AlertDialog$Builder"; + #"AlertDialog$Builder->(Context)V" [classname="AlertDialog$Builder", + # descriptor="(Context)V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->(Context)V"; + #"AlertDialog$Builder->setMessage(CharSequence)AlertDialog$Builder" [classname="AlertDialog$Builder", + # descriptor="(CharSequence)AlertDialog$Builder", + # entrypoint=False, + # external=True, + # methodname=setMessage]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->setMessage(CharSequence)AlertDialog$Builder"; + #"AlertDialog->show()V" [classname="AlertDialog", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=show]; + #"Utils->popup(Activity String String)V" -> "AlertDialog->show()V"; + #"AlertDialog$Builder->create()AlertDialog" [classname="AlertDialog$Builder", + # descriptor="()AlertDialog", + # entrypoint=False, + # external=True, + # methodname=create]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->create()AlertDialog"; + #"Utils->sink(Activity String)V" [accessflags="public static", + # classname="Utils", + # descriptor="(Activity String)V", + # entrypoint=False, + # external=False, + # methodname=sink]; + #"Utils->sink(Activity String)V" -> "Utils->popup(Activity String String)V"; + #"Utils->source(String)String" [accessflags="public static", + # classname="Utils", + # descriptor="(String)String", + # entrypoint=False, + # external=False, + # methodname=source]; + #"StringBuilder->append(String)StringBuilder" [classname="StringBuilder", + # descriptor="(String)StringBuilder", + # entrypoint=False, + # external=True, + # methodname=append]; + #"Utils->source(String)String" -> "StringBuilder->append(String)StringBuilder"; + #"StringBuilder->()V" [classname="StringBuilder", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Utils->source(String)String" -> "StringBuilder->()V"; + #"StringBuilder->toString()String" [classname="StringBuilder", + # descriptor="()String", + # entrypoint=False, + # external=True, + # methodname=toString]; + #"Utils->source(String)String" -> "StringBuilder->toString()String"; +} diff --git a/5_theseus/figs/demo_raw.dot b/5_theseus/figs/demo_raw.dot new file mode 100644 index 0000000..163a181 --- /dev/null +++ b/5_theseus/figs/demo_raw.dot @@ -0,0 +1,235 @@ +strict digraph "" { + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" [accessflags="public constructor", + classname="Lcom/example/theseus/Main;", + descriptor="(Landroid/app/Activity;)V", + entrypoint=False, + external=False, + methodname=""]; + "Ljava/lang/Class;->getClassLoader()Ljava/lang/ClassLoader;" [classname="Ljava/lang/Class;", + descriptor="()Ljava/lang/ClassLoader;", + entrypoint=False, + external=True, + methodname=getClassLoader]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" -> "Ljava/lang/Class;->getClassLoader()Ljava/lang/ClassLoader;"; + "Ljava/lang/String;->getBytes()[B" [classname="Ljava/lang/String;", + descriptor="()[B", + entrypoint=False, + external=True, + methodname=getBytes]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" -> "Ljava/lang/String;->getBytes()[B"; + "Ljava/nio/ByteBuffer;->wrap([B)Ljava/nio/ByteBuffer;" [classname="Ljava/nio/ByteBuffer;", + descriptor="([B)Ljava/nio/ByteBuffer;", + entrypoint=False, + external=True, + methodname=wrap]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" -> "Ljava/nio/ByteBuffer;->wrap([B)Ljava/nio/ByteBuffer;"; + "Ljavax/crypto/spec/SecretKeySpec;->([B Ljava/lang/String;)V" [classname="Ljavax/crypto/spec/SecretKeySpec;", + descriptor="([B Ljava/lang/String;)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" -> "Ljavax/crypto/spec/SecretKeySpec;->([B Ljava/lang/String;)V"; + "Ldalvik/system/InMemoryDexClassLoader;->(Ljava/nio/ByteBuffer; Ljava/lang/ClassLoader;)V" [classname="Ldalvik/system/InMemoryDexClassLoader;", + descriptor="(Ljava/nio/ByteBuffer; Ljava/lang/ClassLoader;)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" -> "Ldalvik/system/InMemoryDexClassLoader;->(Ljava/nio/ByteBuffer; Ljava/lang/ClassLoader;)V"; + "Ljava/lang/Object;->()V" [classname="Ljava/lang/Object;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" -> "Ljava/lang/Object;->()V"; + "Landroid/util/Base64;->decode(Ljava/lang/String; I)[B" [classname="Landroid/util/Base64;", + descriptor="(Ljava/lang/String; I)[B", + entrypoint=False, + external=True, + methodname=decode]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c" -> "Landroid/util/Base64;->decode(Ljava/lang/String; I)[B"; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x584" [accessflags=public, + classname="Lcom/example/theseus/Main;", + descriptor="(Ljava/lang/String;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=decrypt]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x584" -> "Landroid/util/Base64;->decode(Ljava/lang/String; I)[B"; + "Ljavax/crypto/Cipher;->init(I Ljava/security/Key;)V" [classname="Ljavax/crypto/Cipher;", + descriptor="(I Ljava/security/Key;)V", + entrypoint=False, + external=True, + methodname=init]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x584" -> "Ljavax/crypto/Cipher;->init(I Ljava/security/Key;)V"; + "Ljavax/crypto/Cipher;->doFinal([B)[B" [classname="Ljavax/crypto/Cipher;", + descriptor="([B)[B", + entrypoint=False, + external=True, + methodname=doFinal]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x584" -> "Ljavax/crypto/Cipher;->doFinal([B)[B"; + "Ljavax/crypto/Cipher;->getInstance(Ljava/lang/String;)Ljavax/crypto/Cipher;" [classname="Ljavax/crypto/Cipher;", + descriptor="(Ljava/lang/String;)Ljavax/crypto/Cipher;", + entrypoint=False, + external=True, + methodname=getInstance]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x584" -> "Ljavax/crypto/Cipher;->getInstance(Ljava/lang/String;)Ljavax/crypto/Cipher;"; + "Ljava/lang/String;->([B)V" [classname="Ljava/lang/String;", + descriptor="([B)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x584" -> "Ljava/lang/String;->([B)V"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x5c8" [accessflags=public, + classname="Lcom/example/theseus/Main;", + descriptor="(Ljava/lang/String;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=encrypt]; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x5c8" -> "Ljava/lang/String;->getBytes()[B"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x5c8" -> "Ljavax/crypto/Cipher;->init(I Ljava/security/Key;)V"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x5c8" -> "Ljavax/crypto/Cipher;->doFinal([B)[B"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x5c8" -> "Ljavax/crypto/Cipher;->getInstance(Ljava/lang/String;)Ljavax/crypto/Cipher;"; + "Landroid/util/Base64;->encodeToString([B I)Ljava/lang/String;" [classname="Landroid/util/Base64;", + descriptor="([B I)Ljava/lang/String;", + entrypoint=False, + external=True, + methodname=encodeToString]; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x5c8" -> "Landroid/util/Base64;->encodeToString([B I)Ljava/lang/String;"; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x678" [accessflags=public, + classname="Lcom/example/theseus/Main;", + descriptor="()V", + entrypoint=False, + external=False, + methodname=main]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x678" -> "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x584"; + "Ljava/lang/reflect/Method;->invoke(Ljava/lang/Object; [Ljava/lang/Object;)Ljava/lang/Object;" [classname="Ljava/lang/reflect/Method;", + descriptor="(Ljava/lang/Object; [Ljava/lang/Object;)Ljava/lang/Object;", + entrypoint=False, + external=True, + methodname=invoke]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x678" -> "Ljava/lang/reflect/Method;->invoke(Ljava/lang/Object; [Ljava/lang/Object;)Ljava/lang/Object;"; + "Ljava/lang/ClassLoader;->loadClass(Ljava/lang/String;)Ljava/lang/Class;" [classname="Ljava/lang/ClassLoader;", + descriptor="(Ljava/lang/String;)Ljava/lang/Class;", + entrypoint=False, + external=True, + methodname=loadClass]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x678" -> "Ljava/lang/ClassLoader;->loadClass(Ljava/lang/String;)Ljava/lang/Class;"; + "Ljava/lang/Class;->getMethod(Ljava/lang/String; [Ljava/lang/Class;)Ljava/lang/reflect/Method;" [classname="Ljava/lang/Class;", + descriptor="(Ljava/lang/String; [Ljava/lang/Class;)Ljava/lang/reflect/Method;", + entrypoint=False, + external=True, + methodname=getMethod]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x678" -> "Ljava/lang/Class;->getMethod(Ljava/lang/String; [Ljava/lang/Class;)Ljava/lang/reflect/Method;"; + "Lcom/example/theseus/MainActivity;->()V [access_flags=public constructor] @ 0x524" [accessflags="public constructor", + classname="Lcom/example/theseus/MainActivity;", + descriptor="()V", + entrypoint=False, + external=False, + methodname=""]; + "Landroid/app/Activity;->()V" [classname="Landroid/app/Activity;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/MainActivity;->()V [access_flags=public constructor] @ 0x524" -> "Landroid/app/Activity;->()V"; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x53c" [accessflags=protected, + classname="Lcom/example/theseus/MainActivity;", + descriptor="(Landroid/os/Bundle;)V", + entrypoint=False, + external=False, + methodname=onCreate]; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x53c" -> "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x60c"; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x53c" -> "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x678"; + "Landroid/app/Activity;->onCreate(Landroid/os/Bundle;)V" [classname="Landroid/app/Activity;", + descriptor="(Landroid/os/Bundle;)V", + entrypoint=False, + external=True, + methodname=onCreate]; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x53c" -> "Landroid/app/Activity;->onCreate(Landroid/os/Bundle;)V"; + "Landroid/util/Log;->i(Ljava/lang/String; Ljava/lang/String; Ljava/lang/Throwable;)I" [classname="Landroid/util/Log;", + descriptor="(Ljava/lang/String; Ljava/lang/String; Ljava/lang/Throwable;)I", + entrypoint=False, + external=True, + methodname=i]; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x53c" -> "Landroid/util/Log;->i(Ljava/lang/String; Ljava/lang/String; Ljava/lang/Throwable;)I"; + "Lcom/example/theseus/Utils;->()V [access_flags=public constructor] @ 0x754" [accessflags="public constructor", + classname="Lcom/example/theseus/Utils;", + descriptor="()V", + entrypoint=False, + external=False, + methodname=""]; + "Lcom/example/theseus/Utils;->()V [access_flags=public constructor] @ 0x754" -> "Ljava/lang/Object;->()V"; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x76c" [accessflags="public static", + classname="Lcom/example/theseus/Utils;", + descriptor="(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V", + entrypoint=False, + external=False, + methodname=popup]; + "Landroid/app/AlertDialog$Builder;->setTitle(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;", + entrypoint=False, + external=True, + methodname=setTitle]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x76c" -> "Landroid/app/AlertDialog$Builder;->setTitle(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;"; + "Landroid/app/AlertDialog$Builder;->(Landroid/content/Context;)V" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="(Landroid/content/Context;)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x76c" -> "Landroid/app/AlertDialog$Builder;->(Landroid/content/Context;)V"; + "Landroid/app/AlertDialog$Builder;->setMessage(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;", + entrypoint=False, + external=True, + methodname=setMessage]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x76c" -> "Landroid/app/AlertDialog$Builder;->setMessage(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;"; + "Landroid/app/AlertDialog;->show()V" [classname="Landroid/app/AlertDialog;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=show]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x76c" -> "Landroid/app/AlertDialog;->show()V"; + "Landroid/app/AlertDialog$Builder;->create()Landroid/app/AlertDialog;" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="()Landroid/app/AlertDialog;", + entrypoint=False, + external=True, + methodname=create]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x76c" -> "Landroid/app/AlertDialog$Builder;->create()Landroid/app/AlertDialog;"; + "Lcom/example/theseus/Utils;->sink(Landroid/app/Activity; Ljava/lang/String;)V [access_flags=public static] @ 0x7a8" [accessflags="public static", + classname="Lcom/example/theseus/Utils;", + descriptor="(Landroid/app/Activity; Ljava/lang/String;)V", + entrypoint=False, + external=False, + methodname=sink]; + "Lcom/example/theseus/Utils;->sink(Landroid/app/Activity; Ljava/lang/String;)V [access_flags=public static] @ 0x7a8" -> "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x76c"; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x710" [accessflags="public static", + classname="Lcom/example/theseus/Utils;", + descriptor="(Ljava/lang/String;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=source]; + "Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;" [classname="Ljava/lang/StringBuilder;", + descriptor="(Ljava/lang/String;)Ljava/lang/StringBuilder;", + entrypoint=False, + external=True, + methodname=append]; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x710" -> "Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;"; + "Ljava/lang/StringBuilder;->()V" [classname="Ljava/lang/StringBuilder;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x710" -> "Ljava/lang/StringBuilder;->()V"; + "Ljava/lang/StringBuilder;->toString()Ljava/lang/String;" [classname="Ljava/lang/StringBuilder;", + descriptor="()Ljava/lang/String;", + entrypoint=False, + external=True, + methodname=toString]; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x710" -> "Ljava/lang/StringBuilder;->toString()Ljava/lang/String;"; +} diff --git a/5_theseus/figs/patched_main_main.dot b/5_theseus/figs/patched_main_main.dot new file mode 100644 index 0000000..a4bef73 --- /dev/null +++ b/5_theseus/figs/patched_main_main.dot @@ -0,0 +1,315 @@ +strict digraph "" { + #"MainActivity->()V" [accessflags="public constructor", + # classname="MainActivity", + # descriptor="()V", + # entrypoint=False, + # external=False, + # methodname=""]; + #"Activity->()V" [classname="Activity", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"MainActivity->()V" -> "Activity->()V"; + #"MainActivity->onCreate(Bundle)V" [accessflags=protected, + # classname="MainActivity", + # descriptor="(Bundle)V", + # entrypoint=False, + # external=False, + # methodname=onCreate]; + "Main->main()V" [accessflags=public, + classname="Main", + descriptor="()V", + entrypoint=False, + external=False, + methodname=main]; + #"MainActivity->onCreate(Bundle)V" -> "Main->main()V"; + #"Activity->onCreate(Bundle)V" [classname="Activity", + # descriptor="(Bundle)V", + # entrypoint=False, + # external=True, + # methodname=onCreate]; + #"MainActivity->onCreate(Bundle)V" -> "Activity->onCreate(Bundle)V"; + #"Main->(Activity)V" [accessflags="public constructor", + # classname="Main", + # descriptor="(Activity)V", + # entrypoint=False, + # external=False, + # methodname=""]; + #"MainActivity->onCreate(Bundle)V" -> #"Main->(Activity)V"; + #"Log->i(String String Throwable)I" [classname="Log", + # descriptor="(String String Throwable)I", + # entrypoint=False, + # external=True, + # methodname=i]; + #"MainActivity->onCreate(Bundle)V" -> "Log->i(String String Throwable)I"; + "Main->decrypt(String)String" [accessflags=public, + classname="Main", + descriptor="(String)String", + entrypoint=False, + external=False, + methodname=decrypt]; + "Main->main()V" -> "Main->decrypt(String)String"; + "ClassLoader->loadClass(String)Class" [classname="ClassLoader", + descriptor="(String)Class", + entrypoint=False, + external=True, + methodname=loadClass]; + "Main->main()V" -> "ClassLoader->loadClass(String)Class"; + "Malicious->get_data(String Activity)String" [accessflags="public static", + classname="Malicious", + descriptor="(String Activity)String", + entrypoint=False, + external=False, + methodname=get_data, + style=filled, + fillcolor=salmon]; + "Main->main()V" -> "Malicious->get_data(String Activity)String"; + "Method->invoke(Object [Object)Object" [classname="Method", + descriptor="(Object [Object)Object", + entrypoint=False, + external=True, + methodname=invoke]; + "Main->main()V" -> "Method->invoke(Object [Object)Object"; + "Malicious->send_data(String Activity)String" [accessflags="public static", + classname="Malicious", + descriptor="(String Activity)String", + entrypoint=False, + external=False, + methodname=send_data, + style=filled, + fillcolor=salmon]; + "Main->main()V" -> "Malicious->send_data(String Activity)String"; + "T->check_is_Malicious_get_data(Method)Z" [accessflags="public static final", + classname="T", + descriptor="(Method)Z", + entrypoint=False, + external=False, + methodname=check_is_Malicious_get_data, + style=filled, + fillcolor=lightgrey]; + "Main->main()V" -> "T->check_is_Malicious_get_data(Method)Z"; + "Class->getMethod(String [Class)Method" [classname="Class", + descriptor="(String [Class)Method", + entrypoint=False, + external=True, + methodname=getMethod]; + "Main->main()V" -> "Class->getMethod(String [Class)Method"; + "T->check_is_Malicious_send_data(Method)Z" [accessflags="public static final", + classname="T", + descriptor="(Method)Z", + entrypoint=False, + external=False, + methodname=check_is_Malicious_send_data, + style=filled, + fillcolor=lightgrey]; + "Main->main()V" -> "T->check_is_Malicious_send_data(Method)Z"; + #"Object->()V" [classname="Object", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Main->(Activity)V" -> "Object->()V"; + #"ByteBuffer->wrap([B)ByteBuffer" [classname="ByteBuffer", + # descriptor="([B)ByteBuffer", + # entrypoint=False, + # external=True, + # methodname=wrap]; + #"Main->(Activity)V" -> "ByteBuffer->wrap([B)ByteBuffer"; + #"Class->getClassLoader()ClassLoader" [classname="Class", + # descriptor="()ClassLoader", + # entrypoint=False, + # external=True, + # methodname=getClassLoader]; + #"Main->(Activity)V" -> "Class->getClassLoader()ClassLoader"; + #"SecretKeySpec->([B String)V" [classname="SecretKeySpec", + # descriptor="([B String)V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Main->(Activity)V" -> "SecretKeySpec->([B String)V"; + "Base64->decode(String I)[B" [classname="Base64", + descriptor="(String I)[B", + entrypoint=False, + external=True, + methodname=decode]; + #"Main->(Activity)V" -> "Base64->decode(String I)[B"; + #"InMemoryDexClassLoader->(ByteBuffer ClassLoader)V" [classname="InMemoryDexClassLoader", + # descriptor="(ByteBuffer ClassLoader)V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Main->(Activity)V" -> "InMemoryDexClassLoader->(ByteBuffer ClassLoader)V"; + #"String->getBytes()[B" [classname="String", + # descriptor="()[B", + # entrypoint=False, + # external=True, + # methodname=getBytes]; + #"Main->(Activity)V" -> "String->getBytes()[B"; + #"Utils->()V" [accessflags="public constructor", + # classname="Utils", + # descriptor="()V", + # entrypoint=False, + # external=False, + # methodname=""]; + #"Utils->()V" -> "Object->()V"; + #"Utils->popup(Activity String String)V" [accessflags="public static", + # classname="Utils", + # descriptor="(Activity String String)V", + # entrypoint=False, + # external=False, + # methodname=popup]; + #"AlertDialog$Builder->setMessage(CharSequence)AlertDialog$Builder" [classname="AlertDialog$Builder", + # descriptor="(CharSequence)AlertDialog$Builder", + # entrypoint=False, + # external=True, + # methodname=setMessage]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->setMessage(CharSequence)AlertDialog$Builder"; + #"AlertDialog$Builder->setTitle(CharSequence)AlertDialog$Builder" [classname="AlertDialog$Builder", + # descriptor="(CharSequence)AlertDialog$Builder", + # entrypoint=False, + # external=True, + # methodname=setTitle]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->setTitle(CharSequence)AlertDialog$Builder"; + #"AlertDialog$Builder->create()AlertDialog;" [classname="AlertDialog$Builder", + # descriptor="()AlertDialog;", + # entrypoint=False, + # external=True, + # methodname=create]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->create()AlertDialog;"; + #"AlertDialog$Builder->(Landroid/content/Context;)V" [classname="AlertDialog$Builder", + # descriptor="(Landroid/content/Context;)V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Utils->popup(Activity String String)V" -> "AlertDialog$Builder->(Landroid/content/Context;)V"; + #"AlertDialog;->show()V" [classname="AlertDialog;", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=show]; + #"Utils->popup(Activity String String)V" -> "AlertDialog;->show()V"; + "Utils->sink(Activity String)V" [accessflags="public static", + classname="Utils", + descriptor="(Activity String)V", + entrypoint=False, + external=False, + methodname=sink]; + #"Utils->sink(Activity String)V" -> "Utils->popup(Activity String String)V"; + "Utils->source(String)String" [accessflags="public static", + classname="Utils", + descriptor="(String)String", + entrypoint=False, + external=False, + methodname=source]; + #"StringBuilder->append(String)StringBuilder" [classname="StringBuilder", + # descriptor="(String)StringBuilder", + # entrypoint=False, + # external=True, + # methodname=append]; + #"Utils->source(String)String" -> "StringBuilder->append(String)StringBuilder"; + #"StringBuilder->()V" [classname="StringBuilder", + # descriptor="()V", + # entrypoint=False, + # external=True, + # methodname=""]; + #"Utils->source(String)String" -> "StringBuilder->()V"; + #"StringBuilder->toString()String" [classname="StringBuilder", + # descriptor="()String", + # entrypoint=False, + # external=True, + # methodname=toString]; + #"Utils->source(String)String" -> "StringBuilder->toString()String"; + "Main->decrypt(String)String" -> "Base64->decode(String I)[B"; + "String->([B)V" [classname="String", + descriptor="([B)V", + entrypoint=False, + external=True, + methodname=""]; + "Main->decrypt(String)String" -> "String->([B)V"; + "Cipher->doFinal([B)[B" [classname="Cipher", + descriptor="([B)[B", + entrypoint=False, + external=True, + methodname=doFinal]; + "Main->decrypt(String)String" -> "Cipher->doFinal([B)[B"; + "Cipher->init(I Key)V" [classname="Cipher", + descriptor="(I Key)V", + entrypoint=False, + external=True, + methodname=init]; + "Main->decrypt(String)String" -> "Cipher->init(I Key)V"; + "Cipher->getInstance(String)Cipher" [classname="Cipher", + descriptor="(String)Cipher", + entrypoint=False, + external=True, + methodname=getInstance]; + "Main->decrypt(String)String" -> "Cipher->getInstance(String)Cipher"; + #"Main->encrypt(String)String" [accessflags=public, + # classname="Main", + # descriptor="(String)String", + # entrypoint=False, + # external=False, + # methodname=encrypt]; + #"Main->encrypt(String)String" -> "String->getBytes()[B"; + #"Main->encrypt(String)String" -> "Cipher->doFinal([B)[B"; + #"Main->encrypt(String)String" -> "Cipher->init(I Key)V"; + #"Main->encrypt(String)String" -> "Cipher->getInstance(String)Cipher"; + #"Base64->encodeToString([B I)String" [classname="Base64", + # descriptor="([B I)String", + # entrypoint=False, + # external=True, + # methodname=encodeToString]; + #"Main->encrypt(String)String" -> "Base64->encodeToString([B I)String"; + "Malicious->get_data(String Activity)String" -> "Utils->source(String)String"; + "Malicious->send_data(String Activity)String" -> "Utils->sink(Activity String)V"; + #"Class->descriptorString()String" [classname="Class", + # descriptor="()String", + # entrypoint=False, + # external=True, + # methodname=descriptorString]; + #"T->check_is_Malicious_get_data(Method)Z" -> "Class->descriptorString()String"; + #"Method->getName()String" [classname="Method", + # descriptor="()String", + # entrypoint=False, + # external=True, + # methodname=getName]; + #"T->check_is_Malicious_get_data(Method)Z" -> "Method->getName()String"; + #"String->equals(Object)Z" [classname="String", + # descriptor="(Object)Z", + # entrypoint=False, + # external=True, + # methodname=equals]; + #"T->check_is_Malicious_get_data(Method)Z" -> "String->equals(Object)Z"; + #"Method->getDeclaringClass()Class" [classname="Method", + # descriptor="()Class", + # entrypoint=False, + # external=True, + # methodname=getDeclaringClass]; + #"T->check_is_Malicious_get_data(Method)Z" -> "Method->getDeclaringClass()Class"; + #"Method->getParameterTypes()[Class" [classname="Method", + # descriptor="()[Class", + # entrypoint=False, + # external=True, + # methodname=getParameterTypes]; + #"T->check_is_Malicious_get_data(Method)Z" -> "Method->getParameterTypes()[Class"; + #"Method->getReturnType()Class" [classname="Method", + # descriptor="()Class", + # entrypoint=False, + # external=True, + # methodname=getReturnType]; + #"T->check_is_Malicious_get_data(Method)Z" -> "Method->getReturnType()Class"; + #"T->check_is_Malicious_send_data(Method)Z" -> "Class->descriptorString()String"; + #"T->check_is_Malicious_send_data(Method)Z" -> "Method->getName()String"; + #"T->check_is_Malicious_send_data(Method)Z" -> "String->equals(Object)Z"; + #"T->check_is_Malicious_send_data(Method)Z" -> "Method->getDeclaringClass()Class"; + #"T->check_is_Malicious_send_data(Method)Z" -> "Method->getParameterTypes()[Class"; + #"T->check_is_Malicious_send_data(Method)Z" -> "Method->getReturnType()Class"; + #"Malicious->()V" [accessflags="public constructor", + # classname="Malicious", + # descriptor="()V", + # entrypoint=False, + # external=False, + # methodname=""]; + #"Malicious->()V" -> "Object->()V"; +} diff --git a/5_theseus/figs/patched_raw.dot b/5_theseus/figs/patched_raw.dot new file mode 100644 index 0000000..64dd2fd --- /dev/null +++ b/5_theseus/figs/patched_raw.dot @@ -0,0 +1,336 @@ +strict digraph "" { + "Lcom/example/theseus/MainActivity;->()V [access_flags=public constructor] @ 0x7a8" [accessflags="public constructor", + classname="Lcom/example/theseus/MainActivity;", + descriptor="()V", + entrypoint=False, + external=False, + methodname=""]; + "Landroid/app/Activity;->()V" [classname="Landroid/app/Activity;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/MainActivity;->()V [access_flags=public constructor] @ 0x7a8" -> "Landroid/app/Activity;->()V"; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x7c0" [accessflags=protected, + classname="Lcom/example/theseus/MainActivity;", + descriptor="(Landroid/os/Bundle;)V", + entrypoint=False, + external=False, + methodname=onCreate]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" [accessflags=public, + classname="Lcom/example/theseus/Main;", + descriptor="()V", + entrypoint=False, + external=False, + methodname=main]; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x7c0" -> "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0"; + "Landroid/app/Activity;->onCreate(Landroid/os/Bundle;)V" [classname="Landroid/app/Activity;", + descriptor="(Landroid/os/Bundle;)V", + entrypoint=False, + external=True, + methodname=onCreate]; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x7c0" -> "Landroid/app/Activity;->onCreate(Landroid/os/Bundle;)V"; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" [accessflags="public constructor", + classname="Lcom/example/theseus/Main;", + descriptor="(Landroid/app/Activity;)V", + entrypoint=False, + external=False, + methodname=""]; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x7c0" -> "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc"; + "Landroid/util/Log;->i(Ljava/lang/String; Ljava/lang/String; Ljava/lang/Throwable;)I" [classname="Landroid/util/Log;", + descriptor="(Ljava/lang/String; Ljava/lang/String; Ljava/lang/Throwable;)I", + entrypoint=False, + external=True, + methodname=i]; + "Lcom/example/theseus/MainActivity;->onCreate(Landroid/os/Bundle;)V [access_flags=protected] @ 0x7c0" -> "Landroid/util/Log;->i(Ljava/lang/String; Ljava/lang/String; Ljava/lang/Throwable;)I"; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x928" [accessflags=public, + classname="Lcom/example/theseus/Main;", + descriptor="(Ljava/lang/String;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=decrypt]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x928"; + "Ljava/lang/ClassLoader;->loadClass(Ljava/lang/String;)Ljava/lang/Class;" [classname="Ljava/lang/ClassLoader;", + descriptor="(Ljava/lang/String;)Ljava/lang/Class;", + entrypoint=False, + external=True, + methodname=loadClass]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Ljava/lang/ClassLoader;->loadClass(Ljava/lang/String;)Ljava/lang/Class;"; + "Lcom/example/theseus/Malicious;->get_data(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String; [access_flags=public static] @ \ +0x20c" [accessflags="public static", + classname="Lcom/example/theseus/Malicious;", + descriptor="(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=get_data]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Lcom/example/theseus/Malicious;->get_data(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String; [access_flags=public static] @ \ +0x20c"; + "Ljava/lang/reflect/Method;->invoke(Ljava/lang/Object; [Ljava/lang/Object;)Ljava/lang/Object;" [classname="Ljava/lang/reflect/Method;", + descriptor="(Ljava/lang/Object; [Ljava/lang/Object;)Ljava/lang/Object;", + entrypoint=False, + external=True, + methodname=invoke]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Ljava/lang/reflect/Method;->invoke(Ljava/lang/Object; [Ljava/lang/Object;)Ljava/lang/Object;"; + "Lcom/example/theseus/Malicious;->send_data(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String; [access_flags=public static] @ \ +0x228" [accessflags="public static", + classname="Lcom/example/theseus/Malicious;", + descriptor="(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=send_data]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Lcom/example/theseus/Malicious;->send_data(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String; [access_flags=public static] @ \ +0x228"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac" [accessflags="public static final", + classname="Ltheseus/tl6JVUxO9Jqe3VYc/T;", + descriptor="(Ljava/lang/reflect/Method;)Z", + entrypoint=False, + external=False, + methodname=check_is_Malicious_get_data_224c9b416025faf4]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac"; + "Ljava/lang/Class;->getMethod(Ljava/lang/String; [Ljava/lang/Class;)Ljava/lang/reflect/Method;" [classname="Ljava/lang/Class;", + descriptor="(Ljava/lang/String; [Ljava/lang/Class;)Ljava/lang/reflect/Method;", + entrypoint=False, + external=True, + methodname=getMethod]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Ljava/lang/Class;->getMethod(Ljava/lang/String; [Ljava/lang/Class;)Ljava/lang/reflect/Method;"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88" [accessflags="public static final", + classname="Ltheseus/tl6JVUxO9Jqe3VYc/T;", + descriptor="(Ljava/lang/reflect/Method;)Z", + entrypoint=False, + external=False, + methodname=check_is_Malicious_send_data_c961adb85ae3b11c]; + "Lcom/example/theseus/Main;->main()V [access_flags=public] @ 0x9b0" -> "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88"; + "Ljava/lang/Object;->()V" [classname="Ljava/lang/Object;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" -> "Ljava/lang/Object;->()V"; + "Ljava/nio/ByteBuffer;->wrap([B)Ljava/nio/ByteBuffer;" [classname="Ljava/nio/ByteBuffer;", + descriptor="([B)Ljava/nio/ByteBuffer;", + entrypoint=False, + external=True, + methodname=wrap]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" -> "Ljava/nio/ByteBuffer;->wrap([B)Ljava/nio/ByteBuffer;"; + "Ljava/lang/Class;->getClassLoader()Ljava/lang/ClassLoader;" [classname="Ljava/lang/Class;", + descriptor="()Ljava/lang/ClassLoader;", + entrypoint=False, + external=True, + methodname=getClassLoader]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" -> "Ljava/lang/Class;->getClassLoader()Ljava/lang/ClassLoader;"; + "Ljavax/crypto/spec/SecretKeySpec;->([B Ljava/lang/String;)V" [classname="Ljavax/crypto/spec/SecretKeySpec;", + descriptor="([B Ljava/lang/String;)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" -> "Ljavax/crypto/spec/SecretKeySpec;->([B Ljava/lang/String;)V"; + "Landroid/util/Base64;->decode(Ljava/lang/String; I)[B" [classname="Landroid/util/Base64;", + descriptor="(Ljava/lang/String; I)[B", + entrypoint=False, + external=True, + methodname=decode]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" -> "Landroid/util/Base64;->decode(Ljava/lang/String; I)[B"; + "Ldalvik/system/InMemoryDexClassLoader;->(Ljava/nio/ByteBuffer; Ljava/lang/ClassLoader;)V" [classname="Ldalvik/system/InMemoryDexClassLoader;", + descriptor="(Ljava/nio/ByteBuffer; Ljava/lang/ClassLoader;)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" -> "Ldalvik/system/InMemoryDexClassLoader;->(Ljava/nio/ByteBuffer; Ljava/lang/ClassLoader;)V"; + "Ljava/lang/String;->getBytes()[B" [classname="Ljava/lang/String;", + descriptor="()[B", + entrypoint=False, + external=True, + methodname=getBytes]; + "Lcom/example/theseus/Main;->(Landroid/app/Activity;)V [access_flags=public constructor] @ 0x8bc" -> "Ljava/lang/String;->getBytes()[B"; + "Lcom/example/theseus/Utils;->()V [access_flags=public constructor] @ 0x808" [accessflags="public constructor", + classname="Lcom/example/theseus/Utils;", + descriptor="()V", + entrypoint=False, + external=False, + methodname=""]; + "Lcom/example/theseus/Utils;->()V [access_flags=public constructor] @ 0x808" -> "Ljava/lang/Object;->()V"; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x820" [accessflags="public static", + classname="Lcom/example/theseus/Utils;", + descriptor="(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V", + entrypoint=False, + external=False, + methodname=popup]; + "Landroid/app/AlertDialog$Builder;->setMessage(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;", + entrypoint=False, + external=True, + methodname=setMessage]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x820" -> "Landroid/app/AlertDialog$Builder;->setMessage(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;"; + "Landroid/app/AlertDialog$Builder;->setTitle(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;", + entrypoint=False, + external=True, + methodname=setTitle]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x820" -> "Landroid/app/AlertDialog$Builder;->setTitle(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;"; + "Landroid/app/AlertDialog$Builder;->create()Landroid/app/AlertDialog;" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="()Landroid/app/AlertDialog;", + entrypoint=False, + external=True, + methodname=create]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x820" -> "Landroid/app/AlertDialog$Builder;->create()Landroid/app/AlertDialog;"; + "Landroid/app/AlertDialog$Builder;->(Landroid/content/Context;)V" [classname="Landroid/app/AlertDialog$Builder;", + descriptor="(Landroid/content/Context;)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x820" -> "Landroid/app/AlertDialog$Builder;->(Landroid/content/Context;)V"; + "Landroid/app/AlertDialog;->show()V" [classname="Landroid/app/AlertDialog;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=show]; + "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x820" -> "Landroid/app/AlertDialog;->show()V"; + "Lcom/example/theseus/Utils;->sink(Landroid/app/Activity; Ljava/lang/String;)V [access_flags=public static] @ 0x85c" [accessflags="public static", + classname="Lcom/example/theseus/Utils;", + descriptor="(Landroid/app/Activity; Ljava/lang/String;)V", + entrypoint=False, + external=False, + methodname=sink]; + "Lcom/example/theseus/Utils;->sink(Landroid/app/Activity; Ljava/lang/String;)V [access_flags=public static] @ 0x85c" -> "Lcom/example/theseus/Utils;->popup(Landroid/app/Activity; Ljava/lang/String; Ljava/lang/String;)V [access_flags=public static] @ \ +0x820"; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x878" [accessflags="public static", + classname="Lcom/example/theseus/Utils;", + descriptor="(Ljava/lang/String;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=source]; + "Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;" [classname="Ljava/lang/StringBuilder;", + descriptor="(Ljava/lang/String;)Ljava/lang/StringBuilder;", + entrypoint=False, + external=True, + methodname=append]; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x878" -> "Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;"; + "Ljava/lang/StringBuilder;->()V" [classname="Ljava/lang/StringBuilder;", + descriptor="()V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x878" -> "Ljava/lang/StringBuilder;->()V"; + "Ljava/lang/StringBuilder;->toString()Ljava/lang/String;" [classname="Ljava/lang/StringBuilder;", + descriptor="()Ljava/lang/String;", + entrypoint=False, + external=True, + methodname=toString]; + "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x878" -> "Ljava/lang/StringBuilder;->toString()Ljava/lang/String;"; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x928" -> "Landroid/util/Base64;->decode(Ljava/lang/String; I)[B"; + "Ljava/lang/String;->([B)V" [classname="Ljava/lang/String;", + descriptor="([B)V", + entrypoint=False, + external=True, + methodname=""]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x928" -> "Ljava/lang/String;->([B)V"; + "Ljavax/crypto/Cipher;->doFinal([B)[B" [classname="Ljavax/crypto/Cipher;", + descriptor="([B)[B", + entrypoint=False, + external=True, + methodname=doFinal]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x928" -> "Ljavax/crypto/Cipher;->doFinal([B)[B"; + "Ljavax/crypto/Cipher;->init(I Ljava/security/Key;)V" [classname="Ljavax/crypto/Cipher;", + descriptor="(I Ljava/security/Key;)V", + entrypoint=False, + external=True, + methodname=init]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x928" -> "Ljavax/crypto/Cipher;->init(I Ljava/security/Key;)V"; + "Ljavax/crypto/Cipher;->getInstance(Ljava/lang/String;)Ljavax/crypto/Cipher;" [classname="Ljavax/crypto/Cipher;", + descriptor="(Ljava/lang/String;)Ljavax/crypto/Cipher;", + entrypoint=False, + external=True, + methodname=getInstance]; + "Lcom/example/theseus/Main;->decrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x928" -> "Ljavax/crypto/Cipher;->getInstance(Ljava/lang/String;)Ljavax/crypto/Cipher;"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x96c" [accessflags=public, + classname="Lcom/example/theseus/Main;", + descriptor="(Ljava/lang/String;)Ljava/lang/String;", + entrypoint=False, + external=False, + methodname=encrypt]; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x96c" -> "Ljava/lang/String;->getBytes()[B"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x96c" -> "Ljavax/crypto/Cipher;->doFinal([B)[B"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x96c" -> "Ljavax/crypto/Cipher;->init(I Ljava/security/Key;)V"; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x96c" -> "Ljavax/crypto/Cipher;->getInstance(Ljava/lang/String;)Ljavax/crypto/Cipher;"; + "Landroid/util/Base64;->encodeToString([B I)Ljava/lang/String;" [classname="Landroid/util/Base64;", + descriptor="([B I)Ljava/lang/String;", + entrypoint=False, + external=True, + methodname=encodeToString]; + "Lcom/example/theseus/Main;->encrypt(Ljava/lang/String;)Ljava/lang/String; [access_flags=public] @ 0x96c" -> "Landroid/util/Base64;->encodeToString([B I)Ljava/lang/String;"; + "Lcom/example/theseus/Malicious;->get_data(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String; [access_flags=public static] @ \ +0x20c" -> "Lcom/example/theseus/Utils;->source(Ljava/lang/String;)Ljava/lang/String; [access_flags=public static] @ 0x878"; + "Lcom/example/theseus/Malicious;->send_data(Ljava/lang/String; Landroid/app/Activity;)Ljava/lang/String; [access_flags=public static] @ \ +0x228" -> "Lcom/example/theseus/Utils;->sink(Landroid/app/Activity; Ljava/lang/String;)V [access_flags=public static] @ 0x85c"; + "Ljava/lang/Class;->descriptorString()Ljava/lang/String;" [classname="Ljava/lang/Class;", + descriptor="()Ljava/lang/String;", + entrypoint=False, + external=True, + methodname=descriptorString]; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac" -> "Ljava/lang/Class;->descriptorString()Ljava/lang/String;"; + "Ljava/lang/reflect/Method;->getName()Ljava/lang/String;" [classname="Ljava/lang/reflect/Method;", + descriptor="()Ljava/lang/String;", + entrypoint=False, + external=True, + methodname=getName]; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac" -> "Ljava/lang/reflect/Method;->getName()Ljava/lang/String;"; + "Ljava/lang/String;->equals(Ljava/lang/Object;)Z" [classname="Ljava/lang/String;", + descriptor="(Ljava/lang/Object;)Z", + entrypoint=False, + external=True, + methodname=equals]; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac" -> "Ljava/lang/String;->equals(Ljava/lang/Object;)Z"; + "Ljava/lang/reflect/Method;->getDeclaringClass()Ljava/lang/Class;" [classname="Ljava/lang/reflect/Method;", + descriptor="()Ljava/lang/Class;", + entrypoint=False, + external=True, + methodname=getDeclaringClass]; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac" -> "Ljava/lang/reflect/Method;->getDeclaringClass()Ljava/lang/Class;"; + "Ljava/lang/reflect/Method;->getParameterTypes()[Ljava/lang/Class;" [classname="Ljava/lang/reflect/Method;", + descriptor="()[Ljava/lang/Class;", + entrypoint=False, + external=True, + methodname=getParameterTypes]; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac" -> "Ljava/lang/reflect/Method;->getParameterTypes()[Ljava/lang/Class;"; + "Ljava/lang/reflect/Method;->getReturnType()Ljava/lang/Class;" [classname="Ljava/lang/reflect/Method;", + descriptor="()Ljava/lang/Class;", + entrypoint=False, + external=True, + methodname=getReturnType]; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_get_data_224c9b416025faf4(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xaac" -> "Ljava/lang/reflect/Method;->getReturnType()Ljava/lang/Class;"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88" -> "Ljava/lang/Class;->descriptorString()Ljava/lang/String;"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88" -> "Ljava/lang/reflect/Method;->getName()Ljava/lang/String;"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88" -> "Ljava/lang/String;->equals(Ljava/lang/Object;)Z"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88" -> "Ljava/lang/reflect/Method;->getDeclaringClass()Ljava/lang/Class;"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88" -> "Ljava/lang/reflect/Method;->getParameterTypes()[Ljava/lang/Class;"; + "Ltheseus/tl6JVUxO9Jqe3VYc/T;->check_is_Malicious_send_data_c961adb85ae3b11c(Ljava/lang/reflect/Method;)Z [access_flags=public static \ +final] @ 0xb88" -> "Ljava/lang/reflect/Method;->getReturnType()Ljava/lang/Class;"; + "Lcom/example/theseus/Malicious;->()V [access_flags=public constructor] @ 0x1f4" [accessflags="public constructor", + classname="Lcom/example/theseus/Malicious;", + descriptor="()V", + entrypoint=False, + external=False, + methodname=""]; + "Lcom/example/theseus/Malicious;->()V [access_flags=public constructor] @ 0x1f4" -> "Ljava/lang/Object;->()V"; +} diff --git a/jury.typ b/jury.typ index f8b02ee..2d31420 100644 --- a/jury.typ +++ b/jury.typ @@ -8,10 +8,11 @@ column-gutter: 2em, stroke: 0pt, inset: (x: 0pt, y: .5em), - "Présidente :", "", "", "", - "Rapporteurs :", "Vincent Nicomette", "Professeur des Universités", "INSA Toulouse", - "", "Julien Signoles", "Directeur de Recherches", "CEA", - "Examinatrice :", "", "", "", + //"Présidente :", "", "", "", + "Rapporteurs :", "Vincent Nicomette", "Professeur des Universités", "INSA de Toulouse", + "", "Julien Signoles", "Directeur de Recherche", "CEA LIST", + "Examinateurs :", "Guillaume Doyen", "Professeur", "IMT Atlantique", + "", "Simone Aonzo", /*"Assistant Professor"*/ "Maître de Conférences", "Eurecom", "Dir. de thèse :", "Jean-François Lalande", "Professeur des Universités", "CentraleSupélec", "", "Valérie Viet Triem Tong", "Professeure", "CentraleSupélec", ) diff --git a/main.typ b/main.typ index 14466e8..ab05f8c 100644 --- a/main.typ +++ b/main.typ @@ -61,9 +61,9 @@ #show: matisse-thesis.with( - title-fr: [Rétro-Ingénierie d'applications Android: les inconvénients de l'analyse statique], // malheurs -> inconvénients ? + title-fr: [Les difficultés de la rétro-ingénierie Android: de l'analyse large échelle au dé-brouillage dynamique], // Because "Android Skuldgerries and Other Headache Inducing Fuckeries" won't pass the vibe check - title-en: [Android Application Reverse Engineering: the Woes of Static Analysis], + title-en: [The Woes of Android Reverse Engineering: from Large Scale Analysis to Dynamic Deobfuscation], author: "Jean-Marie MINEAU", affiliation: "IRISA", defense-place: "Rennes", diff --git a/main_french.typ b/main_french.typ index d89f91b..c5638b7 100644 --- a/main_french.typ +++ b/main_french.typ @@ -3,7 +3,7 @@ #import "jury.typ": jury-content #show: matisse-thesis.with( - title-fr: [Rétro-Ingénierie d'applications Android: les inconvénients de l'analyse statique], // malheurs -> inconvénients ? + title-fr: [Les difficultés de la rétro-ingénierie Android: de l'analyse large échelle au dé-brouillage dynamique], title-en: [], author: "Jean-Marie MINEAU", affiliation: "IRISA",