Last active
June 9, 2018 18:57
-
-
Save aknik/088aed3d725ee66cbed6baf83e32c1da to your computer and use it in GitHub Desktop.
smali java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
If you need to know the value of a string - e.g. a parameter - | |
you can use Log.d(String tag, String message) to log it to the system log. | |
const-string/jumbo v0, "YourTag" | |
invoke-static {v0, p1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I | |
If you are having trouble navigating the smali code and understand the flow of an app | |
you can use the following smali code. It will call Thread.dumpStack() which logs the current thread's call stack. | |
invoke-static {}, Ljava/lang/Thread;->dumpStack()V | |
--------------------------------------------------------------------------------------- | |
apktool d -r -s mod.apk #Extrae classes.dex | |
d2j-dex2jar mod/classes.dex #Decompila | |
java -jar /opt/jd-gui/jd-gui-1.4.0.jar #Visualiza el codigo java |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment