Related Article(s):
Last active
February 1, 2024 07:27
-
-
Save GroupDocsGists/6bb0d45acb6cc872bc53c12c5eb70f8f to your computer and use it in GitHub Desktop.
How to Sign PDF with Digital Signature Certificate using Java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Java code to sign PDF with digital signature certificate using Java | |
Signature signature = new Signature("path/document.pdf"); | |
DigitalSignOptions options = new DigitalSignOptions("certificate.pfx"); | |
options.setImageFilePath("image.jpg"); | |
options.setLeft(100); | |
options.setTop(100); | |
options.setPageNumber(1); | |
options.setPassword("1234567890"); | |
// sign document to file | |
SignResult result = signature.sign("path/signed-document.pdf", options); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment