Apk decompilation and apk decompilation tutorial

Source: Internet
Author: User

Apk decompilation and apk decompilation tutorial
Tools

Tools required for decompilation


The above are command line decompilation, and androidfly is a graphical interface, but the downloaded decompilation jar package cannot be viewed, probably because it is not the latest.


Decompilation of contributed source files

Use apktool to copy the decompiled apk to the apktool file:


Start cmd, go to the apktool directory, and run the following command (the paths are different ):

C: \ Users \ ASUS> f:
F: \> cd \ workDocument \ uncomfile_tools \ apktool

F: \ workDocument \ uncomfile_tools \ apktool> apktool. bat d-f android_libs.apk android_libs
I: Baksmaling...
I: Loading resource table...
I: Loaded.
I: Decoding AndroidManifest. xml with resources...
I: Loading resource table from file: C: \ Users \ ASUS \ apktool \ framework \ 1.apk
I: Loaded.
I: Regular manifest package...
I: Decoding file-resources...
I: Decoding values */* XMLs...
I: Done.
I: Copying assets and libs ...'

The running result is as follows. There is more than one folder under the Directory, which contains the required resource file.


Decompilation Command Format

Apktool. bat d-f [apk file] [Output Folder]

Repackage to apk Command Format
Apktool. bat B Output Folder


Decompile java code

Rename the decompiled apk to rar or zip to the end of the file and decompress it as follows:


Copy the classes. dex under the folder to the dex2jar-0.0.9.15 and run the following command:

F: \ workDocument \ uncomfile_tools> cd dex2jar-0.0.9.15
F: \ workDocument \ uncomfile_tools \ dex2jar-0.0.9.15> dex2jar. bat classes. dex
This cmd is deprecated, use the d2j-dex2jar if possible
Dex2jar version: translator-0.0.9.15
Dex2jar classes. dex-> classes_dex2jar.jar
Done.

Generate the classes_dex2jar.jar file.


Classes_dex2jar.jarfile. Open it with jd-gui.exe.



Terror!


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.