[FFmpeg-user] FFMeg Concat giving "unsafe file name" error on new server install

Moritz Barsnick barsnick at gmx.net
Tue Mar 29 20:50:56 CEST 2016


Hi Steven,

On Tue, Mar 29, 2016 at 10:36:49 -0500, Steven Burns wrote:

> Quick history - the application I have running is working fine on the
> original server Ubuntu 14.04. I was cloning the process to a second
> server for a backup but one step in the process is failing for a
> reason I can’t seem to find documentation on:

I somehow have the feeling that you were running an older version of
ffmpeg on said "original server", because the safe file mode was
introduced lately.

>From the fine documentation
https://www.ffmpeg.org/ffmpeg-formats.html#Options

    [...] A file path is considered safe if it does not contain a
    protocol specification and is relative and all components only
    contain characters from the portable character set (letters,
    digits, period, underscore and hyphen) and have no period at the
    beginning of a component.

That is obviously not the case for your concat file, it uses absolute
paths:
> [concat @ 0x3c12740] Unsafe file name '/media/scratch1/userVideos/225/usershot1.mp4'

The demuxer accepts the "-safe" option (obviously an input option, to
be placed before the corresponding input file):

    safe
        If set to 1, reject unsafe file paths.
        [...]
        If set to 0, any file name is accepted.

> The same process with same permissions and settings is working on the
> original box - Anyone experienced similar or have suggestions on what
> I could be missing?

I think this is not covered in the changelog, but easily found when
searching the docs. ;-)

Moritz


More information about the ffmpeg-user mailing list