Once installed and configured, you can integrate the Signing Automation Client with a signing application. For example, you can run the signature samples provided with the iText library for Java.
To run the iText signature samples
- Configure a service subscription as explained in Managing tokens with Entrust Certificate Services cloud.
- On your computer, install:
- The PKCS #11 library, as explained in Installing the PKCS #11 library with the Signing Automation Client.
- Oracle JDK 8
- The Eclipse IDE
- Open a web browser in https://github.com/itext/i7js-signatures
- Click on Code > Download ZIP
- Download the ZIP file on your computer.
Unzip the downloaded file into a working folder on your PC. For example:
C:\Projects\i7js-signatures-develop
- Launch the Eclipse IDE.
- Select File > Import > General > Projects from Folder or Archive.
- In Import source, indicate the path of the unzipped iText samples.
- Click Finish.
Add a subfolder to the project. For example:
C:\Projects\i7js-signatures-develop\config
In this new subfolder, create the files described in the following sections.
In the Eclipse navigation pane, browse to i7js‑signatures‑develop > src/test/java > com.itextpdf.samples.signatures.chapter04
In the navigation pane, double-click C4_01_SignWithPKCS11HSM.java
Update the file contents as explained in C4_01_SignWithPKCS11HSM.java.
In the Eclipse navigation pane, right-click C4_01_SignWithPKCS11HSM.java and select Run As > Java Application.
Open the generated file with Adobe Acrobat Reader.
C:\Projects\i7js-signatures-develop\target\signatures\chapter04\hello_hsm.pdf
Check that the generated PDF file includes an embedded signature and a timestamp.