[botan-devel] Possible bug

Navin Shajan navin.kurupacheril at gmail.com
Sun Feb 16 20:45:20 EST 2014


Did you forget to initialize botan?
http://botan.randombit.net/manual/firststep.html#initializing-the-library


On Sun, Feb 16, 2014 at 4:52 PM, Sviatoslav Feshchenko <
sviatoslav at outlook.com> wrote:

> Dear Botan developers,
>
> I suspect there may be a bug in the library or I made an error somewhere
> (and if so I apologize). My environment is as follows:
>
> Botan version: 1.11.8
> OS: Linux Mint 16 Cinnamon 64-bit
> G++ v 4.8.1
>
> Pipe::start_msg() causes a segmentation fault depending on how the pipe
> was set up, as demonstrated in the compilable code below. Many thanks for
> looking into this.
>
>
>
> #include "botan/botan.h"
> #include "botan/bzip2.h"
>
> using namespace Botan;
>
> int main()
> {
>     AutoSeeded_RNG rng;
>     SymmetricKey key(rng, 32);
>     InitializationVector iv(rng, 16);
>
>     Keyed_Filter * decryptor = get_cipher("AES-256/CBC", key, iv,
> DECRYPTION);
>     Bzip_Decompression * decompressor = new Bzip_Decompression();
>
>     //start_msg() will seg fault if pipe is set up in this way
>     Pipe * decryptionPipe = new Pipe(decryptor, decompressor);
>
>     //if the pipe is set up in any of the following ways, start_msg()
> executes normally
> //    Pipe * decryptionPipe = new Pipe(decompressor, decryptor);
> //    Pipe * decryptionPipe = new Pipe(decryptor);
> //    Pipe * decryptionPipe = new Pipe(decompressor);
>
>     //seg fault here
>     decryptionPipe->start_msg();
>
>     return 0;
> }
>
> _______________________________________________
> botan-devel mailing list
> botan-devel at randombit.net
> http://lists.randombit.net/mailman/listinfo/botan-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.randombit.net/pipermail/botan-devel/attachments/20140216/cd1b3218/attachment.html>


More information about the botan-devel mailing list