PDA

View Full Version : liveweb.arte.tv, videos.arte.tv: How to download video streams with rtmpdump


Harry_L
03-23-2010, 04:30 AM
Hello,

Currently this video is still broadcast:
http://liveweb.arte.tv/fr/video/Christophe__en_direct_de_la_Cite_de_la_Musique
rtmpdump (http://all-streaming-media.com/record-video-stream/rtmpdump-freeware-console-RTMP-downloading-application.htm) 2.2b gives me:

E:\RtmpDump\rtmpdump_22b>rtmpdump -r "rtmpe://arte.fcod.llnwd.net:1935/a2306/o25
/MP4:liveweb/stream/911_160310_Christophe_hd.mp4" -W "http://liveweb.arte.tv/fla
sh/player.swf?eventId=919&mode=prod&visual=true;jsessionid=281EB203D07FD90C42237
7A7986536E9.tc6l2&isLive=false;jsessionid=281EB203D07FD90C422377A798 6536E9.tc6l2
&lang=fr" -p "http://liveweb.arte.tv/fr/video/Christophe__en_direct_de_la_Cite_d
e_la_Musique/" -V -o output.mp4
RTMPDump v2.2b
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
DEBUG: Protocol : RTMPE
DEBUG: Hostname : arte.fcod.llnwd.net
DEBUG: Port : 1935
DEBUG: Playpath : mp4:MP4:liveweb/stream/911_160310_Christophe_hd
DEBUG: tcUrl : rtmpe://arte.fcod.llnwd.net:1935/a2306/o25
DEBUG: swfUrl : http://liveweb.arte.tv/flash/player.swf?eventId=919&mode=prod&
visual=true;jsessionid=281EB203D07FD90C422377A7986 536E9.tc6l2&isLive=false;jsess
ionid=281EB203D07FD90C422377A7986536E9.tc6l2&lang=fr
DEBUG: pageUrl : http://liveweb.arte.tv/fr/video/Christophe__en_direct_de_la_Ci
te_de_la_Musique/
DEBUG: app : a2306/o25
DEBUG: live : no
DEBUG: timeout : 120 sec
DEBUG: SWFSHA256:
4E 4F 47 BB 50 23 88 16 BE 3F 37 42 9D 49 87 85 07 16 0A 5E 14 F7 E5 7C 62 82 1A
BA 1C 7B 2B 5E
DEBUG: SWFSize : 572503
DEBUG: Setting buffer time to: 36000000ms
Connecting ...
DEBUG: RTMP_Connect1, ... connected, handshaking
DEBUG: HandShake: Client type: 06

DEBUG: HandShake: DH pubkey position: 166
DEBUG: HandShake: Client digest offset: 879
DEBUG: HandShake: Initial client digest:
B8 00 7C FD A5 E5 E8 0C 07 7D 5F D3 4A 5B 99 94 6F DE 5C 96 9A 07 99 BF B0 E0 98
65 44 18 8E 33
DEBUG: HandShake: Type Answer : 08
WARNING: HandShake: Type mismatch: client sent 6, server answered 8
DEBUG: HandShake: Server Uptime : 1006033357
DEBUG: HandShake: FMS Version : 3.5.2.1
DEBUG: HandShake: Server DH public key offset: 89
DEBUG: HandShake: Secret key:
5D 3F 5C 25 46 51 1C 0A AA 4A 43 C1 A8 EC 89 6A 05 83 74 75 9C 93 12 11 5B AA 2B
28 C5 B0 06 79 C5 DF 16 79 B0 AB B9 35 50 4E 47 3C 1F 3C 04 C0 68 EF 81 FE A1 B
F C8 AF 27 A0 18 A7 EE C0 65 76 BA 12 DF D4 79 A5 CE 5C 7A CD 40 8A 5B 5D 6B E6
D6 99 B7 1A 2E 4A 5D 38 3A 22 25 94 91 E3 01 46 B0 00 3A ED F0 7B C7 3C A9 1D 5B
D8 5A BB 35 A7 8A 6E DB E4 7A 4D CF 7B C1 FD C9 AD 48 DA 1B E9
DEBUG: RC4 Out Key:
0A B7 BC 7A F2 68 15 78 E4 71 66 B6 92 76 5F 76
DEBUG: RC4 In Key:
97 B2 8E 73 61 A5 AE ED F6 69 5D A4 B4 E1 29 78
DEBUG: HandShake: Calculated digest key from secure key and server digest:
2C 31 C2 41 4F 66 23 77 14 86 8C B8 47 02 E3 6E 2A 48 F2 EE BF BD C6 15 4E C1 38
E1 C2 6C A0 22
DEBUG: HandShake: Client signature calculated:
80 48 D5 BB 21 67 2E 2A 0A 17 7D CF E1 D8 89 D4 90 EF 12 AB EE E5 A9 86 6E 9F B0
09 0A 06 A6 8D
DEBUG: HandShake: Server sent signature:
AC 86 25 7D 88 E3 B0 AC DE 6A B5 79 96 C1 11 1A DC 09 88 40 DF 0B EF CA C9 73 51
4F 2F 9E 82 54
DEBUG: HandShake: Digest key:
A6 DC A5 7B BB 99 93 25 F7 0B 20 8D 25 98 FD EC 71 A2 A1 44 74 C0 14 1D 2F AD 59
44 AF 9B D7 E0
DEBUG: HandShake: Signature calculated:
AC 86 25 7D 88 E3 B0 AC DE 6A B5 79 96 C1 11 1A DC 09 88 40 DF 0B EF CA C9 73 51
4F 2F 9E 82 54
DEBUG: HandShake: Genuine Adobe Flash Media Server
DEBUG: HandShake: Handshaking finished....
DEBUG: RTMP_Connect1, handshaked
DEBUG: Invoking connect
INFO: Connected...
DEBUG: HandleServerBW: server BW = 2500000
DEBUG: HandleClientBW: client BW = 2500000 2
DEBUG: RTMP_ClientPacket, received: invoke 240 bytes
DEBUG: (object begin)
DEBUG: (object begin)
DEBUG: Property: <Name: fmsVer, STRING: FMS/3,5,3,837>
DEBUG: Property: <Name: capabilities, NUMBER: 127.00>
DEBUG: Property: <Name: mode, NUMBER: 1.00>
DEBUG: (object end)
DEBUG: (object begin)
DEBUG: Property: <Name: level, STRING: status>
DEBUG: Property: <Name: code, STRING: NetConnection.Co
nnect.Success>
DEBUG: Property: <Name: description, STRING: Connection succe
eded.>
DEBUG: Property: <Name: objectEncoding, NUMBER: 0.00>
DEBUG: Property: <Name: data, OBJECT>
DEBUG: (object begin)
DEBUG: Property: <Name: version, STRING: 3,5,3,837>
DEBUG: (object end)
DEBUG: (object end)
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_result>
DEBUG: HandleInvoke, received result for method call <connect>
DEBUG: sending ctrl. type: 0x0003
DEBUG: Invoking createStream
DEBUG: RTMP_ClientPacket, received: invoke 21 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <onBWDone>
DEBUG: Invoking _checkbw
DEBUG: RTMP_ClientPacket, received: invoke 29 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_result>
DEBUG: HandleInvoke, received result for method call <createStream>
DEBUG: SendPlay, seekTime=0.00, dLength=0, sending play: mp4:MP4:liveweb/stream/
911_160310_Christophe_hd
DEBUG: Invoking play
DEBUG: sending ctrl. type: 0x0003
DEBUG: RTMP_ClientPacket, received: invoke 16419 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_onbwcheck>
DEBUG: Invoking _result
DEBUG: RTMP_ClientPacket, received: invoke 32803 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_onbwcheck>
DEBUG: Invoking _result
DEBUG: RTMP_ClientPacket, received: invoke 247 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object begin)
DEBUG: Property: <Name: level, STRING: error>
DEBUG: Property: <Name: code, STRING: NetStream.Play.S
treamNotFound>
DEBUG: Property: <Name: description, STRING: Failed to play M
P4:liveweb/stream/911_160310_Christophe_hd; stream not found.>
DEBUG: Property: <Name: details, STRING: MP4:liveweb/stre
am/911_160310_Christophe_hd>
DEBUG: Property: <Name: clientid, STRING: zK-gsqDS>
DEBUG: (object end)
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <onStatus>
DEBUG: HandleInvoke, onStatus: NetStream.Play.StreamNotFound
ERROR: Closing connection: NetStream.Play.StreamNotFound
DEBUG: Closing connection.
GetFLV (http://all-streaming-media.com/record-video-stream/GetFLV-Download-and-convert-flash-video-streaming.htm) and StreamTransport (http://all-streaming-media.com/record-video-stream/StreamTransport-Download-HTTP-RTMP-RTMPE-streams.htm) are ineffective.
Have you an idea of the problem?

Thank you.

Stream Recorder
03-23-2010, 05:15 AM
I used Replay Media Catcher (http://all-streaming-media.com/record-video-stream/Replay-Media-Catcher-HTTP-RTMP-FLV-MP3-ripper-recorder.htm) and it downloaded an RTMP stream from the URL provided. It didn't require SWF verification.

Also see the following thread:
anyway to save arte.tv video ? (i cant download from french tv website on Mac OS X)
It offers solutions for Mac OS X as well as Linux and Windows.

noob2001204
03-23-2010, 06:31 AM
The line works fine

rtmpdump -r rtmpe://arte.fcod.llnwd.net:1935/a2306/o25/mp4:liveweb/stream/911_160310_Christophe_hd.mp4 -o video.mp4


Note the "mp4" in your log is uppercase,so it returns an error

Harry_L
03-23-2010, 06:51 AM
I used Replay Media Catcher (http://all-streaming-media.com/record-video-stream/Replay-Media-Catcher-HTTP-RTMP-FLV-MP3-ripper-recorder.htm) and it downloaded an RTMP stream from the URL provided. It didn't require SWF verification...
Perfect with Replay Media Catcher (http://all-streaming-media.com/record-video-stream/Replay-Media-Catcher-HTTP-RTMP-FLV-MP3-ripper-recorder.htm)!
Thank you.
The line works fine

rtmpdump -r rtmpe://arte.fcod.llnwd.net:1935/a2306/o25/mp4:liveweb/stream/911_160310_Christophe_hd.mp4 -o video.mp4


Note the "mp4" in your log is uppercase,so it returns an error
Good view!
Thank you.

elch
04-11-2010, 09:12 AM
I've written a small script for downloading from arte live web:

#!/usr/bin/php
<?php

if (!isset($_SERVER['argv'][1])) {
die();
}

if (is_numeric($_SERVER['argv'][1])) {
$eventId = $_SERVER['argv'][1];
} else {
$contents = file_get_contents($_SERVER['argv'][1]);

preg_match('/eventId=(.*)\&mode/', $contents, $matches);
$eventId = $matches[1];
}

$contents = file_get_contents("http://arte.vo.llnwd.net/o21/liveweb/events/event-$eventId.xml");

preg_match('/<urlHd>rtmp:\/\/(.*)net\/(.*)\/MP4:(.*)<\/urlHd>/', $contents, $matches);

if (isset($matches[3])) {
$host = $matches[1] . 'net';
$app = $matches[2];
$path = 'MP4:' . $matches[3];
$file = basename($path);
$live = '';
} else {
preg_match('/<liveUrl>rtmp:\/\/(.*)\/(.*)\/(.*)<\/liveUrl>/', $contents, $matches);
$host = $matches[1];
$app = $matches[2];
$path = $matches[3];
$file = basename($path) . '.mp4';
$live = '--live';
}

preg_match_all('/<nameFr>(.*)<\/nameFr>/', $contents, $matches);
$category = htmlspecialchars_decode($matches[1][1]);
$title = htmlspecialchars_decode($matches[1][2]);

preg_match('/<urlFr>(.*)<\/urlFr>/', $contents, $matches);
$source = $matches[1];

echo "echo \"category: $category\n";
echo "title: $title\n";
echo "source: $source\" > $file.meta\n";

echo "\n";

echo "rtmpdump --host $host --app $app --playpath $path $live --flv $file\n";

Use it like this:
php arte http://liveweb.arte.tv/fr/video/One_Shot_Not___Sting/

Then it generates two commands. The first one is for creating a meta file (might come in handy when you want some information about a particular recording and it isn't available over the arte site anymore). The second one is just for calling rtmpdump (http://all-streaming-media.com/record-video-stream/rtmpdump-freeware-console-RTMP-downloading-application.htm), i.e. downloading the file.

mx035
06-13-2010, 08:15 AM
How would you do the same thing for the video page, http://videos.arte.tv/fr/videos/arte7#/fr/thumb///1/50/?

smemorando
07-16-2010, 03:02 AM
Could someone please explain me how to do it exactly?
Thanks :)

febo
03-05-2011, 02:33 AM
If you're interested...

http://delendanet.blogspot.com/2011/03/artepupper-01.html
http://www.delenda.net/artepupper/artepupper01.zip

artepupper.exe 0- a simple windows forms interface to rtmpdump (http://all-streaming-media.com/record-video-stream/rtmpdump-freeware-console-RTMP-downloading-application.htm) for arte

Rocky37
06-22-2011, 07:02 AM
If you're interested...

http://delendanet.blogspot.com/2011/03/artepupper-01.html
http://www.delenda.net/artepupper/artepupper01.zip

artepupper.exe 0- a simple windows forms interface to rtmpdump (http://all-streaming-media.com/record-video-stream/rtmpdump-freeware-console-RTMP-downloading-application.htm) for arte

Thank you!!! Merci Beaucoup!!!!

laconcombremasque
08-13-2011, 11:53 AM
@ elch
Thank you so much for the php script.
As of today, it is still working very well. And allows also to download some videos that are not playable anymore from the website ; your script allows RTMPdump (http://all-streaming-media.com/record-video-stream/rtmpdump-freeware-console-RTMP-downloading-application.htm) to fetch them anyway! That's brilliant.

Just for you to know -although I didn't use this feature yet- the first output from your script (the metadata) is false, there must have been a change from arte's servers. The correct files are downloaded, only the metadata.meta given before the rtmpdump command are wrong.
Don't change anything else!
All the best,
L

rudid
09-07-2011, 04:32 AM
Hello,

having a problem with RTMPdump (http://all-streaming-media.com/record-video-stream/rtmpdump-freeware-console-RTMP-downloading-application.htm) and arte.tv - when using the binary in OSX 10.7, video is downloaded properly, doing the same in Ubuntu 10.04 LTS, downloading fails with 'ERROR: Closing connection: NetStream.Failed'

Anyone experiences same behavior?

Following command is issued on both platforms:

rtmpdump -r rtmp://artestras.fcod.llnwd.net/a3903/o35/mp4:geo/videothek/EUR_DE_FR/arteprod/A7_SGT_ENC_04_043825-001-A_PG_HQ_DE?h=857c2959559ca881e46ead494d349018 --swfhash 19153dcc7c475c77cc612f11cfd149e26fea5ab033887d0a35 38a6be9626e0a8 --swfsize 860725 -o test.flv -V -s http://videos.arte.tv/blob/web/i18n/view/player_18-3188338-data-4870353.swf

Result is:

RTMPDump v2.4-ppa2~lucid
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
DEBUG: Protocol : RTMP
DEBUG: Hostname : artestras.fcod.llnwd.net
DEBUG: Port : 1935
DEBUG: Playpath : mp4:geo/videothek/EUR_DE_FR/arteprod/A7_SGT_ENC_04_043825-001-A_PG_HQ_DE?h=857c2959559ca881e46ead494d349018
DEBUG: tcUrl : rtmp://artestras.fcod.llnwd.net:1935/a3903/o35
DEBUG: swfUrl : http://videos.arte.tv/blob/web/i18n/view/player_18-3188338-data-4870353.swf
DEBUG: app : a3903/o35
DEBUG: live : no
DEBUG: timeout : 30 sec
DEBUG: SWFSHA256:
DEBUG: 19 15 3d cc 7c 47 5c 77 cc 61 2f 11 cf d1 49 e2
DEBUG: 6f ea 5a b0 33 88 7d 0a 35 38 a6 be 96 26 e0 a8
DEBUG: SWFSize : 860725
DEBUG: Setting buffer time to: 36000000ms
Connecting ...
DEBUG: RTMP_Connect1, ... connected, handshaking
DEBUG: HandShake: Client type: 03
DEBUG: HandShake: Client digest offset: 430
DEBUG: HandShake: Initial client digest:
DEBUG: b6 06 a5 ee cc 29 b4 29 fe 30 96 7b 0f cb 40 9a
DEBUG: 61 84 36 c7 2b d3 3f ed ff 93 c1 02 44 86 cc ef
DEBUG: HandShake: Type Answer : 03
DEBUG: HandShake: Server Uptime : 960736140
DEBUG: HandShake: FMS Version : 4.0.2.1
DEBUG: HandShake: Calculated digest key from secure key and server digest:
DEBUG: 25 41 93 26 77 3c ca c3 cb 33 93 47 18 00 48 d1
DEBUG: 10 d1 22 37 4a 15 93 9e 5e ae 7c 49 2e 22 4f 6a
DEBUG: HandShake: Client signature calculated:
DEBUG: 67 cf 77 40 cf 9f 4f 6e 52 c1 ab 2c 1e 61 98 19
DEBUG: 94 de 9c 75 3b 7d 13 fa 3a 7b 4f a9 47 59 34 92
DEBUG: HandShake: Server sent signature:
DEBUG: 41 55 52 4c 5d ba 0b e5 02 74 8d 5a 2d c2 7f 17
DEBUG: f9 d2 87 28 9b b1 11 ea 7f 3b 0f cb 52 95 8c 03
DEBUG: HandShake: Digest key:
DEBUG: 79 e6 d8 b5 c9 ff c9 a3 b8 f8 29 46 fc 26 4b 19
DEBUG: 3f d3 03 af 7e 33 58 e5 9f 91 df 86 6f c7 cf 04
DEBUG: HandShake: Signature calculated:
DEBUG: 41 55 52 4c 5d ba 0b e5 02 74 8d 5a 2d c2 7f 17
DEBUG: f9 d2 87 28 9b b1 11 ea 7f 3b 0f cb 52 95 8c 03
DEBUG: HandShake: Genuine Adobe Flash Media Server
DEBUG: HandShake: Handshaking finished....
DEBUG: RTMP_Connect1, handshaked
DEBUG: Invoking connect
INFO: Connected...
DEBUG: HandleServerBW: server BW = 2500000
DEBUG: HandleClientBW: client BW = 2500000 2
DEBUG: HandleChangeChunkSize, received: chunk size change to 4096
DEBUG: HandleCtrl, received ctrl. type: 26, len: 3
DEBUG: HandleCtrl, SWFVerification ping received:
DEBUG: sending ctrl. type: 0x001b
DEBUG: Sending SWFVerification response:
DEBUG: 00 1b 01 01 00 0d 22 35 00 0d 22 35 2f a9 cf 1a
DEBUG: b3 58 70 29 59 64 2d ae 99 44 2c 67 8c 10 60 6a
DEBUG: d6 b0 45 93 76 e0 3a 02 26 57 dd c1
DEBUG: RTMP_ClientPacket, received: invoke 242 bytes
DEBUG: (object begin)
DEBUG: (object begin)
DEBUG: Property: <Name: fmsVer, STRING: FMS/4,0,2,3029>
DEBUG: Property: <Name: capabilities, NUMBER: 255.00>
DEBUG: Property: <Name: mode, NUMBER: 1.00>
DEBUG: (object end)
DEBUG: (object begin)
DEBUG: Property: <Name: level, STRING: status>
DEBUG: Property: <Name: code, STRING: NetConnection.Connect.Success>
DEBUG: Property: <Name: description, STRING: Connection succeeded.>
DEBUG: Property: <Name: objectEncoding, NUMBER: 0.00>
DEBUG: Property: <Name: data, OBJECT>
DEBUG: (object begin)
DEBUG: Property: <Name: version, STRING: 4,0,2,3029>
DEBUG: (object end)
DEBUG: (object end)
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_result>
DEBUG: HandleInvoke, received result for method call <connect>
DEBUG: sending ctrl. type: 0x0003
DEBUG: Invoking createStream
DEBUG: RTMP_ClientPacket, received: invoke 21 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <onBWDone>
DEBUG: Invoking _checkbw
DEBUG: RTMP_ClientPacket, received: invoke 29 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_result>
DEBUG: HandleInvoke, received result for method call <createStream>
DEBUG: SendPlay, seekTime=0, stopTime=0, sending play: mp4:geo/videothek/EUR_DE_FR/arteprod/A7_SGT_ENC_04_043825-001-A_PG_HQ_DE?h=857c2959559ca881e46ead494d349018
DEBUG: Invoking play
DEBUG: sending ctrl. type: 0x0003
DEBUG: RTMP_ClientPacket, received: invoke 16419 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_onbwcheck>
DEBUG: Invoking _result
DEBUG: HandleChangeChunkSize, received: chunk size change to 4096
DEBUG: RTMP_ClientPacket, received: invoke 133 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object begin)
DEBUG: Property: <Name: level, STRING: error>
DEBUG: Property: <Name: code, STRING: NetStream.Failed>
DEBUG: Property: <Name: description, STRING: Failed to play (stream ID: 1).>
DEBUG: Property: <Name: clientid, STRING: pAAQQOEA>
DEBUG: (object end)
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <onStatus>
DEBUG: HandleInvoke, onStatus: NetStream.Failed
ERROR: Closing connection: NetStream.Failed
DEBUG: Closing connection.