How To Sign Java .jar Files Using an EV Code Signing Certificate
|
|
Use Command Jarsigner with the CLI (Command Line Interface) to sign Java .jar files
name=eToken 2. In Windows Explorer, navigate to the JDK folder. 3. In the JDK folder, push and hold Shift, right-click on the bin folder, and select "Open command window here". 4. To view the COMODO EV Code Signing Certificate and the certificate alias on the token: Plug in your token. Run the following command from the command prompt: keytool -list -keystore NONE -storetype PKCS11 -providerclass sun.security.pkcs11.SunPKCS11 -providerArg ./eToken.cfg Keystore type: PKCS11 In this example, LWRCNIB4RGJRA8Am is the certificate alias that you use to sign .jar files. To use the EV code signing certificate on the token to sign file.jar, run the following command from the command prompt: jarsigner -tsa http://timestamp.comodoca.com -verbose -keystore NONE -storetype PKCS11 -providerClass sun.security.pkcs11.SunPKCS11 -providerArg ./eToken.cfg "C:\path\to\file.jar" "LWRCNIB4RGJRA8Am" Sample output: Enter Passphrase for keystore: | |
|