pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1679396 - /pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityHandler.java
Date Thu, 14 May 2015 16:15:14 GMT
Author: tilman
Date: Thu May 14 16:15:13 2015
New Revision: 1679396

URL: http://svn.apache.org/r1679396
Log:
PDFBOX-2576: COSStream is a COSDictionary; delete if-clause that is always true

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

Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityHandler.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityHandler.java?rev=1679396&r1=1679395&r2=1679396&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityHandler.java
(original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityHandler.java
Thu May 14 16:15:13 2015
@@ -454,14 +454,9 @@ public abstract class SecurityHandler
             {
                 COSBase value = entry.getValue();
                 // within a dictionary only the following kind of COS objects have to be
decrypted
-                if (value instanceof COSString || value instanceof COSStream || value instanceof
COSArray || value instanceof COSDictionary)
+                if (value instanceof COSString || value instanceof COSArray || value instanceof
COSDictionary)
                 {
-                    // if we are a signature dictionary and contain a Contents entry then
-                    // we don't decrypt it.
-                    if (!(entry.getKey().equals(COSName.CONTENTS) && value instanceof
COSString))
-                    {
-                        decrypt(value, objNum, genNum);
-                    }
+                    decrypt(value, objNum, genNum);
                 }
             }
         }



Mime
View raw message