Skip to content

anevia lua scripts probe implementations are too relaxed

Many of the lua modules responsible for playlist parsing has far too relaxed rules for being applicable, as an example opening the below URI would invoke the soundcloud playlist parser:

  • http://localhost/soundcloud.com/a/b

testcase

% mkdir -p /srv/http/soundcloud.com/a
% touch !$/b
% vlc-trunk http://localhost/soundcloud.com/a/b
VLC media player 3.0.0-git Vetinari (revision 2.2.0-git-9100-g7f7c05b)
[0000000001dc1498] core libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface.
[00007f6490002a78] es demux error: cannot peek
[00007f6490002a78] es demux error: cannot peek
[00007f6490002a78] es demux error: cannot peek
[00007f6490002a78] es demux error: cannot peek
[00007f6490002a78] es demux error: cannot peek
[00007f6490002a78] ps demux error: cannot peek
[00007f6490002a78] mpgv demux error: cannot peek
[00007f6490002a78] mjpeg demux error: cannot peek
[00007f6490002a78] lua demux error: Couldn't extract soundcloud audio URL, please check for updates to this script

Please note that the above does not result in an error diagnostic saying that we cannot handle the input, instead we "only" get an error diagnostic from the responsible demux (that is used even though it is not applicable).

further information

See the (incomplete) list below for examples of probe-implementations that are too relaxed:

Pretty much every implementation of probe under share/lua/playlist/* is too relaxed, though there are certainly some implementations that should be removed all together (because they do not reflect the current state of the remote APIs which they are meant to work with).

Edited by Pierre Ynard
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information