On Thu, Jan 28, 2016 at 12:12:01AM +0100, Andreas Cadhalpun wrote: > On 27.01.2016 14:22, Michael Niedermayer wrote: > > From: Michael Niedermayer <[email protected]> > > > > TODO: Docs > > TODO: version bump > > > > Note to maintainers: update tools > > > > Note to maintainers: set a default whitelist for your protocol > > If that makes no sense then consider to set "none" and thus require the > > user to specify a white-list > > for sub-protocols to be opened > > > > Note, testing and checking for missing changes is needed > > > > Signed-off-by: Michael Niedermayer <[email protected]> > > --- > > libavformat/avformat.h | 7 +++++ > > libavformat/avio.c | 66 > > ++++++++++++++++++++++++++++++++++++++++--- > > libavformat/avio_internal.h | 4 +++ > > libavformat/aviobuf.c | 16 ++++++++--- > > libavformat/options_table.h | 1 + > > libavformat/url.h | 6 ++++ > > libavformat/utils.c | 13 ++++++--- > > 7 files changed, 101 insertions(+), 12 deletions(-) > > I generally like the approach, but the main problem now is that setting a > default protocol_whitelist doesn't quite work as intended. > This is because it is not propagated back to the AVFormatContext > protocol_whitelist, which is used (in the following patch) to forward > the whitelist when opening other protocols. > Thus I think there also needs to be a protocol_whitelist in the AVIOContext, > which can be used to propagate the whitelist set in ffurl_connect back > to the AVFormatContext.
ive added backwarding to AVFormatContext, this requires manual
overiding for rtp at least though
> This forwarding could be done in ffio_open_whitelist (URLContext->AVIOContext)
> and ffio_open2_wrapper (AVIOContext->AVFormatContext), and the latter could
> then be used instead of ffio_open_whitelist.
>
> > diff --git a/libavformat/avformat.h b/libavformat/avformat.h
> > index 285bb16..273a6ae 100644
> > --- a/libavformat/avformat.h
> > +++ b/libavformat/avformat.h
> > @@ -1827,6 +1827,13 @@ typedef struct AVFormatContext {
> > * Demuxing: Set by user.
> > */
> > int (*open_cb)(struct AVFormatContext *s, AVIOContext **p, const char
> > *url, int flags, const AVIOInterruptCB *int_cb, AVDictionary **options);
> > +
> > + /**
> > + * ',' separated list of allowed protocols.
> > + * - encoding: unused
>
> Really?
> The following patch also uses the whitelist in various *enc.c files.
yes, ive changed a few as i thought, "why not, when iam already
changing things".
I dont think it should be documented to work before its finished
and tested
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Let us carefully observe those good qualities wherein our enemies excel us
and endeavor to excel them, by avoiding what is faulty, and imitating what
is excellent in them. -- Plutarch
signature.asc
Description: Digital signature
_______________________________________________ ffmpeg-devel mailing list [email protected] http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
