Git Product home page Git Product logo

Comments (17)

vramasam avatar vramasam commented on August 25, 2024

Not seeing this exception specific to okHttp library. Observed the same issue in another apk.
Process: com.hdfc.techapp, PID: 9828
java.lang.NoClassDefFoundError: Failed resolution of: Lres/Hex;
at androidx.appcompat.R$styleable.$d2j$hex$b9a46b2b$decode_I(Unknown Source:16)
at androidx.appcompat.R$styleable.(Unknown Source:115)
at androidx.appcompat.app.AppCompatDelegateImpl.createView(Unknown Source:8)
at

Tried the same with the old version of Dex2Jar there this issue is not happening. Can you please look into it?

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

Hello, sorry for not responding for quite some time. I needed to finish some work for University and academic purposes.
What exactly are you trying to do? It seems like you are trying to disassemble a dex file into a jar and reassembling it into Dalvik and then trying to run the apk/dex file on an Android phone. Is that correct?

I searched for the res/Hex file everywhere, but no matter what, I can't find it. Even if you run jadx on an APK file with okhttp included, there is no res/Hex class file.

from dex2jar.

vramasam avatar vramasam commented on August 25, 2024

@ThexXTURBOXx No problem. Thank you for the response back.

Yes your understanding is correct, we are disassemble the dex file in to jar and then reassembling the Dalvik .

Here as you said this file "res/Hex" is not available in the final apk.
We tried including the "dex-translator/src/test/java/res/Hex.java" in the final dex file, then this error is not coming. or We have to change IR2JConverter MAX_FILL_ARRAY_BYTES to Integer.MAX

Ideally my understanding, in this class dex-translator/src/main/java/com/googlecode/d2j/dex/Dex2Asm.java addHexDecodeMethod suppose to do that. But it didn't happen. I may be wrong here, I thought it will give you idea where to look out. Sorry If I am wrong here.

We also observed this is not happening with Dex2Jar first version for the same apk. It's happening because of the changes done with Dex2Jar latest changes.

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

@vramasam Thanks for additional information. Please try out v47 where I believe I have fixed this issue :)

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

For future reference:
Introduced bug in: 62eba63
Fixed in: 0e26919 (additional fix in 8496704)

from dex2jar.

vramasam avatar vramasam commented on August 25, 2024

@vramasam Thanks for additional information. Please try out v47 where I believe I have fixed this issue :)

Sure. Thank you. Will test and update the results here.

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

@vramasam Do you have any news on this or are there still any errors occurring regarding this?

from dex2jar.

vramasam avatar vramasam commented on August 25, 2024

Hello @ThexXTURBOXx

We observed below exception:
2022-03-31 16:17:48.090 20215-20215/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.hdfc.techapp, PID: 20215
java.lang.NoSuchMethodError: No static method decode_B(Ljava/lang/String;)[B in class Landroidx/appcompat/R$styleable; or its super classes (declaration of 'androidx.appcompat.R$styleable' appears in /data/app/~~aQ9x9aGc8JPDrjAM226nIA==/com.xxx.xxxx-qkeGzcHRj9s7g-NO1EajHw==/base.apk)
at androidx.appcompat.R$styleable.$d2j$hex$497c133b$decode_I(Unknown Source:22)
at androidx.appcompat.R$styleable.(Unknown Source:115)
at androidx.appcompat.app.AppCompatDelegateImpl.createView(Unknown Source:8)

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

Ah I see! I forgot one small thing. Give me a second :)

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

Try again using version v48. Now, the method name should also be properly changed.

from dex2jar.

vramasam avatar vramasam commented on August 25, 2024

Okay @ThexXTURBOXx . Thank you. Will test and let you know

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

@vramasam Any news on this? :)

from dex2jar.

vramasam avatar vramasam commented on August 25, 2024

Hello @ThexXTURBOXx

Sorry for the delay response. The above error got resolved. We are seeing the following exception.

2022-04-07 12:30:05.898 21597-21597/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.xx.xxxx, PID: 21597
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.xxx.techapp/com.xxxx.xxxx.MainActivity}: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3763)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3939)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:85)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2278)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:246)
at android.app.ActivityThread.main(ActivityThread.java:8429)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:596)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)
Caused by: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.
at androidx.appcompat.app.AppCompatDelegateImpl.createSubDecor(Unknown Source:438)
at androidx.appcompat.app.AppCompatDelegateImpl.ensureSubDecor(Unknown Source:5)
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(Unknown Source:0)
at androidx.appcompat.app.AppCompatActivity.setContentView(Unknown Source:7)

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

Thanks for your feedback! Nice to hear that this issue has been resolved.
I will take a look at the new issue as soon as possible

from dex2jar.

vramasam avatar vramasam commented on August 25, 2024

Thank you @ThexXTURBOXx .

If you have any further updates on the ticket, please let us know.

from dex2jar.

ThexXTURBOXx avatar ThexXTURBOXx commented on August 25, 2024

Yes, I will! I think the main problem is that dex2jar is not the right tool for a complete, 100% working disassembling and reassembling of dex files.
There will always be errors because of incompatibilities between both instruction sets.
Depending on what you want to achieve, it might be worth to take a look at dexlib2 or even multidexlib2 (from DexPatcher). They provide nice functionality for parsing and manipulating these files (if that is what you want to do).

from dex2jar.

vramasam avatar vramasam commented on August 25, 2024

Ohh okay. Thank you for the update and suggestion. Then this issue is not possible to be fixed ?

from dex2jar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.