When publishing an application or a custom rom you need to sign the .apk or .zip files with a certificate using a private key. The Android system uses the certificate to identify the author of an application and establish trust relationship between applications. The classic way of doing this was to use keytool then sign it with jarsigner. But This Is Easy Way
member andyhamey has posted his simple easy to use tool.
It's very simple, it will take a signed or unsigned apk and re-sign.
It will also batch sign all apk's that are in the INPUT folder.
It also includes the tools needed to create your own signature to sign the apk's
New Feature in v0.4
Included required Java files.
No need for a separate Java installation.
Code:
Changelog v0.4
1. Included the required java files.
2. Tidied the Sign & ZipAlign code.
3. Quicker ZipAligning
4. Stopped the "_signed" & "_za" from being added to the filename.
-----------------
Changlog v0.3
1. Private Key now generated with 2048bit encryption (was 1024)
2. Private Key now valid for 10,000 days (was 999)
3. Zipalign added to the script, will prompt upon signing completion.
Changelog v0.4
1. Included the required java files.
2. Tidied the Sign & ZipAlign code.
3. Quicker ZipAligning
4. Stopped the "_signed" & "_za" from being added to the filename.
Instructions
Test Keys
---------
Put your customised/unsigned .apk into INPUT
Double click ApkSigner_TEST_KEYS.bat
Follow propmts.
Signed .apks will be in OUTPUT
Its that easy.
Personal Keys
-------------
If you wish to sign using your own keys, Use the included generator,
then drop the certificate.rem & key.pk8 files into "Files",
then run ApkSigner_PERSONAL_KEYS.bat
Troubleshooting
---------------
This tool assumes you have added java to your PATH in Environment Variables.
So if you experience issues with "java", locate where java is installed on
YOUR system and edit line 21 in ApkSigner~.bat to reflect YOUR JDK (java) location.
For more information read:
- why you need to sign apk's here
- zipalign