APK code recovery

I recently deleted my hard drive and lost several weeks of work. Despite the fact that I often did this, I did not push my changes upstream for a while.

I extracted the APK application from my phone and I tried to recover its code. I assume this is possible, as it was a test build (and therefore not obfuscation or something like that).

The best result I could achieve was to use dex2jar , but I still have code like this:

int i = context.getResources().getDimensionPixelSize(2131165184); int j = context.getResources().getDimensionPixelSize(2131165184); screenNameParams.addRule(10); screenNameParams.addRule(1, 2131034138); screenNameParams.setMargins(paramInt, 0, 0, 0); 

Or even:

 long l1 = paramLong1; long l2 = paramLong2; long l3 = paramLong3; int i = paramInt; List localList = localClient.getBetween(l1, l2, l3, i); 

My experience with android-apktool was even worse, since I couldn't even get the Java code from it ... which is expected since it works with smali debugging.

I read all the related questions here, and I saw people say that it’s hard to get the actual source code for apk if you are not a developer, so there is hope since I am a developer.

Finally, my question is: is it possible to completely restore the source code of the APK, given that it was a test build from eclipse?

+4
source share
1 answer

In short, no. It seems that your code was launched through ProGuard and obfuscation (as is usually the case), and therefore you will not be able to get your source code. In your quote about being a developer, these people basically say: β€œIt's hard to get the source for the APK if you already have it because you are the developer,” but in this case, even if you are a developer, you lost the source.

The only last option I can think of is to try to find a hard drive recovery program and use it as soon as possible and see if you can restore your source. You may not have rewritten these sectors yet.

+3
source

All Articles