DenLindy, DenLindy wrote > I still do not understand how to put the signature in the sig field with > the MakeSignature.signDetached() method.
MakeSignature.signDetached() isn't the method you need: It is intended for signing libraries / devices which produce naked signatures, not full-fledged PKCS#7 containers. I'm afraid that there is no generic method for your use case yet; instead you'll have to copy everything from MakeSignature.signDetached() that is not specific to creating a signature container and add your arxCoSignService.getSignatureOfDataBuffer call instead. But does the sign service really require the data to sign to be a byte[]? Or is there some analogous method arxCoSignService.getSignatureOfDataStream accepting an InputStream instead? In the latter case you should apply that other method to sap.getRangeStream(). What kind of PKCS7 signature container does that service return? Is it more along the lines of a more modern CAdES signature? Or some more old-fashioned profile? Depending on that you can decide whether to use PdfName.ETSI_CADES_DETACHED or PdfName.ADBE_PKCS7_DETACHED. Regards, Michael -- View this message in context: http://itext-general.2136553.n4.nabble.com/Signing-a-PDF-with-itext-using-an-ARX-CoSign-device-tp4656792p4656848.html Sent from the iText - General mailing list archive at Nabble.com. ------------------------------------------------------------------------------ LogMeIn Central: Instant, anywhere, Remote PC access and management. Stay in control, update software, and manage PCs from one command center Diagnose problems and improve visibility into emerging IT issues Automate, monitor and manage. Do more in less time with Central http://p.sf.net/sfu/logmein12331_d2d _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php