Could you please explain me more in details eventually giving me some example (one for attached and one for detached) of what iText detached signature exactly means?
I found this wonderful documentation: iText digital signature pdf about iText digital signature but I'm still not sure I understand the iText detached signature concept.
Reading the documentation (see the link) I found this definition:
In PDF, we sometimes refer to a detached signature. According to Wikipedia, a detached signature is a type of digital signature that is kept ‘separate from its signed data’, as opposed to ‘bundled together into a single file’. This definition isn’t entirely correct in the context of PDF: the signature is enclosed in the PDF file, but the attributes of the signature are ‘part of the signature’, as opposed to ‘stored in the signature dictionary’.
where is not clear for me what "attributes of the signature" means (what signature attributes it's refer?)
Note that the author of the article (iText documentation) is working with this snippets of a signed PDF file:
%PDF-1.4
%âãÏÓ
3 0 obj
<</F 132/Type/Annot/Subtype/Widget/Rect[0 0 0 0]/FT/Sig
/DR<<>>/T(signature)/V 1 0 R/P 4 0 R/AP<</N 2 0 R>>>>
endobj
1 0 obj
<</Contents <0481801e6d931d561563fb254e27c846e08325570847ed63d6f9e35 ... b2c8788a5>
/Type/Sig/SubFilter/adbe.pkcs7.detached/Location(Ghent)/M(D:20120928104114+02'00')
/ByteRange [0 160 16546 1745 ]/Filter/Adobe.PPKLite/Reason(Test)/ContactInfo()>>
endobj
...
9 0 obj
<</Length 63>>stream
q
BT
36 806 Td
0 -18 Td
/F1 12 Tf
(Hello World!)Tj
0 0 Td
ET
Q
endstream
endobj
...
11 0 obj
<</Type/Catalog/AcroForm<</Fields[3 0 R]/DR<</Font<</Helv 5 0 R
/ZaDb 6 0 R>>>>/DA(/Helv 0 Tf 0 g )/SigFlags 3>>/Pages 10 0 R>>
endobj
xref
0 12
0000000000 65535 f
...
0000017736 00000 n
trailer
<</Root 11 0 R/ID [<08ed1afb8ac41e841738c8b24d592465><bd91a30f9c94b8facf5673e7d7c998dc>]/Info 7 0 R/Size 12>>
startxref
17879
%%EOF