Thursday, 25 April 2013

Signing Jar Files with the "JJA" Sequence

Jar files can be signed using the following syntax [henceforth referred to as the "JJA" sequence]:

jarsigner jar-file alias

The alias identifies the private key used to sign the Jar file, and the key's associated certificate. Quite interesting how that alias works....it's a lookup into the Keystore, where each private and public key pair is identified by an alias, and a password is needed to access the private key. The keystore is generated by the Keytool.