Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Proguard retrace output confusion

I have here a stack trace from one of my games from android market. I have de-proguarded it but I can't really understand it!

I'm not asking for help in the error itself, but just how to interpret this.

I started with this from Market:

java.lang.IllegalArgumentException
at java.nio.Buffer.position(Buffer.java:299)
at com.a.a.k.o.a(Unknown Source)
at com.a.a.k.w.a(Unknown Source)
at com.a.a.k.w.onDrawFrame(Unknown Source)
at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1363)
at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1118)

But retrace.bat has output this, which is longer, so I can't tell what com.a.a.k.o.a is (for exmaple).

java.lang.IllegalArgumentException
at java.nio.Buffer.position(Buffer.java:299)
at com.eaw.graphics.WorldViewShader.void glSetMVPMatrix(float[])(Unknown Source)
                                    void glSetNormalMatrix(com.eaw.graphics.AMatrix)
                                    void SetVertices(java.nio.FloatBuffer)
                                    void ApplyArgs(com.eaw.graphics.WorldViewShaderArgs)
at com.eaw.graphics.TriangleRenderer.void onDrawFrame(com.eaw.airrace.ILayer,com.eaw.airrace.StepOutput,boolean)(Unknown Source)
                                     void loadTexture$332cd44f(int[],int,int)
                                     void delayedLoadTexture(int[],int[],int,int)
at com.eaw.graphics.TriangleRenderer.void onDrawFrame(javax.microedition.khronos.opengles.GL10)(Unknown Source)
at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1363)
at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1118)

Has it rolled 4 functions into 1 during obscuration? or what?

like image 720
weston Avatar asked Sep 15 '11 18:09

weston


People also ask

How do you Deobfuscate stack trace?

Get deobfuscated crash stacktrace from your app pageSign in to your Play Console. Select an app. On the left menu, click Android vitals > Deobfuscation files. Next to a version of your app, click Upload.

What is Dontwarn in ProGuard?

If your code works fine without the missing classes, you can suppress the warnings with '-dontwarn' options. (


2 Answers

You should add -keepattributes SourceFile,LineNumberTable to your proguard configuration file!

like image 139
thiagolr Avatar answered Oct 28 '22 00:10

thiagolr


Your processed code and stack trace doesn't contain line numbers, so ProGuard can't tell to which original method name the obfuscated method name 'a' corresponds. It then prints out all possible alternatives. Cfr. ProGuard's Retrace manual.

The manual also documents how you can preserve line numbers in the obfuscation step.

like image 40
Eric Lafortune Avatar answered Oct 28 '22 02:10

Eric Lafortune