Forgot to mention... Have a look at 
http://www.cryptopp.com/wiki/Authenticated_encryption.

Discard the authenticated encryption suggestion if its OK for the bad
guy to tamper with your data.

On Oct 11, 6:58 pm, Jeffrey Walton <[email protected]> wrote:
> Hi Ben,
>
> > AESEncryptor::AESEncryptor(const string& passphrase,
> >   BufferedTransformation* attachment) : Filter(attachment)
> > {
> >   _passphrase = passphrase;
>
> > }
>
> Don't store the passphrase. Store a SecByteBlock, and stuff a KDF'd
> passphrase into it.
>
> Also, take a look at DefaultEncryptorWithMac. Its briefly discussed 
> inhttp://www.codeproject.com/KB/security/BlockCiphers.aspxunder the
> topic "Encryptors with MACs".
>
> Finally, you 
> havehttp://www.cryptopp.com/wiki/Filterandhttp://www.cryptopp.com/wiki/Filter_(Intermediate).
>  The Intermediate
> topics include creation of:
> * UselessFilter
> * BufferlessUselessFilter
> * AnchorFilter
>
> Jeff
>
> On Oct 11, 12:49 pm, Ben Botto <[email protected]> wrote:
>
> > I'm curious if I'm creating filters "correctly".  This works, just
> > making sure it is the right way of doing it.  I have created a class
> > to AES encrypt some data, and that works well.  I wanted to turn it
> > into a filter, and this is what I came up with.  The part I'm mainly
> > unsure of is buffering the data, as I haven't seen any of the other
> > filters do it this way.  My AES class needs all the data to decrypt,
> > so I buffer the data in the Put2 method until MesageEnd, at which time
> > I decrypt and pass the data on to the next BufferedTransformation.
> > Any comments are appreciated!
>
> > [SNIP]

-- 
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to [email protected].
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.

Reply via email to