SIGNAPK(1)
π SIGNAPK(1) π
okay bestie, gather round, because this is the tool for signing JARs and APKs and it's lowkey iconic π
β¨ NAME β¨
signapk β the JAR and APK signing tool. that's it, that's the whole vibe π«Ά
πΈ SYNOPSIS πΈ
it's a command line tool for signing Android ZIP/JAR/APK files, and here's the shape of it:
signapk [-w] [-a alignment] [-providerClass className] publickey.x509[.pem] privatekey.pk8 [publickey2.x509[.pem] privatekey2.pk8 ...] input.jar output.jar signapk file.jar
and just so we're clear: input.jar is an existing file to sign. yes bestie, it has to already exist, we're signing it not summoning it π
π¦ DESCRIPTION π¦
so what does she actually do? she signs ZIP files β and that includes JARs, APKs, and Over-The-Air (OTA) updates β in a way that's compatible with Android's mincrypt verifier, using EC or RSA keys and SHA1 or SHA-256. no cap.
she can also sign APKs using APK Signature Scheme v2. and fr fr, this is the standard tool used to sign APK and JAR files distributed as part of Android ROMs. main character energy only π
π HISTORICAL NOTE π
okay this part is giving lore, and you need it:
- before the KitKat release (aka 4.4.2 aka android-19),
signapkstraight up ignored the signature algorithm specified in the certificate and always usedSHA1withRSA. not me being stubborn π - starting with JellyBean-MR2 (aka 4.3 aka android-18), the platform supports
SHA256withRSA, so we use the signature algorithm in the certificate to select which one to use (SHA256withRSAorSHA1withRSA). also in JellyBean-MR2, EC keys are supported π¦β¨ - and because there are old keys still in use whose certificate actually says
MD5withRSAβ yeah, MD5, in this economy β those get treated as though they saySHA1withRSAfor compatibility with older releases. periodt π
π SEE ALSO π
π AUTHORS π
The Android Open Source Project. π
and that's the whole page bestie β this was SIGNAPK(1), brought to you by The Android Open Source Project, and she ate, no crumbs. go sign something πβ¨π
π¦ where this page comes from
- debian bookworm: signapk 1:10.0.0+r36-1 Β· Apache-2.0
- debian trixie: signapk 1:10.0.0+r36-1.1 Β· Apache-2.0
- ubuntu jammy: signapk 1:10.0.0+r36-1 Β· Apache-2.0
- ubuntu noble: signapk 1:10.0.0+r36-1ubuntu2 Β· Apache-2.0
- ubuntu questing: signapk 1:10.0.0+r36-1.1
- ubuntu resolute: signapk 1:10.0.0+r36-1.1build1 Β· Apache-2.0
- ubuntu stonking: signapk 1:10.0.0+r36-1.1build1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms