Muz.ru gives away audio material for free

    imageGreetings to all users!

    NB I want to make an amendment right away. The fact is that audio material from muz.ru servers can be obtained as 128 kb / s . Therefore, this technique will be relevant only for audio books, rather than for compositions.

    What was all this for?


    The answer is very simple - for fun. The fact is that the site presented uses its own flash audio player, which in some cases behaves humanely, but in some it does not. I will explain why. This player reproduces some audio recordings in full, and some forcibly cuts up to 30 seconds. I can’t say anything about compositions that are being trimmed, but on audio books, yes - they are all trimmed to 30 seconds. That's why I decided to figure out what's what.

    How to get a file


    At first I decided to study their flash audio player. He pulled it out of the site, repelled it, but did not see anything worthwhile, and therefore decided to quit this venture by questioning the suspect and begin to examine GET and POST requests from / to the server.

    In order to get information about the track, you need to send a POST request to muz.ru/Services/Player2.asmx/GetTrackInfo and specify the track number as the transmitted parameter: The



    answer will not be long in coming and as a result we get this:



    Us will be interested in the FirstTouchGuid parameter. I want to note that this parameter is unique and it changes with each new access to the server. Then, to get the Id of the link, we need to send a request to the address:
    h ** p: //fs.muz.ru/handlers/link.ashx? F = FirstTouchGuid

    As a result, we will return the same unique Id from which we can already form final link to the audio recording. The link itself will look like this:
    h ** p: //fs.muz.ru/handlers/audio.ashx? F = downloadLinkId

    As a result, we can save the file audio.ashx , which is nothing but mp3 :



    Process automation


    I sketched the simplest C # code, which allows you to demonstrate all of the above. This code looks like this in a window view:



    Window view source code: pastebin.com/E09zNKPS

    P.S. All of these my speculations are exclusively informative in nature. I consider it correct to store audio recordings on the server trimmed in a hardcore way for up to 30 seconds, and not to invent players that can only hide part of the audio recording from the user. I wrote to the site administration about a year ago, but the omnipotent ignore turned out to be so omnipotent.

    Thank you for your attention to reading this post. Have a nice day everyone!

    Also popular now: