[FFmpeg-devel] [PATCH] avformat/dashdec: only limit DASH manifest size according to AVBprint limits
Jan Ekström
jeebjp at gmail.com
Fri Sep 4 23:40:40 EEST 2020
On Thu, Sep 3, 2020 at 8:29 PM Jan Ekström <jeebjp at gmail.com> wrote:
>
> Currently the API is internally limited to unsigned integers, so if we
> limit the file size as well as the amount to read to UINT_MAX - 1, we
> do not require additional limiting to be performed on the values.
>
> This change is based on the fact that initially the 8*1024 value added
> in 96d70694aea64616c68db8be306c159c73fb3980 was only for the case where
> the file size was not known. It was not a maximum file size limit.
>
> In 29121188983932f79aef8501652630d322a9974c this was reworked to be
> a maximum manifest file size limit, while its commit message appears
> to only note that it added support for larger manifest file sizes.
>
> This should enable various unfortunately large MPEG-DASH manifests,
> such as Youtube's multi-megabyte live stream archives to load up
> as well as bring back the original intent of the logic.
> ---
Got some reviews regarding the commit message on IRC, and have updated
it to the following:
avformat/dashdec: drop arbitrary DASH manifest size limit
Currently the utilized AVBPrint API is internally limited to unsigned
integers, so if we limit the file size as well as the amount to read
to UINT_MAX - 1, we do not require additional limiting to be performed
on the values.
This change is based on the fact that initially the 8*1024 value added
in 96d70694aea64616c68db8be306c159c73fb3980 was only for the case where
the file size was not known. It was not a maximum file size limit.
In 29121188983932f79aef8501652630d322a9974c this was reworked to be
a maximum manifest file size limit, while its commit message appears
to only note that it added support for larger manifest file sizes.
This should enable various unfortunately large MPEG-DASH manifests,
such as Youtube's multi-megabyte live stream archives to load up
as well as bring back the original intent of the logic.
---
Jan
More information about the ffmpeg-devel
mailing list