- Download the APK from the device.
- Convert the APK file to a JAR
- Decompile the JAR
Download the APK from the device
This can be done using the Android SDK platform tools. Go to your SDK directory and find platform-tools/adb.
If you don't know where your application is installed on your device follow these instructions:
Type
adb shell
This gives you a Linux shell on your device. Now type:
This will give you a list of all your installed applications and the paths where they are located in the filesystem.
Exit the shell and download the APK via:
Now you can find the APK file in your current directory.
Now we use the dex2jar tool to convert the Dalvik executable files into class files inside a JAR. Download the tool from the github repository and run
pm list packages -f
This will give you a list of all your installed applications and the paths where they are located in the filesystem.
Exit the shell and download the APK via:
adb pull <Path to the APK file on the device>
Now you can find the APK file in your current directory.
Convert the APK file to a JAR
Now we use the dex2jar tool to convert the Dalvik executable files into class files inside a JAR. Download the tool from the github repository and run
sh d2j-dex2jar.sh -f ~/path/to/apk_to_decompile.apk
This creates the JAR archive in the current directory.
Now we can use the Java Decompiler to view the contents of the JAR archive. Just open the JAR archive in the Decompiler and browse the classes.
Decompile the JAR
Now we can use the Java Decompiler to view the contents of the JAR archive. Just open the JAR archive in the Decompiler and browse the classes.
Keine Kommentare:
Kommentar veröffentlichen