问题
I try to get source code from an .apk
I followed the steps from right here
Is there a way to get the source code from an APK file? but on Step 2.4 when I wrote on my cmd dex2jar path> d2j-dex2jar classes.dex
I get
"'d2j-dex2jar' is not recognized as an internal or external command, operable program or batch files."
any solutions ?
回答1:
Use dex2jar classes.dex
instead of d2j-dex2jar classes.dex
And please check which version of dex2jar is with you.
if it is dex2jar-2.x jar file then , please try to download dex2jar-0.0.9.15 jar file.
回答2:
for dex2jar 2.0 version please follow below steps to generate jar
- download dex2jar (https://sourceforge.net/projects/dex2jar/files/)
- extract folder
- goto folder in command prompt
- chmod u+x d2j_invoke.sh
- chmod u+x d2j-dex2jar.sh
- put desired apk to decompile in dex2jar folder
- sh d2j-dex2jar.sh -f -o output_jar.jar my_app.apk
- This will generate output_jar.jar in same folder
回答3:
Add permission with: chmod +x d2j-dex2jar.sh Then run it with: ./d2j-dex2jar.sh app.apk
回答4:
place all the apk file, coverted zip, apktool, apktool install, dex2jar, jd-gui folders under a single folder... open command prompt(admin).. then goto the directory of your newly created folder.. then type... d2j-dex2jar classes.dex , press enter... thats it ur problem is solved...cheezzz
no need to add any xtra permissions...it workwed for me..it'll work for you too...
回答5:
Just goto the folder where you put your classes.dex file then just run the command in command prompt http://i.stack.imgur.com/8X3aP.png
-Make sure you have downloaded the dex2jar latest version which is dex2jar-2.0. download it with this link
https://sourceforge.net/projects/dex2jar/
-It will then make your classes.dex file to executable jar 'classes-dex2jar.jar'
回答6:
If you have downloaded the d2j-dex2jar-2.x then it would not contain the d2j-dex2jar.sh file
so, try to download the dex2jar-0.0.9.15 from the link dex2jar-0.0.9.15
Finally extract this zip file and you will find the d2j-dex2jar.sh file.
Hopefully this will help you!
回答7:
you must use dex2jar-0.0.9.15 to decompile apk older version dos'nt work correctly because missing some files via extension bat
来源:https://stackoverflow.com/questions/29744010/apk-decompile-error-d2j-dex2jar-command-not-found