apktool 使用一览

apktool使用说明

  1. 确保电脑当前版本的jdk至少1.7以上

  2. 下载页面wrapper script右击保存为*.bat脚本文件

    链接

  3. 下载apktool到本地

    链接

  4. 修改重命名文件名为:apktool

  5. 将两个文件移动到指定目录下:

    • windows -> c://Windows (usually)

    • Linux -> /usr/local/bin (root needed)

    • Mac -> /usr/local/bin (root needed)

      如果是Linux或者Mac,需要修改两个文件的权限 chmod +X

  6. 终端运行apktool d *.apk 即可将apk资源文件提取到当前文件夹下

    示例如下:
    
        $ apktool d test.apk
        I: Using Apktool 2.3.1 on test.apk
        I: Loading resource table...
        I: Decoding AndroidManifest.xml with resources...
        I: Loading resource table from file: 1.apk
        I: Regular manifest package...
        I: Decoding file-resources...
        I: Decoding values */* XMLs...
        I: Baksmaling classes.dex...
        I: Copying assets and libs...
        I: Copying unknown files...
        I: Copying original files...
    
        $ apktool b test
        I: Using Apktool 2.3.1 on test
        I: Checking whether sources has changed...
        I: Smaling smali folder into classes.dex...
        I: Checking whether resources has changed...
        I: Building resources...
        I: Building apk file...
        I: Copying unknown files/dir...
    
* 使用java -jar apktool.jar获取帮助

    > https://ibotpeaches.github.io/Apktool/documentation/
坚持原创技术分享,您的支持将鼓励我继续创作!