What is the Difference between Jar signer and Apk signer?

夙愿已清 提交于 2019-12-05 07:32:46

jarsigner is designed for signing JAR files and does not know anything about APKs and Android, whereas apksigner is designed for signing APK files and knows what requirements Android places on APK signatures. For example, jarsigner does not produce APK Signature Scheme v2 signatures introduced in Android Nougat, whereas apksigner does. Another example is that jarsigner does not know that APKs which need to run on API Level 17 or lower must not use SHA-256 digests in their signatures, whereas apksigner knows that.

If you want to sign an APK using one of these tools, use apksigner.

EDIT: Here's the official documentation about signing from command-line: https://developer.android.com/studio/publish/app-signing.html#signing-manually

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!