Anyone know how to enable cookie interaction in ffmpeg? I have an HLS stream who need save cookies from the server , but actually that doesn't happen.
Asked
Active
Viewed 1.8k times
2 Answers
17
You can send headers with FFmpeg
Linux
ffmpeg -i INPUT -headers $'Cookie: logged_in=yes; tracker=direct\r\n'
Windows
powershell ffmpeg -i INPUT -headers "Cookie: logged_in=yes; tracker=direct`r`n"

Zombo
- 1
- 62
- 391
- 407
-
ok, I was reading about that but I want the posibility to save cookies between playlist calls. Actually my server need the cookies saved to calculate the next playlist m3u8 – Rodrigo Amaro Reveco Apr 22 '13 at 22:44
-
The provided link leads to a 404. – Akito Aug 14 '22 at 19:52
-
1@Akito, I found similar script https://github.com/als888/a/blob/master/scripts/ff-cookie.sh but you have to replace `ffplay` with `ffmpeg` – Maxim Suslov Jan 24 '23 at 09:47
-1
There's no cookie support in ffmpeg. You'll need to implement that part on your own or perhaps use mplayer which supports cookies.

vipw
- 7,593
- 4
- 25
- 48