[Botan-devel] Computing total length for enc / dec
barathraghavan at gmail.com
Mon Jun 28 00:12:19 EDT 2010
I'm using the EAX mode of operation with AES and am serializing (to disk/network) in raw form. To enable decryption I need to communicate, in advance, the IV and the message length (the length of both the ciphertext and the tag).
Is there a good way of having Botan calculate this total length value for me in advance of giving it the data? I'd rather not buffer all the data I'm encrypting just so I can determine how long it's going to be. I know I can calculate it manually (by adding the length of the file to the tag length), but it seems brittle to do it that way, especially if the underlying implementation changes or if I want to switch to a different mode / cipher.
More information about the botan-devel