You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Thomas Chojecki (JIRA)" <ji...@apache.org> on 2011/06/22 11:42:47 UTC

[jira] [Updated] (PDFBOX-1046) Decrypting malformed document with signature cause NPE

     [ https://issues.apache.org/jira/browse/PDFBOX-1046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thomas Chojecki updated PDFBOX-1046:
------------------------------------

    Attachment: decrypt_NPE_patch.txt

> Decrypting malformed document with signature cause NPE
> ------------------------------------------------------
>
>                 Key: PDFBOX-1046
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-1046
>             Project: PDFBox
>          Issue Type: Bug
>          Components: Parsing
>    Affects Versions: 1.5.0
>            Reporter: Thomas Chojecki
>         Attachments: decrypt_NPE_patch.txt
>
>
> I got a encrypted document that was destroyed by the signer.
> The decrypter can handle it but while searching for signatures, a null check is missing. This cause NPE.
> My patch will cause throw a IOException if something went wrong while decrypting. Another solution is just skipping the object (in my case the referenced object is missing) and continue.
> Maybe a errorhandling for the parser will be a good idea. So the user can decide how importan it is for him to parse a pdf properly and step off if a document isn't conform OR continue and risk to lose some information while parsing malformed documents. 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira