Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

cbc.h

Go to the documentation of this file.
00001 #ifndef CRYPTOPP_CBC_H
00002 #define CRYPTOPP_CBC_H
00003 
00007 #include "filters.h"
00008 #include "modes.h"
00009 
00010 NAMESPACE_BEGIN(CryptoPP)
00011 
00013 
00016 class CBCRawEncryptor : protected CipherMode, public FilterWithBufferedInput
00017 {
00018 public:
00019         CBCRawEncryptor(const BlockTransformation &cipher, const byte *IV, BufferedTransformation *outQueue = NULL);
00020 
00021 protected:
00022         void FirstPut(const byte *) {}
00023         void NextPut(const byte *inString, unsigned int length);
00024         void LastPut(const byte *inString, unsigned int length);
00025 };
00026 
00028 
00031 class CBCRawDecryptor : protected CipherMode, public FilterWithBufferedInput
00032 {
00033 public:
00034         CBCRawDecryptor(const BlockTransformation &cipher, const byte *IV, BufferedTransformation *outQueue = NULL);
00035 
00036 protected:
00037         void FirstPut(const byte *) {}
00038         void NextPut(const byte *inString, unsigned int length);
00039         void LastPut(const byte *inString, unsigned int length);
00040 };
00041 
00043 
00045 class CBCPaddedEncryptor : protected CipherMode, public FilterWithBufferedInput
00046 {
00047 public:
00048         CBCPaddedEncryptor(const BlockTransformation &cipher, const byte *IV, BufferedTransformation *outQueue = NULL);
00049 
00050 protected:
00051         void FirstPut(const byte *) {}
00052         void NextPut(const byte *inString, unsigned int length);
00053         void LastPut(const byte *inString, unsigned int length);
00054 };
00055 
00057 
00059 class CBCPaddedDecryptor : protected CipherMode, public FilterWithBufferedInput
00060 {
00061 public:
00062         CBCPaddedDecryptor(const BlockTransformation &cipher, const byte *IV, BufferedTransformation *outQueue = NULL);
00063 
00064 protected:
00065         void FirstPut(const byte *) {}
00066         void NextPut(const byte *inString, unsigned int length);
00067         void LastPut(const byte *inString, unsigned int length);
00068 };
00069 
00071 
00075 class CBC_CTS_Encryptor : protected CipherMode, public FilterWithBufferedInput
00076 {
00077 public:
00082         CBC_CTS_Encryptor(const BlockTransformation &cipher, byte *IV, BufferedTransformation *outQueue, bool stealIV);
00083         CBC_CTS_Encryptor(const BlockTransformation &cipher, const byte *IV, BufferedTransformation *outQueue = NULL);
00084 
00085 protected:
00086         void FirstPut(const byte *inString);
00087         void NextPut(const byte *inString, unsigned int length);
00088         void LastPut(const byte *inString, unsigned int length);
00089 
00090         byte *m_iv;
00091 };
00092 
00094 
00098 class CBC_CTS_Decryptor : protected CipherMode, public FilterWithBufferedInput
00099 {
00100 public:
00101         CBC_CTS_Decryptor(const BlockTransformation &cipher, const byte *IV, BufferedTransformation *outQueue = NULL);
00102 
00103 protected:
00104         void FirstPut(const byte *inString) {}
00105         void NextPut(const byte *inString, unsigned int length);
00106         void LastPut(const byte *inString, unsigned int length);
00107 };
00108 
00109 NAMESPACE_END
00110 
00111 #endif

Generated at Mon Jan 15 01:16:30 2001 for Crypto++ by doxygen1.2.4 written by Dimitri van Heesch, © 1997-2000