Carlisle's Site

Back

常用的反编译工具:#

Apktool#

反编译出 apk, 解析出 resources.arsc、classes.dex、9.png、XMLs 资源、Smali 文件,并且可以重新进行打包。

# 安装
brew install apktool

# 反编译
apktool d pathtoapk outdir

# 重新打包
apktool b apppath outpath
shell

dex2jar#

Tools to work with android .dex and java .class files.

# 安装
brew install dex2jar

# 将 apk 改成后缀 .zip 之后解压后得到一个 classes.dex。
d2j-dex2jar pathtoclasses.dex
shell

生成一个 jar 文件,用 jd-gui 打开就可以看到其中的 java 代码了。

jd-gui#

可视化反编译查看 .jar 文件

# 安装
brew cask install jd-gui
shell

JADX#

方便的 jadx 工具,可以直接反编译 apk。

# 安装
brew install jadx

# 使用
jadx-gui
shell

另外选择 File → Save ALL 即可保存源码文件,然后就可以导入 Android Studio 等 IDE 中。

其他#

Android 反编译软件的使用
https://carlislechan.github.io/blog/20160823-android-decompiler
Author Carlisle
Published at August 23, 2016
Comment seems to stuck. Try to refresh?✨