pdfbox-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tilman Hausherr (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (PDFBOX-3149) Failure to decrypt empty strings (AES 128)
Date Wed, 02 Dec 2015 21:38:11 GMT

    [ https://issues.apache.org/jira/browse/PDFBOX-3149?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15036445#comment-15036445
] 

Tilman Hausherr edited comment on PDFBOX-3149 at 12/2/15 9:38 PM:
------------------------------------------------------------------

Could you attach a file that fails? I tried to reproduce the problem in TestSymmetricKeyEncryption.java,
because I wanted a test that fails without the patch, but the test never fails :-(

The reason is that we don't support AES128 encryption, only decryption.


was (Author: tilman):
Could you attach a file that fails? I tried to reproduce the problem in TestSymmetricKeyEncryption.java,
because I wanted a test that fails without the patch, but the test never fails :-(

> Failure to decrypt empty strings (AES 128)
> ------------------------------------------
>
>                 Key: PDFBOX-3149
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3149
>             Project: PDFBox
>          Issue Type: Bug
>          Components: Crypto, Parsing, PDModel
>    Affects Versions: 2.0.0
>            Reporter: Jesse Long
>            Assignee: Tilman Hausherr
>            Priority: Minor
>         Attachments: PDFBOX-3149.patch
>
>
> SecurityHandler fails to decrypt empty strings in a AES 128 encrypted PDF. 
> Strings like: <</Name ()>>
> This is because it tries to read the first 16 bytes as the AES IV, failing which it throws
IOException. Solution: if you cannot read any bytes from the stream, it is empty and so there
is nothing to decrypt.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: dev-help@pdfbox.apache.org


Mime
View raw message