Recover files from apk Google Play

混江龙づ霸主 提交于 2019-12-10 12:23:56

问题


Some time ago i uploaded to google play an app for my family restaurant which was something like showing the menu, timetable, prices..all that stuff. It's still in the google play and i have access to it by google developers but the problem is that i lost all the code.

Is there any way of recovering the data to add some new info and then update my app?

Thank you a lot.


回答1:


You'll need a rooted device for this:

Install the app to your device, and then take the apk off of the device using:

  1. Plug your “Rooted” Android device into your computer via the included USB cable.
  2. From your adb command line (usually C:\android-sdk-windows\tools\) type adb shell and press enter
  3. Switch to root user, type su and press enter
  4. type “cd data/app“ and press enter
  5. List all the installed apk files, type ls and press enter (find the one you want to extract)
  6. In another command window, pull one of the files on to your computer by typing: adb pull /data/app/application.apk name.apk and press enter

Once you have the apk, rename it to whatever.zip and extract it as a zip file. You will now see a bunch of folders. Anything in your assets folder can be recovered now right away. For the java code, you must use dex2jar to convert classes.dex to a .jar file. After that, you can use JD-GUI to read the code from the .jar file.

To extract AndroidManifest.xml and everything in res folder(layout xml files, images etc.) you must use APKTool Run the following command :

apktool.bat d sampleApp.apk

It also extracts the .smali file of all .class files, but these are difficult to read, and you should use the code from dex2jar instead.




回答2:


If you Obfusticate your code using progaurd while generating the APK file, then its not possible.

If not, you can decompile the classes some extent and making some changes to the decompiled class and you can get it working... There are few tools to decompile the APJK file

Thanks,



来源:https://stackoverflow.com/questions/14286372/recover-files-from-apk-google-play

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!