pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1855018 - /pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/PublicKeySecurityHandler.java
Date Fri, 08 Mar 2019 05:52:01 GMT
Author: tilman
Date: Fri Mar  8 05:52:01 2019
New Revision: 1855018

URL: http://svn.apache.org/viewvc?rev=1855018&view=rev
Log:
PDFBOX-4436: make PDCryptFilterDictionary a COSObjectable

Modified:
    pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/PublicKeySecurityHandler.java

Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/PublicKeySecurityHandler.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/PublicKeySecurityHandler.java?rev=1855018&r1=1855017&r2=1855018&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/PublicKeySecurityHandler.java
(original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/PublicKeySecurityHandler.java
Fri Mar  8 05:52:01 2019
@@ -156,7 +156,7 @@ public final class PublicKeySecurityHand
             if (array == null)
             {
                 PDCryptFilterDictionary defaultCryptFilterDictionary = encryption.getDefaultCryptFilterDictionary();
-                array = (COSArray) defaultCryptFilterDictionary.getCOSDictionary().getItem(COSName.RECIPIENTS);
+                array = (COSArray) defaultCryptFilterDictionary.getCOSObject().getItem(COSName.RECIPIENTS);
             }
             byte[][] recipientFieldsBytes = new byte[array.size()][];
             //TODO encryption.getRecipientsLength() and getRecipientStringAt() should be
deprecated
@@ -418,11 +418,11 @@ public final class PublicKeySecurityHand
         {
             array.add(new COSString(recipient));
         }
-        cryptFilterDictionary.getCOSDictionary().setItem(COSName.RECIPIENTS, array);
+        cryptFilterDictionary.getCOSObject().setItem(COSName.RECIPIENTS, array);
         encryptionDictionary.setDefaultCryptFilterDictionary(cryptFilterDictionary);
         encryptionDictionary.setStreamFilterName(COSName.DEFAULT_CRYPT_FILTER);
         encryptionDictionary.setStringFilterName(COSName.DEFAULT_CRYPT_FILTER);
-        cryptFilterDictionary.getCOSDictionary().setDirect(true);
+        cryptFilterDictionary.getCOSObject().setDirect(true);
         setAES(true);
     }
 



Mime
View raw message