avformat/hls: Fix DoS due to infinite loop
authorMichael Niedermayer <michael@niedermayer.cc>
Fri, 25 Aug 2017 23:26:58 +0000 (01:26 +0200)
committerMike Gabriel <sunweaver@debian.org>
Sat, 31 Aug 2019 15:36:55 +0000 (16:36 +0100)
commitba651381f0cb6c3fb3670588b56f94af81dd7da3
treea447d0b00e5405fe9de7856cd36c71e428f6ce98
parent9aa83245fa55408b15ecd9782e458a506338a388
avformat/hls: Fix DoS due to infinite loop

Fixes: loop.m3u
The default max iteration count of 1000 is arbitrary and ideas for a better solution are welcome

Found-by: Xiaohei and Wangchu from Alibaba Security Team
Previous version reviewed-by: Steven Liu <lingjiujianke@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
[sunweaver] Rebased against a libavformat/hls.c version that did not yet have AVOption support.
            Initializing HLS_Context.max_reload statically with the value 1000.

Gbp-Pq: Name CVE-2017-14058.patch
libavformat/hls.c