Question

I've build pdf with pdfbox and by the hand. I have also Visible signature on pdf. everything works, but there is no image and text shown in PDF (but there is visible rectangle, without image and text). what do you think what happens?

can you see the sample? that's sample

enter image description here thank you.

enter image description here

Was it helpful?

Solution

I've build pdf with pdfbox and by the hand. [...] there is no image and text shown in PDF (but there is visible rectangle, without image and text).

That is exactly what you built your document and especially the signature related data to do:

3 0 obj
<<
/FT /Sig
/F 132
/T (Signature1)
/Type /Annot
/Subtype /Widget
/V 5 0 R
/P 4 0 R
/Rect [100 574 310 625]
/AP << /N 6 0 R >>
/DR << /XObject << /FRM0 7 0 R >> >>
>>
endobj 
6 0 obj
<<
/Type /XObject
/Subtype /Form
/Resources << /XObject << /FRM0 7 0 R >> >>
/BBox [0 0 100 100]
/FormType 1
/Length 8 0 R
>>
stream

endstream
endobj 
  1. There is a visible rectangle (actually after selecting the signature in question) because /Rect [100 574 310 625] in your signature field dictionary indicates the rectangular area where you have your signature.

  2. There is no image and text shown in PDF because the normal appearance stream (which according to /AP << /N 6 0 R >> in your signature field dictionary is defined in object 6) is defined as an empty stream (there is nothing but white space between stream and endstream).

    Most likely you wanted to place the xobject /FRM0 defined in the resources of the appearance stream. In that case you have the same problem in that xobject:

    7 0 obj
    <<
    /Type /XObject
    /Subtype /Form
    /Resources << /XObject << /n0 9 0 R /n1 10 0 R >> >>
    /BBox [0 0 100 100]
    /FormType 1
    /Length 11 0 R
    >>
    stream
    
    endstream
    endobj 
    

    This stream also is empty, you forgot to place the xobjects /n0 and /n1.

    Those xobjects look correctly defined but seem to be copied from samples from the early age of integrated PDF signatures.

Concerning the Adobe Acrobat error message observed by @stanlyF:

Error during signature verification.  

Signature contains incorrect, unrecognized, corrupted or suspicious data.
Support Information: SigDict /SubFilter value

The signature value dictionary also is incomplete:

5 0 obj
<<
/Type /Sig
/Name (sig1)
/ByteRange [0 0 0 0]
/Contents <0000...0000>
>>
endobj 
  1. The dictionary neither has a /Filter nor a /SubFilter entry. While nominally the filter is required and the subfilter is optional, interoperable signing mostly depends on the subfilter and the filter ist ignored. Thus the Support Information.
  2. The /Name entry is weird because it is specified to contain the name of the person or authority signing the document (if present)
  3. The signed byte range is empty: it consists of two seqgments, both of them starting at offset 0 and being 0 bytes long.
  4. The contained signature container itself consists only of 0x00 bytes.

OTHER TIPS

Acrobat said:

"Error during signature verification.  

Signature contains incorrect, unrecognized, corrupted or suspicious data.
Support Information: SigDict /SubFilter value"

Signature has incorrect/incomplete the content-closing marker.

And also /n0 /n1 XObjects in resources have no pdf instructions.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top