mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-13 10:30:05 +01:00
avformat/options: log filename on open
The loglevel is choosen so that the main filename and any images of
multi image sequences are shown only at debug level to avoid
clutter.
This makes exploits in playlists more visible. As they would show
accesses to private/sensitive files
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 53e0d5d724)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
@@ -532,6 +532,7 @@ int avformat_open_input(AVFormatContext **ps, const char *filename,
|
||||
if ((ret = av_opt_set_dict(s, &tmp)) < 0)
|
||||
goto fail;
|
||||
|
||||
av_strlcpy(s->filename, filename ? filename : "", sizeof(s->filename));
|
||||
if ((ret = init_input(s, filename, &tmp)) < 0)
|
||||
goto fail;
|
||||
s->probe_score = ret;
|
||||
@@ -569,7 +570,6 @@ int avformat_open_input(AVFormatContext **ps, const char *filename,
|
||||
}
|
||||
|
||||
s->duration = s->start_time = AV_NOPTS_VALUE;
|
||||
av_strlcpy(s->filename, filename ? filename : "", sizeof(s->filename));
|
||||
|
||||
/* Allocate private data. */
|
||||
if (s->iformat->priv_data_size > 0) {
|
||||
|
||||
Reference in New Issue
Block a user