Replies: 5 comments
-
I think you are mixing two topics here. Are you saying if we successfully disassemble a dex file in 2nd - I agree with the default to non-greedy and opt-in. I was merging PRs without a greater understanding of the change and to reverse an api change so soon - I'll have to think about. |
Beta Was this translation helpful? Give feedback.
-
My english is not the best. And I was curious about this: why could it not put it back in the exact name and place it was, like you said instead creating assets.dex on root which had caused problem on some devices |
Beta Was this translation helpful? Give feedback.
-
This explained why the heck smali_assets were created out of the blue. I always deleted smali_assets folder when i see it before compiling, app working fine so far. I will try that --only-main-classes option next time |
Beta Was this translation helpful? Give feedback.
-
Yeah, I have also been told to delete smali_assets or assets.dex to avoid errors. |
Beta Was this translation helpful? Give feedback.
-
I am also facing the same issue. https://modapky.com/dragon-city-breeding-calculator/ |
Beta Was this translation helpful? Give feedback.
-
By default, apktool.jar decompile dex from assets if available. This is the problem because many apps often add additional dex or encrypted dex in assets which will cause failing to decompile or compile, or even cause problem with the app if assets.dex has been added to the APK file. Often with the error
Exception in thread "main" org.jf.dexlib2.dexbacked.DexBackedDexFile$NotADexFile: Not a valid dex magic value: cf 77 4c c7 9b 21 01 cd
orClass xxx has already been interned
I don't get really much sense with this, i think nobody ever worked with dex in assets. Many users will just get confused with this error, only very few knew that
--only-main-classes
fixes itIf disassembling dex from assets still makes sense, it would be better to add option to decompile dex from assets instead and ignore/skip non-valid dex to continue decompiling. Everybody could trick apktool to cause error by creating non-valid dex file and place it in assets folder
And why not compile dex back to the original location instead creating assets.dex.
There is no infomation about assets.dex so I don't know what would be possible or not
Just my opinion
Beta Was this translation helpful? Give feedback.
All reactions