GosuSan
01-16-2016, 09:38 AM
Hey everyone,
I am new to this recording Stuff, but I spent quite some time working and learning Linux Stuff (wich is now my main OS).
I recently found a site where I can watch eurosport (or eurosport 2) online:
http://cricfree.sx/euro-sports-2-live-stream
So, there is an iframe where the actual stream is embedded, wich is always nice (less code -> less errors):
http://cricfree.sx/update/euro2.php
First approach was with wireshark but that didn't work out at all (can go into detail, but that might get pretty much text and boring).
So I read the rtmpdump-docs and some posts here in the forum and tried this next:
# Stream is not started, no other tabs open in chrome #
$ sudo iptables -t nat -A OUTPUT -p tcp --dport 1935 -j REDIRECT
$ rtmpsrv
# Start the stream #
RTMP Server v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu; license: GPL
Streaming on rtmp://0.0.0.0:1935
WARNING: Trying different position for client digest!
rtmpdump -r "rtmp://31.220.2.148/redirect/" -a "redirect/" -f "LNX 17,0,0,188" -W "http://p.jwpcdn.com/6/12/jwplayer.flash.swf" -p "http://yotv.co/embedo.php?live=eu2&vw=620&vh=490" -y "eu2" -o eu2.flv
Closing connection... done!
RTMPDump v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
Connecting ...
INFO: Connected...
Duplicate request, skipping.
Closing connection... done!
Caught signal: 13, cleaning up, just a second...
ERROR: WriteN, RTMP send error 32 (42 bytes)
ERROR: RTMP_ReadPacket, failed to read RTMP packet header
Okay, connected, but can't capture the stream. But I got my rtmpdump-command, wich is if I understand that correct, the main purpose of rtmpsrv.
So I removed the iptables rule:
$ sudo iptables -t nat -D OUTPUT -p tcp --dport 1935 -j REDIRECT
# stopped the stream in the browser - closed browser #
tried the command that rtmpsrv gave me (plus the -V switch because it didn't work last time):
$ rtmpdump -r "rtmp://31.220.2.148/redirect/" -a "redirect/" -f "LNX 17,0,0,188" -W "http://p.jwpcdn.com/6/12/jwplayer.flash.swf" -p "http://yotv.co/embedo.php?live=eu2&vw=620&vh=490" -y "eu2" -o eu2.flv -V
RTMPDump v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
DEBUG: Protocol : RTMP
DEBUG: Hostname : 31.220.2.148
DEBUG: Port : 1935
DEBUG: Playpath : eu2
DEBUG: tcUrl : rtmp://31.220.2.148:1935/redirect/
DEBUG: swfUrl : http://p.jwpcdn.com/6/12/jwplayer.flash.swf
DEBUG: pageUrl : http://yotv.co/embedo.php?live=eu2&vw=620&vh=490
DEBUG: app : redirect/
DEBUG: flashVer : LNX 17,0,0,188
DEBUG: live : no
DEBUG: timeout : 30 sec
DEBUG: SWFSHA256:
DEBUG: b3 59 92 56 0e ae 15 22 60 d0 ff 65 76 ec d3 98
DEBUG: 58 4f 3a f2 46 ad bd a7 c6 8a a4 41 6e 9b cf 7d
DEBUG: SWFSize : 404302
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: a6 73 ae 53 1f c6 6f 8f 22 78 fa 50 bd cc d0 47
DEBUG: 67 69 8d b1 d0 2c cb 6c aa 9c fa 1b d1 82 71 13
DEBUG: HandShake: Type Answer : 03
DEBUG: HandShake: Server Uptime : 96850052
DEBUG: HandShake: FMS Version : 3.0.1.1
DEBUG: HandShake: Calculated digest key from secure key and server digest:
DEBUG: 9e ed a0 e9 fc b3 3f d8 7e 08 1f 41 80 75 a1 bb
DEBUG: a5 5c ec c1 5f 4c 3d f0 27 7f 69 ae b0 f9 45 47
DEBUG: HandShake: Client signature calculated:
DEBUG: 80 bb f6 1c d1 ae 47 08 bd 0c d2 61 e3 28 bb 51
DEBUG: b0 e6 43 fd 0e 1e 21 93 27 80 78 65 ed 8e 53 86
DEBUG: HandShake: Server sent signature:
DEBUG: bb 7e c8 53 9b ba 77 7e 84 4c f8 f5 40 b3 a0 e1
DEBUG: c0 89 15 ca 13 97 d7 4d 65 18 c0 e1 72 6c 97 50
DEBUG: HandShake: Digest key:
DEBUG: 49 67 83 c1 cc 78 4f b1 71 03 b9 d4 00 51 aa ae
DEBUG: a0 05 56 a5 d7 54 a5 12 1b fb 0e 9a a6 35 bf 18
DEBUG: HandShake: Signature calculated:
DEBUG: bb 7e c8 53 9b ba 77 7e 84 4c f8 f5 40 b3 a0 e1
DEBUG: c0 89 15 ca 13 97 d7 4d 65 18 c0 e1 72 6c 97 50
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: HandleCtrl, received ctrl. type: 0, len: 6
DEBUG: HandleCtrl, Stream Begin 0
DEBUG: HandleChangeChunkSize, received: chunk size change to 4096
DEBUG: RTMP_ClientPacket, received: invoke 315 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object begin)
DEBUG: Property: <Name: level, STRING: error>
DEBUG: Property: <Name: code, STRING: NetConnection.Connect.Rejected>
DEBUG: Property: <Name: description, STRING: Connection failed: Application rejected connection.>
DEBUG: Property: <Name: ex, OBJECT>
DEBUG: (object begin)
DEBUG: Property: <Name: redirect, STRING: rtmp://185.63.255.18:80/live>
DEBUG: Property: <Name: code, NUMBER: 302.00>
DEBUG: (object end)
DEBUG: Property: <Name: clientid, NUMBER: 1131397378.00>
DEBUG: Property: <Name: secureToken, STRING: 17f1764c24537b99899ee23d86372705deb7eefd85e91feb8a 29f6a072f4c43a3b84d26d>
DEBUG: (object end)
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_error>
ERROR: rtmp server sent error
DEBUG: RTMP_ClientPacket, received: invoke 18 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <close>
ERROR: rtmp server requested close
DEBUG: Closing connection.
Well, that errors does not tell me anything ...
So, I tried rtmpsrv, rtmpdump, time for rtmpsuck i guess ...
Created a user called "proxy" as suggested in the rtmpdump docs, and changed the iptable rule to
$ iptables -t nat -A OUTPUT -p tcp --dport 1935 -m owner \! --uid-owner proxy -j REDIRECT
$ su proxy
$ rtmpsuck
# start the stream in my browser #
RTMP Proxy Server v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu; license: GPL
Streaming on rtmp://0.0.0.0:1935
WARNING: Trying different position for client digest!
Processing connect
app: redirect/
flashVer: LNX 17,0,0,188
swfUrl: http://p.jwpcdn.com/6/12/jwplayer.flash.swf
tcUrl: rtmp://31.220.2.148/redirect/
pageUrl: http://yotv.co/embedo.php?live=eu2&vw=620&vh=490
ERROR: WriteN, RTMP send error 9 (16 bytes)
ERROR: RTMP_ReadPacket, failed to read RTMP packet header
Closing connection... done!
$ iptables -t nat -D OUTPUT -p tcp --dport 1935 -m owner \! --uid-owner proxy -j REDIRECT
Now I am out of ideas and here to ask for help :)
If you need any more information, let me know.
And Thanks in advance!
I am new to this recording Stuff, but I spent quite some time working and learning Linux Stuff (wich is now my main OS).
I recently found a site where I can watch eurosport (or eurosport 2) online:
http://cricfree.sx/euro-sports-2-live-stream
So, there is an iframe where the actual stream is embedded, wich is always nice (less code -> less errors):
http://cricfree.sx/update/euro2.php
First approach was with wireshark but that didn't work out at all (can go into detail, but that might get pretty much text and boring).
So I read the rtmpdump-docs and some posts here in the forum and tried this next:
# Stream is not started, no other tabs open in chrome #
$ sudo iptables -t nat -A OUTPUT -p tcp --dport 1935 -j REDIRECT
$ rtmpsrv
# Start the stream #
RTMP Server v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu; license: GPL
Streaming on rtmp://0.0.0.0:1935
WARNING: Trying different position for client digest!
rtmpdump -r "rtmp://31.220.2.148/redirect/" -a "redirect/" -f "LNX 17,0,0,188" -W "http://p.jwpcdn.com/6/12/jwplayer.flash.swf" -p "http://yotv.co/embedo.php?live=eu2&vw=620&vh=490" -y "eu2" -o eu2.flv
Closing connection... done!
RTMPDump v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
Connecting ...
INFO: Connected...
Duplicate request, skipping.
Closing connection... done!
Caught signal: 13, cleaning up, just a second...
ERROR: WriteN, RTMP send error 32 (42 bytes)
ERROR: RTMP_ReadPacket, failed to read RTMP packet header
Okay, connected, but can't capture the stream. But I got my rtmpdump-command, wich is if I understand that correct, the main purpose of rtmpsrv.
So I removed the iptables rule:
$ sudo iptables -t nat -D OUTPUT -p tcp --dport 1935 -j REDIRECT
# stopped the stream in the browser - closed browser #
tried the command that rtmpsrv gave me (plus the -V switch because it didn't work last time):
$ rtmpdump -r "rtmp://31.220.2.148/redirect/" -a "redirect/" -f "LNX 17,0,0,188" -W "http://p.jwpcdn.com/6/12/jwplayer.flash.swf" -p "http://yotv.co/embedo.php?live=eu2&vw=620&vh=490" -y "eu2" -o eu2.flv -V
RTMPDump v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
DEBUG: Protocol : RTMP
DEBUG: Hostname : 31.220.2.148
DEBUG: Port : 1935
DEBUG: Playpath : eu2
DEBUG: tcUrl : rtmp://31.220.2.148:1935/redirect/
DEBUG: swfUrl : http://p.jwpcdn.com/6/12/jwplayer.flash.swf
DEBUG: pageUrl : http://yotv.co/embedo.php?live=eu2&vw=620&vh=490
DEBUG: app : redirect/
DEBUG: flashVer : LNX 17,0,0,188
DEBUG: live : no
DEBUG: timeout : 30 sec
DEBUG: SWFSHA256:
DEBUG: b3 59 92 56 0e ae 15 22 60 d0 ff 65 76 ec d3 98
DEBUG: 58 4f 3a f2 46 ad bd a7 c6 8a a4 41 6e 9b cf 7d
DEBUG: SWFSize : 404302
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: a6 73 ae 53 1f c6 6f 8f 22 78 fa 50 bd cc d0 47
DEBUG: 67 69 8d b1 d0 2c cb 6c aa 9c fa 1b d1 82 71 13
DEBUG: HandShake: Type Answer : 03
DEBUG: HandShake: Server Uptime : 96850052
DEBUG: HandShake: FMS Version : 3.0.1.1
DEBUG: HandShake: Calculated digest key from secure key and server digest:
DEBUG: 9e ed a0 e9 fc b3 3f d8 7e 08 1f 41 80 75 a1 bb
DEBUG: a5 5c ec c1 5f 4c 3d f0 27 7f 69 ae b0 f9 45 47
DEBUG: HandShake: Client signature calculated:
DEBUG: 80 bb f6 1c d1 ae 47 08 bd 0c d2 61 e3 28 bb 51
DEBUG: b0 e6 43 fd 0e 1e 21 93 27 80 78 65 ed 8e 53 86
DEBUG: HandShake: Server sent signature:
DEBUG: bb 7e c8 53 9b ba 77 7e 84 4c f8 f5 40 b3 a0 e1
DEBUG: c0 89 15 ca 13 97 d7 4d 65 18 c0 e1 72 6c 97 50
DEBUG: HandShake: Digest key:
DEBUG: 49 67 83 c1 cc 78 4f b1 71 03 b9 d4 00 51 aa ae
DEBUG: a0 05 56 a5 d7 54 a5 12 1b fb 0e 9a a6 35 bf 18
DEBUG: HandShake: Signature calculated:
DEBUG: bb 7e c8 53 9b ba 77 7e 84 4c f8 f5 40 b3 a0 e1
DEBUG: c0 89 15 ca 13 97 d7 4d 65 18 c0 e1 72 6c 97 50
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: HandleCtrl, received ctrl. type: 0, len: 6
DEBUG: HandleCtrl, Stream Begin 0
DEBUG: HandleChangeChunkSize, received: chunk size change to 4096
DEBUG: RTMP_ClientPacket, received: invoke 315 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object begin)
DEBUG: Property: <Name: level, STRING: error>
DEBUG: Property: <Name: code, STRING: NetConnection.Connect.Rejected>
DEBUG: Property: <Name: description, STRING: Connection failed: Application rejected connection.>
DEBUG: Property: <Name: ex, OBJECT>
DEBUG: (object begin)
DEBUG: Property: <Name: redirect, STRING: rtmp://185.63.255.18:80/live>
DEBUG: Property: <Name: code, NUMBER: 302.00>
DEBUG: (object end)
DEBUG: Property: <Name: clientid, NUMBER: 1131397378.00>
DEBUG: Property: <Name: secureToken, STRING: 17f1764c24537b99899ee23d86372705deb7eefd85e91feb8a 29f6a072f4c43a3b84d26d>
DEBUG: (object end)
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <_error>
ERROR: rtmp server sent error
DEBUG: RTMP_ClientPacket, received: invoke 18 bytes
DEBUG: (object begin)
DEBUG: Property: NULL
DEBUG: (object end)
DEBUG: HandleInvoke, server invoking <close>
ERROR: rtmp server requested close
DEBUG: Closing connection.
Well, that errors does not tell me anything ...
So, I tried rtmpsrv, rtmpdump, time for rtmpsuck i guess ...
Created a user called "proxy" as suggested in the rtmpdump docs, and changed the iptable rule to
$ iptables -t nat -A OUTPUT -p tcp --dport 1935 -m owner \! --uid-owner proxy -j REDIRECT
$ su proxy
$ rtmpsuck
# start the stream in my browser #
RTMP Proxy Server v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu; license: GPL
Streaming on rtmp://0.0.0.0:1935
WARNING: Trying different position for client digest!
Processing connect
app: redirect/
flashVer: LNX 17,0,0,188
swfUrl: http://p.jwpcdn.com/6/12/jwplayer.flash.swf
tcUrl: rtmp://31.220.2.148/redirect/
pageUrl: http://yotv.co/embedo.php?live=eu2&vw=620&vh=490
ERROR: WriteN, RTMP send error 9 (16 bytes)
ERROR: RTMP_ReadPacket, failed to read RTMP packet header
Closing connection... done!
$ iptables -t nat -D OUTPUT -p tcp --dport 1935 -m owner \! --uid-owner proxy -j REDIRECT
Now I am out of ideas and here to ask for help :)
If you need any more information, let me know.
And Thanks in advance!