freearhey / iptv-checker

Node.js CLI tool for checking links in IPTV playlists

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Side-Effect: Overriding the default ffprobe User-Agent header

detroitenglish opened this issue · comments

When not defined as an option, the current command passed to ffprobe overrides ffprobe's default User-Agent header (with User-Agent: "undefined", I believe).

According to the ffprobe docs on the -user_agent option:

If not specified the protocol will use a [User-Agent header] string describing the libavformat build. ("Lavf/")

Overriding the standard UA-header by default could result in false-negatives from stream providers that sniff (or worse, whitelist) the User-Agent of incoming connections.

PR inbound...

Side Notes:

  • The -show_error and -show_format options aren't necessary, since stream connectivity is all that matters in this case.
  • SECURITY: User-defined --user-agent strings should be wrapped in single-quotes to combat shell injection attacks.