Hi Andreas, Hi zyx, Andreas, thanks for your fixes and updates. @zyx: Could you please review them and maybe commit them to the repository? I don't have any time right now to follow patches.
Best regards, Dominik On Wed, Mar 5, 2014 at 6:11 PM, Andreas Brzesowsky < andreas.brzesow...@dots.de> wrote: > Okay, so attacht are my changes to add decryption support for AESV2 and > fix some issues with RC4V2 decryption. > With that you can now handle a lot more PDF files with PoDoFo. > > Changes: > - Added AESV2 decryption (PdfAESInputStream and > PdfEncryptAESBase::BaseDecrypt) > - Added "EncryptMetadata" is false support, for RC4V2 and AES (In Acrobat > the option has the name: "Encrypt all document contens except metadata") > - Added support for RC4V2 with enryption features that are only compatible > with Acrobat 6 ("V" > 2 and "R" > 3, but "CFM" = "V2") > > Remarks: > - Needed to change the last parameter of PdfEncrypt::Decrypt to a > reference (pdf_long &outLen). Because the output length is not the same as > the input length for AES (initial IV and padding is in the input). > - Needed to extend PdfInputStream::Read with a pTotalLeft parameter for > the AES decryption. Because the decryption needs to know when to finalize > the last chunk and to adjust the resulting length (initial IV and padding). > - Still open is the support for AESV3 decyption, which should not be so > complicated anymore, because of the now existing AESV2 descryption. > > So please check my changes and add them to the repository. > > Kind regards > > Andreas > > Am 27.02.2014 08:23, schrieb zyx: > > On Tue, 2014-02-25 at 14:25 +0100, Andreas Brzesowsky wrote: > > I have added some code to decode AESV2 InputStream, some fixes for RC4 > decoding and handling of the EncryptMetadata flag for RC4 and AESV2. > So some more encrypted pdf could be handled by PoDoFo. > I want to contribute my changes. > > Hello, > thanks for looking into this (I'm not a PoDoFo developer, but I'd like > to answer the below questions and thank you for your work). > > > Are there any rules like coding rules or additional test cases I > should consider before contribution? > > I do not think there is any written guide on coding style being used in > the PoDoFo code base, I did not find any at least, but the best would be > to pick some core file, like PdfDocument.c/.h and mimic its coding > style. > > With respect of adding test cases, it's always a good thing to have more > tests, to spot regressions, thus they are welcome, but not mandatory. > > > And how to contribute the best way? > > You can send the patch to this list, thus more people will be able to > test it, or send it directly to Dominik for a review. > Bye, > zyx > > > > -- > > [image: dots] <http://www.dots.de/en/> > > Andreas Brzesowsky > > dots Software GmbH > Schlesische Str. 27, 10997 Berlin, Germany > Phone: +49 (0)30 695 799-34, Fax: +49 (0)30 695 799-55 > andreas.brzesow...@dots.de > http://www.dots.de > > Amtsgericht (District Court): Berlin Charlottenburg HRB 65201 > Geschäftsführer (Managing Directors): Olaf Lorenz, Ken Osuga > Follow us on: [image: Twitter] <http://www.dots.de/?id=twitter> [image: > Youtube] <http://www.dots.de/?id=youtube> [image: > Xing]<http://www.dots.de/?id=xing> > > > ------------------------------------------------------------------------------ > Subversion Kills Productivity. Get off Subversion & Make the Move to > Perforce. > With Perforce, you get hassle-free workflows. Merge that actually works. > Faster operations. Version large binaries. Built-in WAN optimization and > the > freedom to use Git, Perforce or both. Make the move to Perforce. > > http://pubads.g.doubleclick.net/gampad/clk?id=122218951&iu=/4140/ostg.clktrk > _______________________________________________ > Podofo-users mailing list > Podofo-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/podofo-users > >
<<inline: youtube-sign.png>>
<<inline: logo_dots_software_50hoch.png>>
<<inline: twitter-sign.png>>
<<inline: xing-sign.png>>
------------------------------------------------------------------------------ Subversion Kills Productivity. Get off Subversion & Make the Move to Perforce. With Perforce, you get hassle-free workflows. Merge that actually works. Faster operations. Version large binaries. Built-in WAN optimization and the freedom to use Git, Perforce or both. Make the move to Perforce. http://pubads.g.doubleclick.net/gampad/clk?id=122218951&iu=/4140/ostg.clktrk
_______________________________________________ Podofo-users mailing list Podofo-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/podofo-users