You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Adam Nichols (JIRA)" <ji...@apache.org> on 2010/06/15 18:05:24 UTC
[jira] Commented: (PDFBOX-749) Image colours going wrong when I
encrypt an existing pdf
[ https://issues.apache.org/jira/browse/PDFBOX-749?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12879012#action_12879012 ]
Adam Nichols commented on PDFBOX-749:
-------------------------------------
Is this a duplicate of https://issues.apache.org/jira/browse/PDFBOX-99?
> Image colours going wrong when I encrypt an existing pdf
> --------------------------------------------------------
>
> Key: PDFBOX-749
> URL: https://issues.apache.org/jira/browse/PDFBOX-749
> Project: PDFBox
> Issue Type: Bug
> Affects Versions: 1.2.0
> Reporter: Stephen Gallagher
>
> Hi, I am using pdfbox to open an existing pdf file with embedded images (png, gif etc). I am then using the security features to encrypt the pdf and generate a new pdf.
> In the new pdf the images have lost their original colours and have completely different colours. I thought 1.2 would fix this as I saw a bug report on it but it still occurs for me.
> Here is the code I am using:
> PDDocument document = null;
> document = PDDocument.load(infile);
> AccessPermission ap = new AccessPermission();
> int keyLength = 128;
> StandardProtectionPolicy spp = new StandardProtectionPolicy(ownerPassword, userPassword, ap);
> spp.setEncryptionKeyLength(keyLength);
> document.protect(spp);
> document.save(outfile);
> document.close();
> Steve
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.