[FFmpeg-user] How to pass cookies to ffmpeg to download aes-128 protected .ts?

Renato Santos renato.cron at gmail.com
Wed Mar 5 11:38:20 CET 2014


Can't you use curl and pass it using pipe?




On Tue, Mar 4, 2014 at 5:43 AM, Han Jiang <oglops at gmail.com> wrote:

> hi all , i've been using ffmpeg for a while with this syntax :
>
> ffmpeg -i "http://x:1935/vod/yyyy" -c copy -absf aac_adtstoasc  out.mp4
>
> but suddenly from today, i found that when i ran it, the following error
> occurs
>
> [tls @ 0000000000305a40] Error in the push function.
> Unable to open key file https://xxxxx/yyyy.php?wowzasessionid=222333444
> [hls,applehttp @ 0000000002c986a0] Error when loading first segment '
> http://xxx:1935/vod/yyy.mp4/media_w222333444_0.ts'
> http://xxx:1935/vod/yyy.mp4: Invalid data found when processing input
>
> how ever i still managed to get the m3u8 file
>
> #EXTM3U
> #EXT-X-VERSION:3
> #EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=673937,CODECS="avc1.66.13,
> mp4a.40.2",RESOLUTION=1024x576
> chunklist_222333444.m3u8
>
> then of course i can get hold of the chunklist_222333444.m3u8 file
>
> #EXTM3U
> #EXT-X-VERSION:3
> #EXT-X-TARGETDURATION:11
> #EXT-X-MEDIA-SEQUENCE:0
> #EXT-X-KEY:METHOD=AES-128,URI="
> https://xxx/yyyy.php?wowzasessionid=222333444
> "
> #EXTINF:10.333,
> media_w222333444_0.ts
> #EXTINF:9.917,
> media_w222333444_1.ts
> #EXTINF:9.917,
> ...
>
> in this case how do i use ffmpeg to download the stream ?
>
> i have account on this website, how to tell it i have the key ?
> like this ?
>
> ffmpeg -y -cookies "Cookie:  name=value; name1=value1; \r\n" -i "
> http://xxx:1935/vod/xxx/mp4:xxx.mp4/playlist.m3u8" -c copy -absf
> aac_adtstoasc - o out.mp4
>
> tried but does not work, still same error:
> Unable to open key file
> https://cmivfx.com/myStream.php?wowzasessionid=123456xx
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>



-- 
Saravá,
Renato CRON
http://www.renatocron.com/blog/
@renato_cron <http://twitter.com/#!/renato_cron>


More information about the ffmpeg-user mailing list