1

I have trouble finding a library capable for digital signing PDF.

I was able to create .Net app for signing but now I need dll that will work without .Net framework.

Does anyone knows good lightweight library for that? Commercial/NonCommercial

Community
  • 1
  • 1
Nikola Loncar
  • 2,611
  • 1
  • 26
  • 38

1 Answers1

0

I am not sure if it classifies as "lightweight", but you could try with Amyuni PDF Creator ActiveX (commercial). You can use it from C++, Delphi, VB etc. The current version (4.5) takes about 4.7Mb.

Take a look at the documentation for the method DigitalSignature for more details.

Sample code in VB from the documentation:

Private Sub cmdSingDocument_Click ()    
With PDFCreactiveX1    
.Open( "document.pdf", "" )    
.DigitalSignature("Amyuni Dev Signature", "Testing",    
 "signatureImage.jpg", "Montreal", 1, 100, 100, 400, 200, 1 + 2 + 4 + 8)    
.Save("signed.pdf", "" )    
End With    
End Sub

Usual disclaimer applies.

yms
  • 10,361
  • 3
  • 38
  • 68
  • Something completely different: On [documentation](http://stackoverflow.com/documentation/pdf/5161/integrated-pdf-signatures/18525/the-signed-byte-range#t=201610210600075019686) you claimed "I have seen PDF signatures with the byte-range specified for the page contents only. They worked just fine in Acrobat Reader." There is no way to ask back there, so I do it here in a comment: Can you share a sample file for that? It should not be possible, at least not interoperably in current Reader versions – mkl Oct 21 '16 at 06:09
  • @mkl I am no longer working in the pdf field, so I lost access to the files database that had those samples. The interoperability however I cannot garantee it, it may very well not work anymore on most recent readers. This was about 4 years ago, by the time I wrote this: http://stackoverflow.com/questions/12074543/comparing-a-signed-pdf-to-an-unsigned-pdf-using-document-hash/12957758#12957758 – yms Oct 21 '16 at 14:38
  • At the bottom of that answer you mention you quote from a PDF Reference concerning an object digest. If the signatures you saw signing a single page only were actually object digest signatures, not byte range digest signatures, that would make sense to me. Object digest signatures did not make it into the ISO specification. – mkl Oct 21 '16 at 17:20