The anti-compilation of the apk under window is very simple, there are many integration tools, select the installation package and then you can build a tool to decompile the source files and the jar, and then use Jd-gui to view the source code, use a text editor to view the resource files. After changing the Mac has not found what to force the Anti-compilation tool, no way, self-organizing the anti-compilation process, share
In fact, the anti-compilation toolset is finally using a few of our commonly used build to complete the APK anti-compilation, is Apktool: Extract the APK in various resource files, tablets, layouts, various resources, etc. dex2jar: Classes.dex the apk into a jar file to view the source code.
1. Apktool: Extract various resource files in APK
The basic syntax for Apktool is:
{Your path}/sh apktool.sh d {your path}/food.apk
Then we will see a food folder in the apktool.sh directory, and this will contain all the resource files. Where/res/values/public.xml contains the various ID resources that we define.
:
https://code.google.com/p/android-apktool/
Https://code.google.com/p/android-apktool/wiki/Install
Https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_2.0.0rc3.jar
2. Dex2jar: Turn apk classes.dex into a jar file
The most basic syntax:
{Your path}/sh dex2jar.sh {your path}/classes.dex
So we can see the Classes_dex2jar.jar in the Classed.dex directory and then we can use Jd-gui to open it.
Classes.dex is the file we extracted from the APK.
:
https://code.google.com/p/dex2jar/
Https://dex2jar.googlecode.com/files/dex2jar-0.0.9.15.zip
3, Jd-gui: View jar File This tool is relatively simple, is used to view the jar file. The jar file generated by Dex2jar is viewed using this tool. Did not expect the official website also provides the Mac version. Big Love ~
In addition, Android Studio has integrated the Jd-intellij (Java decompiler IntelliJ Plugin), the latest version 0.6.
:
http://jd.benow.ca/
Http://jd.benow.ca/jd-gui/downloads/jd-gui-0.3.5.osx.i686.dmg
The initial directory is as follows:
4, the specific operation is as follows:
$ sh apktools/apktool.sh d food.apk//In the current directory generate a food folder, inside for the extracted resource file $ unzip-o-D tmpfood food.apk//Generate a Tmpfood folder in the current directory, Inside for unzip apk get file $ sh dex2jar-0.0.9.15/dex2jar.sh tmpfood/classes.dex//Generate a Classes_ in Tmpfood directory Dex2jar.jar file, this file is the source file that was obtained
The resulting files are as follows:
To view our resulting jar files:
Resources Download:
http://download.csdn.net/detail/ttdevs/8317793
Anti-compilation of apk under Mac