Aspose.Word for Java - sign PDF using CAC Card

We are using Aspose.Word for Java to generate PDF documents from our J2EE application. As a next step in our process, we need the ability to sign those PDFs using CAC Card. Does Aspose.Word have that capability ? If it does, can you share some write-up and samples on that.

Hi Naresh,

Thanks for your inquiry. Please use PdfSaveOptions.setDigitalSignatureDetails method to set the details for signing the output PDF document. Please read the detail of PdfDigitalSignatureDetails class from here:
https://reference.aspose.com/words/java/com.aspose.words/PdfDigitalSignatureDetails

Following code example shows how to digital sign a PDF document.

PdfDigitalSignatureDetails signatureDetails = new PdfDigitalSignatureDetails(MyDir + "cert.p12","testpdf", "Test Signing", "Aspose Office", new java.util.Date());
Document doc = new Document();
PdfSaveOptions saveOptions = new PdfSaveOptions();
saveOptions.setDigitalSignatureDetails(signatureDetails);
doc.save(MyDir + "Out.pdf", saveOptions);

I hope, this helps.

Best regards,