Thursday, January 29, 2015

Decompiling Android ADK files

Decompile Android ADK files to understand how an application works or to gain an understanding of an undocumented API.

Step 1: Get the ADK file

Use AirDroid or you can grab .adk file from the phone itself.

If you rename the application.adk to application.zip, you can open the file and view much of the application except the code itself.

Note: Some applications are compiled using PhoneGap.  When renaming the apk to zip, check out the assets folder for the web data.

Step 2: Decompile ADK

To view the android java code, you must decompile the DEX file.

https://code.google.com/p/dex2jar/wiki/ModifyApkWithDexTool

windows shell

% cd c:\path-to-someApk.apk

% C:\dex2jar-version\d2j-dex2jar.bat someApk.apk

Step 3: Use a viewer to browse JAR file

After you've decompiled the dex file, you will have a .jar file.  There are many options for exploring this but here is an example

jd-gui




That is it!  Browse the code.


No comments:

Post a Comment