2
1
mirror of https://github.com/qpdf/qpdf.git synced 2024-06-06 20:30:54 +00:00
qpdf/libqpdf/qpdf/Pl_AES_PDF.hh
Jay Berkenbilt 846c9f6bcc checkpoint -- started doing some R4 encryption support
git-svn-id: svn+q:///qpdf/trunk@807 71b93d88-0707-0410-a8cf-f5a4172ac649
2009-10-17 03:14:47 +00:00

28 lines
662 B
C++

#ifndef __PL_AES_PDF_HH__
#define __PL_AES_PDF_HH__
#include <qpdf/Pipeline.hh>
class DLL_EXPORT Pl_AES_PDF: public Pipeline
{
public:
// key_data should be a pointer to key_size bytes of data
static unsigned int const key_size = 16;
Pl_AES_PDF(char const* identifier, Pipeline* next,
bool encrypt, unsigned char* key_data);
virtual ~Pl_AES_PDF();
virtual void write(unsigned char* data, int len);
virtual void finish();
private:
void flush(bool discard_padding);
bool encrypt;
unsigned int offset;
static unsigned int const buf_size = 16;
unsigned char buf[buf_size];
};
#endif // __PL_AES_PDF_HH__