How can I update the version of an APK which I did not create myself
I am new to Android development. I am using a x-platform development tool which builds and signs the APK for me. This tool has a bug and it does not generate APK's with the version code I specify, all APK's generated are version 1.0.
I would like to unpack the APK, edit the version code, and then resign and repackage it. It was signed using my keystore or开发者_开发知识库iginally, so I have the keys needed to sign it again.
How can this be done?
It should be possible; previously I've changed an existing APK's package name without access to the source.
However, you will probably need (and I don't have any more specific guides to hand):
- a hex editor
- a guide to the APK file format
- a way of calculating the APK checksum
You need to unzip the APK, alter the (binary-packed) AndroidManifest.xml
, alter the checksum in the resources.arsc
(I think) and then re-zip the APK.
Actually, in searching for a couple of these resources, I came across apktool
, which sounds promising.
I don't think that you can change the APK after it is packed and signed, since singing is there so that you actually can't change it anymore after signing.
What IDE are you using? E.g. Eclipse can also sign and build APK files and I've never seen a problem with the version number.
No, if it's signed.
Only the owner of key can change the .apk content.
精彩评论