The SignServer JArchive Signer signs Java Archives (JAR) packages according to the JAR file specification.
Follow the instructions in the sections below to add and sign using the JArchive signer:
Add JArchive Signer
To add and configure the JArchive signer, do the following:
- Go to the Admin Web Workers tab and click Add.
- Add a worker by clicking From Template.
- Choose jarchive_signer.properties from the Load From Template list menu and click Next.
- Click Apply on the Configuration page to load the sample JArchiveSigner configuration.
Ensure that the JArchiveSigner worker is in state ACTIVE:
Submit and Sign file using JArchive Signer
The following describes how to submit and sign a JAR with the JArchive signer either using the SignServer Demo Web or the SignServer Client CLI SignClient.
Sign JAR using Demo Web
To download an example JAR and then submit and sign the file using the Demo Web, do the following:
- Download helloworld.jar to test JAR signing.
- Go to the SignServer Generic Signing and Validation Demo page on https://<yourinstancepublicdns>/signserver/demo/genericsign.jsp.
- Scroll down on the page to the Sign by File Upload section and specify JArchiveSigner in the Worker name field.
- Click Browse, select helloworld.jar and click Submit.
- You will be prompted to save the Signed JAR file helloworld.jar.
Sign JAR using Client CLI
To download an example JAR and then submit and sign the JAR using the Client CLI SignClient, do the following. Note that the Client CLI requires Java.
- Download the SignServer ClientCLI from the location: https://<yourinstancepublicdns>/signserver/clientcli-dist/signserver-clientcli.zip.
- Unzip signserver-clientcli.zip to the
signserver-clientcli
directory. - Copy helloworld.jar to the bin directory inside the
signserver-clientcli
directory. - Open a command (cmd) window if on a Windows system, or a terminal on Linux or Mac and change directory (cd) to the
bin
directory.
- Sign HelloPE.exe using SignClient:
- If you are on a Windows system, use the following command:
# signclient.cmd signdocument -host <yourinstancepublicdns> -port 80 -workername JArchiveSigner -infile helloworld.jar -outfile helloworldsigned.jar
CODE
- If you are on a Linux or Mac system, use the following command:
# ./signclient signdocument -host <yourinstancepublicdns> -port 80 -workername JArchiveSigner -infile helloworld.jar -outfile helloworldsigned.jar
CODE