[FFmpeg-devel] [PATCH] avformat/dhav: Limit get_duration() iterations

Kieran Kunhya kieran618 at googlemail.com
Sun Nov 14 21:36:59 EET 2021


> diff --git a/libavformat/dhav.c b/libavformat/dhav.c
> index b6bb25204c2..6c1cdde32c9 100644
> --- a/libavformat/dhav.c
> +++ b/libavformat/dhav.c
> @@ -234,12 +234,13 @@ static int64_t get_duration(AVFormatContext *s)
>      int64_t start_pos = avio_tell(s->pb);
>      int64_t start = 0, end = 0;
>      struct tm timeinfo;
> +    int max_interations = 100000;
>

I don't think this should be allowed.

Kieran


More information about the ffmpeg-devel mailing list