// For complete examples and data files, please go to https://github.com/groupdocs-signature/GroupDocs.Signature-for-Java
// setup Signature configuration
SignatureConfig signConfig = CommonUtilities.getConfiguration();
// instantiating the conversion handler
SignatureHandler handler = new SignatureHandler(signConfig);
// setup digital verification options
CellsVerifyDigitalOptions verifyOptions1 = new CellsVerifyDigitalOptions(CommonUtilities.getCertificatePath("acer.pfx"));
//password is needed to open .pfx certificate
verifyOptions1.setPassword("1234567890");
CellsVerifyDigitalOptions verifyOptions2 = new CellsVerifyDigitalOptions(CommonUtilities.getCertificatePath("certificate.cer"));
VerifyOptionsCollection verifyOptionsCollection = new VerifyOptionsCollection(verifyOptions1, verifyOptions2);
//verify document
VerificationResult result = handler.verify(CommonUtilities.getStoragePath(fileName), verifyOptionsCollection);
System.out.println("Signed file verification result: " + result.isValid());