Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[core]smali code has these methods, but pseudo code does not have these methods #1170

Closed
xmhwws opened this issue May 18, 2021 · 5 comments
Closed
Labels
bug Core Issues in jadx-core module

Comments

@xmhwws
Copy link

xmhwws commented May 18, 2021

windows10
Latest beta version of jadx
apk link:https://drive.google.com/file/d/1ns6UdqPvwopEFbLIB1e6s_HXoxWR3N_S/view?usp=sharing
class:com.bat.conversation.ui.search.SearchMainActivity

smali code has these methods, but pseudo code does not have these methods
JADX SMALI
JADX1

in GDA:
GDA

Jadx setting:
jadx 设置

@xmhwws xmhwws added Core Issues in jadx-core module bug labels May 18, 2021
@skylot
Copy link
Owner

skylot commented May 18, 2021

@xmhwws looks like these methods was inlined.
Do you need an option to disable method inlining? Or maybe don't remove methods after inline?

@skylot
Copy link
Owner

skylot commented May 18, 2021

Well, this feature already was reported as issue in #1109, so looks like jadx definitely need some improvement here.
Maybe mode for low level compare with bytecode like I mention previously in #1109 (comment):

Actually it is a big issue in jadx: different people use jadx differently, but I don't want to add switches for every small feature in jadx. That will cause tons of options, and it will be hard to test, reproduce issues and maintain.
I was thinking about some kind of predefined 'profiles' which will combines some switches. I see 3 of them for now:

  1. low-level - for compare with bytecode, like fallback but more precise (types, var names)
  2. compilable - for compilation or code analysis - will disable some unstable feature, so code will be more verbose.
  3. readable - full set of jadx features, result is compact and readable code, possible errors can revert to previous profiles for affected methods or classes.

@xmhwws
Copy link
Author

xmhwws commented May 18, 2021

@xmhwws looks like these methods was inlined.
Do you need an option to disable method inlining? Or maybe don't remove methods after inline?

If these methods disappear due to being inlined, please keep them displayed normally.
I monitored the method calling process of APK and found that these methods were called. Then I didn't find these methods in jadx. I was a little bit crashed at that time.

@busmaker
Copy link
Contributor

Inlining methods is great for reading and understanding the code, meanwhile people may want to hook such inlined methods and it causes inconvenience.

I think we can keep inlining these methods but don't remove them and add an auto-comment at the places they're being inlined.

@skylot
Copy link
Owner

skylot commented May 18, 2021

comment at the places they're being inlined

Sometime this can be in a complex expression and inserting inplace comment will make it more complex and hard to read.

Anyway, as a quick fix I add an option to completely disable methods inline.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Core Issues in jadx-core module
Projects
None yet
Development

No branches or pull requests

3 participants