Apktool Extract the apk file's resources

Source: Internet
Author: User

APK file itself is a compressed package, directly with the decompression tool can be opened, but the inside of the file has been encoded into a binary file format, can not directly see, such as the program description file Androidmanifest.xml.

These files can be decoded and restored using the Apktool tool. Apktool (http://code.google.com/p/android-apktool/now address is: http://ibotpeaches.github.io/Apktool/) is a very well-known open source Toolkit, Powerful, can unpack apk files and repackage, commonly used to Chinese Android applications.

Installation method, see http://ibotpeaches.github.io/Apktool/install/:

Quick Check
    • Apktool 2.x (Versions after 1.5.2 )
      1. is Java 1.7 installed?
      2. Does executing on java -version command Line/command prompt return 1.7?
      3. If not, please install Java 7 and make it the default.
Installation for Apktool 2.x
  • Windows :
    1. Download Windows Wrapper script (right click, Save Link as apktool.bat )
    2. Download Apktool-2 (Find newest here)
    3. Rename downloaded jar to Apktool.jar li>
    4. Move both files ( Apktool.jar & apktool.bat ) to your Windows directory (usually c://windows )
    5. If You don't have access to c://windows Ywhere then add this directory to your environment Variables System PATH variable.
    6. Try running apktool via command prompt
  • Linux :
    1. Download Linux Wrapper script (right click, Save Link as apktool ) /li>
    2. Download Apktool-2 (Find newest here)
    3. Make sure the 32bit libraries ( Ia32-libs) downloaded and installed by your Linux Package Manager, if is on a 64bit Unix system.
    4. (This helps provide support for the 32bit native binary aapt, which are required by Apktool)
    5. Rena Me downloaded jar to apktool.jar
    6. Move both files ( Apktool.jar & apktool) to /usr/local/bin (Root needed)
    7. Make sure both files is executable ( chmod +x
    8. Try running apktool via CLI
  • Mac OS X:
    1. Download Mac Wrapper script (right click, Save Link as apktool )
    2. Download Apktool-2 (Find newest here)
    3. Rename downloaded jar toapktool.jar
    4. Move both files ( apktool.jar & apktool ) to /usr/local/bin (Root needed)
    5. Make sure both files is executable ( chmod +x )
    6. Try running apktool via CLI

Note -Wrapper scripts is not a needed, but the helpful so don't have a to type of over and over java -jar apktool.jar .

I can't put them in the bin directory, but I put them in the/software/android/tools directory.

In this way, I unzip an apk file under the download directory, which is the following command:

/software/android/tools/apktool D ~/downloads/com.supercell.clashofclans_v8.116.2-722_android-4.0.3.apk

The extracted directory is:/software/android/tools/the following directory.

Parameter description:

apktool d [demo.apk]  // 参数是 d 而不是 -d。

./apktool
Apktool v2.0.3-a tool for reengineering Android apk files
With Smali v2.1.0 and Baksmali v2.1.0
Copyright Ryszard Wi?niewski <[email protected]>
Updated by Connor Tumbleson [email protected]

Usage:apktool
-advance,--Advanced Prints advance information.
-version,--Version Prints the version then exits


Usage:apktool if|install-framework [options] <framework.apk>
-p,--frame-path <dir>    Stores framework files into <dir>.
-T,--tag <tag>          tag frameworks using <tag>.


Usage:apktool D[ecode] [options] <file_apk>
-F,--force       & nbsp;      force Delete Destination directory.
-o,--output <dir>       The name of folder that gets written. Default is apk.out
-P,--frame-path <dir>   Uses framework files located in <dir>.
-R,--no-res             do not decode resources.
-S,--no-src             do not decode sources.
-T,--frame-tag <tag>    Uses framework files tagged by <tag>.


Usage:apktool b[uild] [options] <app_path>
-F,--force-all Skip changes detection and build all files.
-O,--output <dir> The name of the apk that gets written. Default is dist/name.apk
-P,--frame-path <dir> Uses framework files located in <dir>.

For additional info, see:http://ibotpeaches.github.io/apktool/
For Smali/baksmali info, See:https://github.com/jesusfreke/smali


Apktool Extract the apk file's resources

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.