Exception in thread main org.jf.dexlib2.dexbacked.DexBackedDexFileNotADexFile

转自:https://blog.csdn.net/m0_37696990/article/details/103931261

使用apktool反编译apk时报错

Exception in thread "main" org.jf.dexlib2.dexbacked.DexBackedDexFile$NotADexFile
: Not a valid dex magic value: cf 77 4c c7 9b 21 01 cd

提示很明显,就是非法Dex,这是因为apk里有加密过后的dex文件,比如有些apk的assets目录下有加密后的Dex文件,添加–only-main-classes参数即可

java -jar "%~dp0\apktool_2.4.1.jar" d -f Game.apk -only-main-classes

 

你可能感兴趣的:(Android)