|
23 | 23 | deobfuscator.main(".apk/"+dex) |
24 | 24 | os.system("$TOOLS/redex-all -c $TOOLS/default.config .apk/const/const.dex -o .apk/const") |
25 | 25 | print("$TOOLS/redex-all .apk/const/const.dex -o .apk/const") |
26 | | -#os.system("$TOOLS/redex-all -c $TOOLS/default.config .apk/const/const.dex -o .apk/const") |
27 | | -#print("$TOOLS/redex-all -c $TOOLS/default.config .apk/const/const.dex -o .apk/const") |
28 | 26 | os.system("mv .apk/const/classes.dex .apk/"+dex) |
| 27 | + |
29 | 28 | apk_name=apk_name.replace(".apk","_deobfuscated.apk") |
30 | 29 | apk_name=os.path.basename(apk_name) |
31 | 30 | os.system("java -jar $TOOLS/apktool.jar b ./.apk -o "+apk_name) |
32 | 31 |
|
33 | 32 | os.system("zipalign -f -v 4 "+apk_name+" "+apk_name.replace(".apk","_align.apk")) |
34 | 33 | os.system("apksigner sign --ks deoptfuscator.keystore --ks-pass pass:123456 "+apk_name.replace(".apk","_align.apk")) |
35 | | -#outfile = apk_name.replace(".apk", "_align.apk") |
36 | | -#os.system("mv " + outfile + " " + outpath) |
37 | 34 | os.system("rm -rf "+apk_name) |
38 | | -#os.system("rm -rf " + apk_name + " .std* .pro*") |
39 | | -#os.system("rm -rf .apk") |
40 | | - |
41 | | - |
42 | | -#file = '/home/hbryu/Desktop/deoptfuscator/.profile' |
43 | | -#file_size = getsize(file) |
44 | | -#if file_size != 0: |
45 | | -#os.system('cp .profile ~/Desktop/dataset/AndroZoo_profile' + apk_name + '_profile') |