I need to pass http headers (user agent and ip) to an ffmpeg command.
I use the following command:
ffmpeg -y -timeout 5000000 -map 0:0 -an -sn -f md5 -
Well, ffmpeg manual says to split multiple http-headers by CRLF. The problem is that you overwrite your first "-header" argument with the second "-header" as there can be only one "-header" argument.
For your example, you need to join User-Agent
and X-Forwarded
into one argument by valid CRLF like this:
-header "User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.80 Safari/537.36"$'\r\n'"X-Forwarded-For: 13.14.15.66"$'\r\n'