Audio/video stream recording forums

Attention Visitor:
You may have to register or log in before you can post:
  • Click the register link to sign up.
  • Registered members please fill in the form below and click the "Log in" button.
To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Audio/video stream recording forums > Streaming media recording forum > Video stream recording
Register FAQ Members List Calendar Mark Forums Read

Reply Post New Thread
 
Thread Tools Display Modes
  #1  
Old 05-12-2015, 04:55 PM
beerfoot beerfoot is offline
Linux *****
 
Join Date: May 2015
Posts: 6
beerfoot is on a distinguished road
Default

Catch and forward streams TUTORIAL => $50 reward


Hi,

I've spent days trying to find a simple tutorial on how to catch rtmp streams, with fresh and updated contents/tools. I couldn't find a recent step by step tutorial for newbies with a great summary. I'm trying another method right here, stream-recorder and its great community are my last hope to get a relevant tutorial

I offer a $50 Amazon gift card for anyone providing a small tutorial with the following:

1. how to identify the rtmp stream address/port/parameters from mips.tv, ucaster.eu? ex: regarder(.)me/splus/streamer.php?id=sebastien2
a. which tools do you use? Wireshark, other
b. the good rtmpdump command to catch the stream
c. how to redirect the rtmp stream to my own rtmp server (forward)

2. how to catch a stream from a TV channel?
a. the best tools for catching the raw stream on Linux
b. how to forward the caught stream to my own rtmp server

3. what kind of server / hosting would you advise to broadcast the rtmp streams to ~100K visitors during 2-3 hours ?

I have good skills in Linux admin but I'm a newbie to stream recording

Why do I offer a gift card? Because I've been reading hundreds of pages and I still can't find a relevant "for dummies" tutorial. People spending their time helping writing such contents deserve to be rewarded.

Feel free to send a message before you start, I will tell you if anyone else has already started writing the tutorial. Of course, the tutorial can be written down here as a post answer available for everybody if admins wish to

Thanks,
Tom

Last edited by beerfoot : 05-12-2015 at 04:56 PM. Reason: avoid link for stream example
Reply With Quote
  #2  
Old 05-12-2015, 08:18 PM
biezom biezom is offline
Senior Member
 
Join Date: Sep 2014
Posts: 1,025
biezom is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


hi
you can use
ngrep with libap (it works too on windows)
this example is for janjua.tv (your example doesn't work when i wrote this post)
it works like mips.tv .....
1) in administrator terminal
Code:
ngrep  play -d wlan0 >janjua.txt
with wlan0 is interface connected maybe eth0.....

2)
load the page
http://www.cloud-tivu.net/Blog/dmax-...eaming-estero/

3) when the video start stop ngrep with Ctrl +C

4) read janjua.txt with gedit you have something like this
Code:
.connect.?..........app...live..flashVer...L
  NX 17,0,0,134..swfUrl..9http://www.janjuaplayer.com/resources/scripts/eplay
  er.swf...tcUrl...rtmp://5.63.150.84/live..fpad....capabilities.@m........au
  dioCodecs.@.........videoCodecs.@o........videoFunction.?..........pageUrl.
  .8http://www.janjuaplayer.com/embedplayer/Dmaxg3/3/500/380..objectEncoding.
  @.............OK                                                          
##############################################################################################
 [AP]
  ......q.........play............SDmaxg3?id=37815&pk=408c1ca8856f67aed24ad4d
  966227ee07b26f67a8d6807c8e45c78ec55cdc9e6..

5)you have all that you want to use rtmpdump
Code:
rtmpdump -r "rtmp://37.130.227.172/live"  -W "http://www.janjuaplayer.com/resources/scripts/eplayer.swf" -p "http://www.janjuaplayer.com/embedplayer/Dmaxg3/3/500/380" -y "Dmaxg3?id=37815&pk=408c1ca8856f67aed24ad4d966227ee07b26f67a8d6807c8e45c78ec55cdc9e6" -C S:OK -o Dmaxg3.flv
Code:
rtmpdump -r "rtmp://37.130.227.172/live" -W "http://www.janjuaplayer.com/resources/scripts/eplayer.swf" -p "http://www.janjuaplayer.com/embedplayer/Dmaxg3/3/500/380" -y "Dmaxg3?id=37815&pk=408c1ca8856f67aed24ad4d966227ee07b26f67a8d6807c8e45c78ec55cdc9e6" -C S:OK -o Dmaxg3.flv
RTMPDump v2.4 KSV-05-05-2015
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
Connecting ...
INFO: Connected...
Starting download at: 0.000 kB
INFO: Metadata:
INFO:   presetname              Custom
INFO:   creationdate            Tue May 12 17:25:41 2015
INFO:   videodevice             ManyCam Video Source
INFO:   framerate               25.00
INFO:   width                   320.00
INFO:   height                  240.00
INFO:   videocodecid            avc1
INFO:   videodatarate           250.00
INFO:   avclevel                31.00
INFO:   avcprofile              66.00
INFO:   videokeyframe_frequency 5.00
INFO:   audiodevice             Mic estermo (IDT High Definitio
INFO:   audiosamplerate         44100.00
INFO:   audiochannels           2.00
INFO:   audioinputvolume        100.00
INFO:   audiocodecid            .mp3
INFO:   audiodatarate           96.00
28052.433 kB / 684.28 sec

on linux i use
livestreamer youtube-dl rtmpdump ngrep gdb(read flash memory to find token) virtualbox(simulate mobile device) .....

for the other question i don't know

I have not answered all your questions, but that does not matter, because I do not want your offerings

Last edited by biezom : 05-13-2015 at 01:19 AM.
Reply With Quote
  #3  
Old 05-13-2015, 06:43 AM
beerfoot beerfoot is offline
Linux *****
 
Join Date: May 2015
Posts: 6
beerfoot is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


Thank you Biezom, you rock

I've tried your method with ngrep on stream stream365(.)in/live13.html with the right network interface wlan0 and I only get :

Code:
interface: wlan0 (192.168.1.0/255.255.255.0)
match: play
###############################################exit
47 received, 0 dropped
after a few seconds of video stream read.

Do you have an idea?
Reply With Quote
  #4  
Old 05-13-2015, 07:16 AM
biezom biezom is offline
Senior Member
 
Join Date: Sep 2014
Posts: 1,025
biezom is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


Quote:
Originally Posted by beerfoot View Post
Thank you Biezom, you rock

I've tried your method with ngrep on stream stream365(.)in/live13.html with the right network interface wlan0 and I only get :

Code:
interface: wlan0 (192.168.1.0/255.255.255.0)
match: play
###############################################exit
47 received, 0 dropped
after a few seconds of video stream read.

Do you have an idea?
a) in a first administrator terminal


Code:
iptables -t nat -A OUTPUT -p tcp --dport 1735 -j REDIRECT --to-port 1935
b) in a second administrator terminal

Code:
rtmpsrv
c)load your video (it does not start, it's normal)
d) rtmpsrv generate a code like


Code:
rtmpdump -r "rtmp://185.39.9.98:1735/vod/" -a "vod/?token=play@143151868008681" -f "LNX 17,0,0,134" -W "http://www.businessapp1.pw/jwplayer5/addplayer/jwplayer.flash.swf" -p "http://www.playerapp1.pw/embed.php?c=118&width=650&height=380&autostart=true&tk1=DVXSZPhLw6S6iik6YBniuUcvM8mwyo%2FdmiLozOmED1imvUQ%2Fh22vNgJii1WfiybLGDoCp9KhoRvqShA3CwBfMA%3D%3D&tk2=xwn75qSiqwltiyrMQTj%2B0VmqgiqdVc2I0eNzmVnWDPQ%3D&tk3=wNEx02lQXP%2B2SrlJ0XXZvW5sZIdytARwwjFpnA3%2F%2BB4%3D" -y "stream22" -o "2015-05-13_02-05-03_stream22.flv"
with in red some parameters that works just once and limited in time
so when you have this code, for the rest you have to act quickly
e) copy the code
f) close your video
g) stop rtmpsrv (CTRL +C)
h ) in the first administrator terminal
Code:
iptables -t nat -D OUTPUT -p tcp --dport 1735 -j REDIRECT --to-port 1935
i) in an user terminal paste the code and run

Code:
rtmpdump -r "rtmp://185.39.9.98:1735/vod/" -a "vod/?token=play@143151868008681" -f "LNX 17,0,0,134" -W "http://www.businessapp1.pw/jwplayer5/addplayer/jwplayer.flash.swf" -p "http://www.playerapp1.pw/embed.php?c=118&width=650&height=380&autostart=true&tk1=DVXSZPhLw6S6iik6YBniuUcvM8mwyo%2FdmiLozOmED1imvUQ%2Fh22vNgJii1WfiybLGDoCp9KhoRvqShA3CwBfMA%3D%3D&tk2=xwn75qSiqwltiyrMQTj%2B0VmqgiqdVc2I0eNzmVnWDPQ%3D&tk3=wNEx02lQXP%2B2SrlJ0XXZvW5sZIdytARwwjFpnA3%2F%2BB4%3D" -y "stream22" -o "2015-05-13_02-05-03_stream22.flv"
RTMPDump v2.4 KSV-05-05-2015
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
Connecting ...
INFO: Connected...
Starting download at: 0.000 kB
INFO: Metadata:
INFO:   presetname              Custom
INFO:   creationdate            Mon May 11 20:00:06 2015
INFO:   videodevice             Conexant Polaris Video Capture
INFO:   framerate               24.00
INFO:   width                   720.00
INFO:   height                  404.00
INFO:   videocodecid            avc1
INFO:   videodatarate           480.00
INFO:   avclevel                31.00
INFO:   avcprofile              66.00
INFO:   videokeyframe_frequency 5.00
INFO:   audiodevice             Conexant Polaris Video Capture
INFO:   audiosamplerate         44100.00
INFO:   audiochannels           1.00
INFO:   audioinputvolume        75.00
INFO:   audiocodecid            .mp3
INFO:   audiodatarate           56.00
1377.777 kB / 23.07 sec
Reply With Quote
  #5  
Old 05-13-2015, 11:08 AM
beerfoot beerfoot is offline
Linux *****
 
Join Date: May 2015
Posts: 6
beerfoot is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


It works perfectly. You are AWESOME biezom, your post is clear and in the target. THANK YOU
Reply With Quote
  #6  
Old 05-13-2015, 01:49 PM
beerfoot beerfoot is offline
Linux *****
 
Join Date: May 2015
Posts: 6
beerfoot is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


I've been trying the same method, working for another stream, but unsuccessful for getting the rtmpdump command of regarder(.)me/splus/streamer.php?id=remi1

Could anyone briefly explain why this rtmp stream can't be caught the same way?

Thanks++
Reply With Quote
  #7  
Old 05-13-2015, 02:12 PM
biezom biezom is offline
Senior Member
 
Join Date: Sep 2014
Posts: 1,025
biezom is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


Quote:
Originally Posted by beerfoot View Post
I've been trying the same method, working for another stream, but unsuccessful for getting the rtmpdump command of regarder(.)me/splus/streamer.php?id=remi1

Could anyone briefly explain why this rtmp stream can't be caught the same way?

Thanks++
port 1935 in the previous case it was 1735

step a)
Code:
iptables -t nat -A OUTPUT -p tcp --dport 1935 -j REDIRECT
step h)
Code:
iptables -t nat -D OUTPUT -p tcp --dport 1935 -j REDIRECT
Reply With Quote
  #8  
Old 05-13-2015, 03:42 PM
beerfoot beerfoot is offline
Linux *****
 
Join Date: May 2015
Posts: 6
beerfoot is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


OK I'm going to review my "iptable book" to understand those port redirects
Reply With Quote
  #9  
Old 05-15-2015, 11:05 AM
beerfoot beerfoot is offline
Linux *****
 
Join Date: May 2015
Posts: 6
beerfoot is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


Hi Biezom, would you help me again for 5 minutes?

Now I can get the streams using rtmpdump - I learnt thanks to you - , what's the easiest way to push the caught stream to another rtmp server? Does ffmpeg do the trick?

Thank you
Reply With Quote
  #10  
Old 05-15-2015, 11:11 AM
biezom biezom is offline
Senior Member
 
Join Date: Sep 2014
Posts: 1,025
biezom is on a distinguished road
Default

Re: Catch and forward streams TUTORIAL => $50 reward


Quote:
Originally Posted by beerfoot View Post
Hi Biezom, would you help me again for 5 minutes?

Now I can get the streams using rtmpdump - I learnt thanks to you - , what's the easiest way to push the caught stream to another rtmp server? Does ffmpeg do the trick?

Thank you

sorry for this i don't know
Reply With Quote
Reply Post New Thread
Tags: , ,



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -6. The time now is 06:48 PM.


Powered by All-streaming-media.com; 2006-2011
vB forum hacked with Zoints add-ons