Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

dexexception: not support version

I was trying to convert apk to source code. When I entered below command

./d2j-dex2jar.sh classes.dex

I got this exception:

com.googlecode.d2j.DexException: not support version.
at com.googlecode.d2j.reader.DexFileReader.<init>(DexFileReader.java:151)
at com.googlecode.d2j.reader.DexFileReader.<init>(DexFileReader.java:211)
at com.googlecode.dex2jar.tools.Dex2jarCmd.doCommandLine(Dex2jarCmd.java:104)
at com.googlecode.dex2jar.tools.BaseCmd.doMain(BaseCmd.java:288)
at com.googlecode.dex2jar.tools.Dex2jarCmd.main(Dex2jarCmd.java:32)

Version of my apk is Oreo and dexcompiler is dex2jar-2.0. As much as I Know this dexcompiler supports upto N version (correct me if I am wrong). I have searched about this exception, but I didn't find any answers.

Please help me to resolve this exception

like image 392
anandhu Avatar asked Apr 02 '18 07:04

anandhu


2 Answers

I had the same problem. Used the updated version. Now it works fine.

https://github.com/DexPatcher/dex2jar/releases/download/v2.1-20171001-lanchon/dex-tools-2.1-20171001-lanchon.zip

like image 176
john Avatar answered Oct 12 '22 22:10

john


(2021) get the dex2jar-2.1.zip from this link https://github.com/pxb1988/dex2jar/releases first enter this command d2j-dex2jar -h then run the second command d2j-dex2jar "yourapkfile" .

like image 41
RabiaDagdemir Avatar answered Oct 12 '22 22:10

RabiaDagdemir