Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Verify Digital Signatures in Documents using Java
// Verifying Digital Signatures in a PDF document using Signature API for Java by GroupDocs
Signature signature = new Signature("sample_signed.pdf");
DigitalVerifyOptions options = new DigitalVerifyOptions("certificate.pfx");
options.setComments("Test comment");
options.setPassword("1234567890");
// Verify Document Signatures
VerificationResult result = signature.verify(options);
if (result.isValid()) {
System.out.println("Document Verified Successfully !");
}
else {
System.out.println("Document Verification Failed.");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.