APK signature, zipalign optimization (command line version)

Source: Internet
Author: User

1. Generate key: Keytool-genkey-alias demo.keystore-keyalg rsa-validity 40000-keystore demo.keystore

2. Signature file: Jarsigner-verbose-keystore demo.keystore-signedjar demo_signed.apk demo.apk demo.keystore

If the installation fails, add the parameter "-digestalg sha1-sigalg Md5withrsa" after re-signing the installation

If not available-tsa or-tsacert, this jar does not have a timestamp. If there is no timestamp, the user may not be able to verify the jar after the expiration date (XXXX-XX-XX) of the signer's certificate or any subsequent revocation date. "Warning Please add parameter"-tsa Https://timestamp.geotrust.com/tsa "after re-signing the installation

3, Alignment optimization: zipalign-v 4 demo_signed.apk final.apk

Reference: http://www.cnblogs.com/qianxudetianxia/archive/2011/04/09/2010468.html

Reference: http://blog.csdn.net/changcsw/article/details/45643607

APK signature, zipalign optimization (command line version)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.