How Do I Sign .jar Files Using the CLI Command Jarsigner?
name=eToken
library=c:\WINDOWS\system32\eTPKCS11.dll
keytool -list -keystore NONE -storetype PKCS11 -providerclass sun.security.pkcs11.SunPKCS11 -providerArg ./eToken.cfg
Enter keystore password: [enter password]
Keystore type: PKCS11
Keystore provider: SunPKCS11-eToken
Your keystore contains 1 entry
7800FA4C81523ACA, PrivateKeyEntry,
Certificate fingerprint (SHA2):
XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX
jarsigner
-tsa http://tsa.quovadisglobal.com/TSS/HttpTspServer -verbose -keystore
NONE -storetype PKCS11 -providerClass sun.security.pkcs11.SunPKCS11
-providerArg ./eToken.cfg "C:\path\to\file.jar" "7800FA4C81523ACA"
Enter Passphrase for keystore:
adding: META-INF/7800FA4C.SF
requesting a signature timestamp
TSA location: http://tsa.quovadisglobal.com/TSS/HttpTspServer
adding: META-INF/7800FA4C.RSA
signing: samplejar.class
jar signed.