Am 13.05.2021 um 06:35 schrieb Ranjeet Kuruvilla:
https://community.adobe.com/t5/acrobat/flatten-pdf-after-signature/m-p/12032659#M312513

This seems to be what I wanted: All fields become readonly after at
least one is signed.


You could try this by doing the read-only assignment as an incremental save.

    field.setReadOnly(true);
    Set<COSDictionary> objectsToWrite = new HashSet<>();
    objectsToWrite.add(field.getCOSObject());
    doc.saveIncremental(fileOutputStream, objectsToWrite);

However Adobe will complain if the file was signed with a "no changes allowed" certification signature.

Tilman



On 12.05.21 20:42, Tilman Hausherr wrote:
Am 12.05.2021 um 16:27 schrieb Ranjeet Kuruvilla:
https://apache.googlesource.com/pdfbox/+/trunk/examples/src/main/java/org/apache/pdfbox/examples/signature/ShowSignature.java


I am using 2.0.23 and Preflight 2.0.23.

It is possible to sign a document and then change a field (check or
uncheck a checkbox for example).

I want to either

a. make it impossible to change a value after even one signature has
been given
use certification signature  ( SigUtils.setMDPPermission() ). While
saving incrementally will still be possible, Adobe will complain
(depending on the value used)

or

b. find out which field was altered after signature
If it is saved normally, then the signature verification will fail; if
you save incrementally, PDFBox can't tell, but Adobe will mention it.

Tilman


. How can I do that?

I do not think ShowSignature can do that.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to