Not getting any idea how to make good layout in Android
activity or not getting how any application doing that things which you
want in your project but you don’t know how to implement it in your APK
File. So, I came here with new technology & new thinking which can
make you crazy in android world.Now time for backtracking…start your
time to do hacking. Do you know you can get source code of Android APK
file? Time to break the code..Let’s learn step by step.
In this tutorial we will learn how to convert android APK
file into source code. Android .apk file is a compressed form of a file
which contains Java classes (in .dex form), XML files and all necessary
files. So first we will learn how to get Java source File from android
apk using dex2jar and Java decompiler tools and then we will learn how
to get XML source file using apktool and apkinstall tools.To get the
source code from APK file, we will need these tools:1. dex2jar2. java decompiler
3. apktool
4. apkinstallSteps to get source: Get Java files from apk: 1. Rename the .apk file into .zip file (example SharedPr.apk into SharedPr.zip).
2. Extract SharedPr.zip file and copy classes.dex file from extracted folder.
3. Extract dex2jar.zip and paste classes.dex into dex2jar folder.
3. Open command prompt and change directory to the dex2jar folder. Then write dex2jar classes.dex and press enter. Now you will get classes.dex.dex2jar file in the same folder.
Convert classes.dex to classes.dex.dex2jar |
classes.dex.dex2jar will be in dex2jar folder |
Save All Java Files |
1. Extract apktool and apkinstall in a folder (Example : New Folder).
2. Put SharedPr.apk (your apk file) in same folder (i.e New Folder).
Keep Android Apk File with apktool and apkinstall |
4. Type command on command prompt: apktool d SharedPr.apk
Get All XML Files In Resource Folder |
Folder) and all XML files will be in res->layout folder.
See All XML Files in new created Folder |
Note: Video of this post is also available on YouTube, Watch video “How to get source code (Java code and XML code) From Android APK File“.
For more related to Android tutorials see List of Android Tutorials
No comments:
Post a Comment