Welcome Guest Search | Active Topics | Sign In | Register

How to merge secured PDF files? Options
Oliver Hanappi
Posted: Thursday, September 26, 2013 7:00:18 AM
Rank: Newbie
Groups: Member

Joined: 8/27/2013
Posts: 5
Hi!

I want to merge some secured PDF files, where editing is not permitted. However I already get exceptions when trying to initialize the PdfDocument instances.

Code:
System.Exception: Catalog object not found.
   at EO.Pdf.PdfDocument..ctor(hh A_0)
   at EO.Pdf.PdfDocument..ctor(String fileName)

System.NullReferenceException: Object reference not set to an instance of an object.
   at EO.Pdf.Internal.dt.a(hh A_0)
   at EO.Pdf.Internal.hh.a(g3 A_0)
   at EO.Pdf.Internal.hh.a(Stream A_0, Boolean A_1)
   at EO.Pdf.Internal.hh.a(String A_0)
   at EO.Pdf.Internal.hh..ctor(String A_0, PdfDocumentSecurity A_1)
   at EO.Pdf.PdfDocument..ctor(String fileName)


Even if I supply the correct password for editing through an PdfDocumentSecurity instance, I get the same exceptions.

Here are some test files (password is "1234"):
https://dl.dropboxusercontent.com/u/9917425/secured.pdf
https://dl.dropboxusercontent.com/u/9917425/secured2.pdf

What am I doing wrong? With other libraries like Aspose.Pdf, merging such files is possible without supplying a password.

Best Regards,
Oliver Hanappi
eo_support
Posted: Thursday, September 26, 2013 9:59:39 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

We do not support these files yet. PDF supports multiple encryption methods. We only support the standard RC4 encryption/decryption algorithm. Your file uses AES. So we are not able to open it yet.

I believe theoretically it is possible to merge encrypt files without providing a password if both files have the same password and the same "security seed". However in reality this is rare. So in order to merge them properly, we always decode everything first, which requires the correct password.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.