[
https://issues.apache.org/jira/browse/PDFBOX-2729?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15087739#comment-15087739
]
Tilman Hausherr commented on PDFBOX-2729:
-----------------------------------------
This almost enables AES128 encryption, only the //TODO line must be implemented
so that it works by default.
Gleb, your solution has the problem that it reads and saves the file first, so
it is no longer the same before signing. Another problem is that we must
encrypt with the same method than initially done, which is why I implemented
AES128 too. A third problem will happen with AES256: this one has a random
component. We must find a way to keep the encryption key after loading the
file. Currently it is lost due to the SecurityHandler object being created a
second time for saving, I haven't fully understood that part yet.
> Can't sign encrypted PDF files
> ------------------------------
>
> Key: PDFBOX-2729
> URL: https://issues.apache.org/jira/browse/PDFBOX-2729
> Project: PDFBox
> Issue Type: Bug
> Components: Signing
> Affects Versions: 2.0.0
> Reporter: Cyril Bremaud
> Assignee: Andreas Lehmkühler
> Attachments: Scan0001.pdf, Scan0001_protected.pdf,
> Scan0001_protected_signed.pdf
>
>
> It is not possible to sign an encrypted PDF document.
> More details here :
> [http://stackoverflow.com/questions/29232684/signing-an-encrypted-pdf-document-with-pdfbox-2-0-0]
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]