Files
FFmpeg/libavdevice
Mirkó Visontai ae981e6f0e avdevice/android_camera: fix OOB read in metadata parsing
ACAMERA_SCALER_AVAILABLE_STREAM_CONFIGURATIONS metadata is an
int32[n*4] array (one 4-tuple per stream config: format, width,
height, input/output flag). ACameraMetadata_const_entry.count is the
total number of int32_t elements, not the number of tuples. The loop
bound must be count/4 to avoid iterating past the end of the array.

Similarly, ACAMERA_CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES is an
int32[n*2] array (min/max pairs). The loop bound must be count/2.

Without this fix, both loops over-iterate and read heap memory
beyond the metadata array bounds.

Signed-off-by: Mirko Visontai <mirkov@google.com>
(cherry picked from commit 1588bce21b)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2026-08-02 06:03:03 +02:00
..
2025-08-03 13:48:47 +02:00
2025-06-15 21:00:38 +05:30
2024-03-31 00:08:43 +01:00
2026-06-26 02:43:34 +02:00
2025-08-03 13:48:47 +02:00