如何反编译apk文件

准备三个工具:Apktool、dex2jar、jd-gui

  • Apktool

    • 下载:downloads

    • 安装:install

      **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
      4.Move both files (apktool.jar & apktool.bat) to your Windows directory (Usually C://Windows)
      5.If you do not have access to C://Windows, you may place the two files anywhere then add that directory to your Environment Variables System PATH variable.
      6.Try running apktool via command prompt
      
    • 使用:documentation

  • 示例:

    C:\Users\Decompile>apktool d FARead.apk
    I: Using Apktool 2.2.1 on FARead.apk
    I: Loading resource table...
    I: Decoding AndroidManifest.xml with resources...
    I: Loading resource table from file: C:\Users\pc\AppData\Local\apktool\framework\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...
    
  • dex2jar

    • 下载:sourceforge bitbucket

    • 安装:install

      **Windows:**
      1.解压apk安装包,获取classes.dex文件
      2.解压dex2jar压缩包
      3.将classes.dex文件拷贝到dex2jar目录
      4.cmd进入dex2jar目录下,执行“d2j-dex2jar.bat classes.dex”命令
      5.当前目录下生成classes-dex2jar.jar文件
      
    • 使用:documentation

    • 示例:

      C:\Users\Decompile\dex2jar-2.0>d2j-dex2jar classes.dex
      dex2jar classes.dex -> .\classes-dex2jar.jar
      
  • jd-gui

    • 下载:downloads

    • 安装:install

      **Windows:**
      1.下载jd-gui-1.4.0.jar文件或者jd-gui-windows-1.4.0.zip压缩包
      2.Windows下双击jar文件即可打开Java Decompiler程序
      3.用Java Decompiler程序打开classes-dex2jar.jar文件
      
    • 使用:documentation

    • 示例:

示例

I Don't Want Your Money, I Want Aragaki Yui.