webp icon indicating copy to clipboard operation
webp copied to clipboard

Encoding is unsound

Open purplesyringa opened this issue 1 year ago • 0 comments

This library does not verify that image.len() >= width * height * channels before passing data to WebPPictureImportRGB(A), resulting in segfault on this example:

fn main() {
    webp::Encoder::from_rgb(&[], 16383, 16383).encode_lossless();
}

purplesyringa avatar Sep 06 '24 18:09 purplesyringa