Friday, February 25, 2011

Download Samurai.FM Stream As MP3

Learn how to download or rip any Samurai.FM stream as m4a and convert the m4a to mp3.

Samurai.FM hosts all the audio files in the m4a file format and streams them through the RTMP protocol. To find the rtmp stream URL you need an advanced network sniffer. To download the m4a audio file hosted at such a rtmp stream URL you need a downloaded tool that supports the rtmp protocol. Both these functions are combined in one great program already, CooJah 6. Make sure to carefully read this little post on how to install and configure CooJah 6 as unfortunately its InstallShield is in Chinese. Don't start to worry now! The graphical user interface is entirely in English.

Sniffing Samurai.FM
After you have installed and configured CooJah 6 go to Samurai.FM and sniff your first Samuraif.FM rtmp stream URL. In this example I am going to use Tanith's set at Tresor from 16th Feb 2011. Go to that page or any other page on Samurai.FM from where you would like to download music.

Now run CooJah 6 and start sniffing your network traffic. Then hit the red play button on the Samurai.FM page. You will see the rtmp stream URL appearing immediately in CooJah 6.




That is it for the first step already! As you can see the URL starts with rtmp.

Download Samurai.FM RTMP Stream
Now all that is left to do is right-click on the rtmp stream URL found by CooJah 6 and select Download by Blader, the integrated download tool.



Blader will now open with the New Task window. There you can select the download path and rename the audio file if you like. Make sure not to change the filename extension and leave Download live video unchecked. What I like to point out here is that you can see the entire request header. This is an truly awesome feature and very important if you like to write your own command line for RTMPDump.



Once you have selected the download path and chosen a filename hit OK and Blader will start downloading the audio stream directly from Samurai.FM.



Convert M4A To MP3
Once the m4a file is downloaded you can convert it to a mp3 audio file. There are many free and unfortunately crappy tools to do this. Therefore I highly recommend using the excellent WinFF for this purpose. WinFF is a program with graphical user interface that uses FFMpeg, a command line tool to convert multimedia files between formats. Since most of you don't like dealing with command lines use WinFF. You can download WinFF from here. WinFF is really easy to use and very powerful as it has a lot of options for tweaking conversions to your desired results.

Once downloaded and installed in WinFF click on Add to select the m4a file you downloaded with Blader. For Output Details select Audio in the Convert to: drop down menu and MP3 in the Preset: drop down menu. Last not least select your Output Folder. Now hit convert and let WinFF do its job.



A command window will open and show you the details about the conversion. Once finished it will ask you to hit any key to close that command window.



You can now enjoy your perfectly converted mp3 downloaded from Samurai.FM and converted with WinFF anywhere and anytime you like.

Hopefully you have enjoyed this little insight to Samurai.FM and can now download all the podcasts, mixes or sets that you like without any restrictions. If you find a mix that you have problems downloading drop me a comment and I will help you find the right rtmp stream URL.

16 comments :

  1. hi..
    lets exchange links..
    i have put yours on my blog

    ReplyDelete
  2. Hi Budi,

    thanks for linking to my blog. I have a list of blogs and sites that I read and think other people might be interested in. It is on the right hand side of my blog as you can see. If I decide your blog to be interesting enough and filled with content that I appreciate you can be sure that I will link to you. Try to improve your blog with posts about topics that have not been widely covered for example.

    All the best!

    ReplyDelete
  3. Thanks so much! Works very well and pretty easy.

    ReplyDelete
  4. I thank you very much for sharing all you inside knowledge on these topics.
    I unfortunately could not get Coojah to work (I think it might have a problem detecting my network controller / have similar problem with URL Snooper) / never the less I managed to "record" the set I wanted from Samurai.

    Now a question you might have an answer to - Do you know of any way to get hold of content "hidden" behind .flv.smil
    Like for example the videos at DanceTrippin.tv
    If you have, I hope your are willing also share this technique with us ?

    ReplyDelete
  5. Illuminate, thanks for your comment. Let's first have a look at why your network adapter/controller is not being recognised.

    What is your network adapter's model and make please? I am sure it can be seen in URL Snooper as well as CooJah. Tell me more and what error message you get when you select it in URL Snooper for example and I can try to help you better.

    Now about DanceTrippin.tv. The .flv.smil is actually packing the video into a RTMP stream. I had no problems pulling the RTMP stream with CooJah in no time. However I also had to disable my HOSTS file for the video to load completely, so if you have a HOSTS file in place, for example the one from MVPS http://winhelp2002.mvps.org/hosts.htm make sure to disable that as well as allow dancetrippin.tv in the NOSCRIPT Firefox addon in case you run it.

    The video stream loaded and got picked up by CooJah and I could download it with 1-3MB/s, so quite fast.

    However I must tell you that recently I have done some testing with CooJah and have found out that is does not pick up streams when it sniffs from newer version browsers, so to speak, the latest Firefox 7 for example. I tested it with Firefox 3.5 and it worked perfectly on most sites where with Firefox 7 I would not get any stream shown in CooJah whatsoever.

    So you can try two things. Get a portable installation of Firefox 3.5 for example and then tell CooJah in the tools - settings - filter settings to sniff from the portable Firefox 3.5, go to DanceTrippin.tv and try again, the RTMP stream should now come up.

    You can also try with another browser like Chrome or Safari, however I am not too sure how good CooJah is with sniffing traffic from those.

    The second thing you can try is get the RTMP stream directly with RTMPDump. I went to this video from UMEK http://www.dancetrippin.tv/video/umek-party-cause-slovenia-techno and had CooJah running, it would definitely pick up what you had already, the URL with .flv.smil at the end.

    For the UMEK video this was

    http://hwcdn.net/k7w9n4n5/fms/episodes700/231.flv.smil

    When you now actually go to that site you will see two longer lines, one starting with meta base and one starting with video src. If you put the content/string in brackets of those two longer lines right behind each other you will get the RTMP stream for the video. So simply join those two lines and you have your RTMP stream URL, it being:

    rtmp://fms026.am4.hwcdn.net/k7w9n4n5/_definst_fms/episodes700/231?doppl=0de800df43456fc7&dopsig=18b33e9b7b43f7bfae58ceee6c94466c

    The only thing left now it putting that into RTMPDump with a few extra commands. If you need to I can write those commands out for you if the GUI (graphical user interface) approach with CooJah does not reap any success, however I am sure we can get CooJah run perfectly fine on your system.

    Hope this helped you, please let me know if you managed with my instructions or not, also please do let me know your system OS and version and the browser and browser version used with CooJah when you continue to have problems with it.

    Sorry I could not reply earlier, on the other hand I hope I have now replied detailed enough to really help you.

    OK, Illuminate, you take good care and please don't forget, "Dance, dance.. else we are all lost!".

    ReplyDelete
  6. Technolux, thx for taking your time answering.

    At the moment I'm running on a Sony laptop with Win 7 Home Premium 64 bit.

    Browsers:
    Firefox 7.0.1 (x86)
    Chrome 13.0.874.106
    Safari 5.1
    IE 9.0.8112.16421

    The problem with the not recognized (or not present in list) network adapter in both URL Snooper and CooJah was solved by switching my connection from the WiFi adapter to a wired one.
    Then both URL Snooper and CoolJah started reacting, and I was able to see what I needed.

    I can confirm what you mention with regards to Firefox 7 and CooJah - here nothing much useful shows up.

    With Safari and IE9, CooJah picked up the rtmp without any problems.

    With Chrome, CooJah also picked up the rtmp, despite of the flash plugin crashed.

    Once again thx.

    "Illuminate dancing out the door to the sound of Dubfire @ El Row"

    ReplyDelete
  7. Illuminate, wicked comment! Thanks! Excellent you took the time to reply in such great detail. This info is vital for other people as well that might have run into similar challenges.

    Last question: Did you have all those browsers installed or were they partly the portable versions of for example Firefox and Chrome?

    I guess not since the portable version of Firefox and Chrome does not reap many results with CooJah over here. However since you say Chrome worked with the flash plugin crashed, it might have worked just because the plugin crashed.

    If you find time let me know. Thanks again!

    ReplyDelete
  8. Coojah works fine and I've downloaded few sets from samurai.fm, but when I play native m4a files with VLC, or when I play converted mp3 files the music cycles every 20 seconds several times, then goes on, and cycles next 20 sec... Sameny suggestion? effect playing on PC, or ipod. While converting with WInFF there is a msg: Transition from ONLY_LONG or LONG_STOP to an EIGHT_SHORT sequence detected. If you heard and audible artifact, please submit the sample to the FFmpeg developers.
    Any suggestion, besides submitting the sample ?

    ReplyDelete
  9. Pacypenev,
    thanks for your comment. I will investigate and then let you know. If you find something in the meantime please post it here as well. Thanks. Speak soon!

    ReplyDelete
  10. Also I will update the post about installing and configuring CooJah 6 and its sniffing capabilities with regards to installed and portable browsers and their versions. People need to know what browser versions and whether it is an installed or portable version works best with CooJah 6.

    ReplyDelete
  11. How To Download Videos From Increase.indiacan.com

    ReplyDelete
    Replies
    1. It works fine with CooJah 6, just play the content while you have CooJah 6 running, it will pick up the stream and record it just fine.

      Delete
    2. it doesn't work.. video didn't play while cooljah is running... maybe it detecting cooljah.

      Delete
    3. At the moment I can't even reach http://increase.indiacan.com/

      Delete
    4. Also the site says now:"Browser other than IE are not supported." Sorry I am not visiting any site I cannot visit with Firefox or Chrome. My support for downloading from increase.indiacan.com ends here. Get them to accept Firefox and Chrome and I will show how to get all their videos.

      Delete

Comments Are Always Moderated.