Android‎ > ‎

Unpacking and Repacking Apk

posted Feb 13, 2013, 1:04 AM by Akash Khaitan   [ updated Mar 9, 2013, 7:56 AM ]
Unpacking and repacking of Apk can be done using apktool

Get the Apktool from here
http://code.google.com/p/android-apktool/

The apk tool folder should contain the apktool executable and the apktool.jar

 Uncompress  apktool d file.apk
 Modify Files
 Modify desired values, drawables etc
 Repackage to Apk
 apktool b foldername new_akp.apk
 Sign the Repackaged Apk
jarsigner -verbose -keystore my-release-key.keystore ./HelloWorld/dist/HelloWorld.apk alias_name

OR
java -jar signapk.jar certificate.pem key.pk8 app.apk  app-signed.apk


Modified Apk needs to be signed.
In order to sign the modified Apk, use jarsigner or Signapk

Jarsigner (Asuming you have the keystore)
Use Jarsigner with java 1.6 and not 1.7
Issues with jar signer check below
Check the Jarsigner differences in java 1.6 and 1.7


SignApk
Generating keys for Signapk
http://android-dls.com/wiki/index.php?title=Generating_Keys



For Clear implementation, refer
http://blog.apkudo.com/2012/10/16/reverse-engineering-android-disassembling-hello-world/

http://forum.xda-developers.com/showthread.php?t=1466100

http://madteam.co/news/2011/10/how-to-use-apktool/



ċ
SignApk.zip
(9k)
Akash Khaitan,
Feb 13, 2013, 1:04 AM
Comments