[FFmpeg-devel] [PATCH 2/2] [RFC]lavf/ffm: update with more options.
Lukasz Marek
lukasz.m.luki2 at gmail.com
Mon Nov 3 13:05:53 CET 2014
On 3 November 2014 01:31, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Sun, Nov 02, 2014 at 07:19:14PM +0100, Lukasz Marek wrote:
>
>
> shouldnt all these values be checked to be within the allowed ranges
> for the corresponding AVOptions?
>
> being able to set so many field so arbitrarily could be usefull to
> some kind of exploit ...
>
Yes, it wouldn't hurt to set them via AVOption API which implies validation.
OTOH most options doesn't set any reasonable range, just INT_MIN - INT_MAX
Remarkable example:
{"ac", "set number of audio channels", OFFSET(channels), AV_OPT_TYPE_INT,
{.i64 = DEFAULT }, INT_MIN, INT_MAX, A|D|E},
I try to implement sending private options now and we will see how it
works. Maybe then I will change sending common options as well using
AVOption API.
More information about the ffmpeg-devel
mailing list