FFmpeg before 9.1 contains a heap out-of-bounds read vulnerability in libavfilter/vf_lut2.c because the second input's pixel format is unrestricted when the output depth option is set. Attackers can supply crafted media such as monoblack BMP or PBM images to index beyond lookup tables, crashing applications or leaking heap contents into output video.
https://www.vulncheck.com/advisories/ffmpeg-before-9.1-heap-out-of-bounds-read-via-lut2-filter
https://github.com/FFmpeg/FFmpeg/commit/6b11ad5b5724806dbee653482088af4bf4dce97b
https://github.com/FFmpeg/FFmpeg/blob/n9.0.2/libavfilter/vf_lut2.c#L185
https://github.com/FFmpeg/FFmpeg