VideoHelp Forum
+ Reply to Thread
Page 1 of 2
1 2 LastLast
Results 1 to 30 of 48
Thread
  1. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Hello. I've been trying to find a way to download a higher quality (in this case 720p) of the demo bunny video from abyss.to for some days and I haven't found any solution. I was wondering if there's anyone who can give some pointers at least as to how to do it. The video is found at https://abyss.to/ and has available a lower quality of 360p but that can be downloaded without problems. The steps I've used are the following. I first filtered the network requests and looked for tunnel.

    Image
    [Attachment 76132 - Click to enlarge]


    Then I filtered the network requests and looked for txt. That Google link is where the video is found but cannot be accessed directly.

    Image
    [Attachment 76133 - Click to enlarge]


    I then combined those 2 URLs and used the following curl command (I think that the link found at the tunnel request may vary).
    Code:
    curl 'https://mjfuy5wdl19.apicdn72.one/a81268c21bad153beb' \
      -H 'Referer: https://abysscdn.com/' \
      --compressed > video_sd
    Then I checked the downloaded video and it's 360p. The video is working.

    Image
    [Attachment 76134 - Click to enlarge]


    If the page can't be inspected then the solution is to modify some function calls in its javascript code for the debugger checker part. The browser shouldn't be relevant in this part but for some reason for me, Firefox didn't stop at all in the debug stage when the inspect tool was detected but Chrome worked.

    Image
    [Attachment 76135 - Click to enlarge]


    My problem is that I don't know what exactly to modify to the request to get the 720p video. Or if it's even done in the same manner. A failed attempt to get the 720p video was to look for the requests that are getting parts of the video such as in the next image.

    Image
    [Attachment 76136 - Click to enlarge]


    I wrote a bash script that downloaded all the fragments. Each fragment then seemed to be some base64 encoded content. I then decoded it and appended all the files into a single file. I tried playing it and the player detected its full duration but only the first 20 seconds or so were working, the rest of the file was corrupted and couldn't be played. That being said I don't know what to try anymore and was wondering if someone can give some pointers at least.

    Edit: as of June 2024 the 360p curl method stopped working.
    Last edited by 2nHxWW6GkN1l916N3ayz8HQoi; 11th Jun 2024 at 09:51.
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  2. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    I found a workaround to download abyss.to with better quality. It is not a viable solution since it relies on a public site and won't even work 100% for all videos. But I tried it for 10 random ones and seems to be decent enough. It looks like the site always offers the highest quality available and doesn't let you download at any lower option even if the original video had them. First of all, you need the video ID which can be found by looking at the frame info of the video.

    Image
    [Attachment 76145 - Click to enlarge]


    Then you copy that ID and use it on the site like this: https://hellabyte.one/import/abyss/{abyss_id}. So in this case, the URL is https://hellabyte.one/import/abyss/0nBdh2D73 . If it stops you from downloading because of a timer simply use a VPN or even tor. After downloading the demo video from the site, it is indeed 720p.

    Image
    [Attachment 76146 - Click to enlarge]


    Edit: Apparently as of 13.03.2024 this stopped working.
    Last edited by 2nHxWW6GkN1l916N3ayz8HQoi; 13th Mar 2024 at 08:21.
    Quote Quote  
  3. nice video! and nice explanation
    Quote Quote  
  4. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    I wasn't quite pleased with the previously found solution (the one using a public site) so I coded my own. This solution is unusual since it relies on overwriting some javascript code regarding the player used by abyss/hydrax (jw player I think). It doesn't work for all videos 100% but when you need one that isn't available on the hellabyte site then you have another alternative at least. For those videos where the presented code works, an advantage is that you can manually set the desired quality. Also, if you don't have minimal coding knowledge or don't know someone who does then you can ignore this entire post.

    (The following steps were tested using the site https://abyss.to/ )
    1. In step 1 you load the page with the video and select the desired quality. Then you open dev tools and break the debugger detector as shown previously.

    2. Go to Sources -> Page and try to find the "bundle.min.js" file since that's where the "magic" happens.

    Image
    [Attachment 76178 - Click to enlarge]


    3. Ctrl+F and search in the js file for "prototype.put". Modify that function according to the next source code. I added some comments in the code to guide you better in understanding it. Only do this step if you understand what it does because I claim no responsibility if something goes bad, etc., etc. yada, yada.

    Code:
    // Add these variable initializations outside the detected function of interest
    var batchMap = new Map();
    // Adjust the batchSize value according to your needs. A low value means a high number of downloads but also a high chance to skip over some downloads 
    // because the stream of downloads can't be handled. A high value means a low number of downloads but more waiting time in between downloads which
    // also increases the chance of failure
    var batchSize = 150;
    // Use DEBUG_MODE as true to detect the COUNT_FRAGMENTS value then turn it to false if you want to download the video fragments
    var COUNT_FRAGMENTS = 1983;
    var DEBUG_MODE = true;
    
    // Look for a function that handles a video fragment and its associated index in the bundle.min.js file used by abyss.to
    n.prototype.put = function (e, t, r) {
      // The original page source code is left untouched since we don't want to break its flow
      if (this.closed)
        return s(r, new Error("Storage is closed"));
      var i = e === this.lastChunkIndex;
    
      // Variable used to keep the original flow while adding additional features
      var result = i && t.length !== this.lastChunkLength ? s(r, new Error("Last chunk length must be " + this.lastChunkLength)) : i || t.length === this.chunkLength ? (this.chunks[e] = t,
        void s(r, null)) : s(r, new Error("Chunk length must be " + this.chunkLength))
    
      // -- Add this code below --
      // Displays the fragment count since it needs to be known how many fragments the video uses
      if (DEBUG_MODE) {
        console.log(this.chunks.length);
        return result;
      }
    
      // To avoid downloading entire large videos (> 1 GB), the fragment stream is divided into batches of fixed length using a Map object
      let batchIndex = Math.floor(e / batchSize);
      let currentBatch = batchMap.get(batchIndex);
      // If the batch is new then it is initiated
      if (currentBatch == undefined || currentBatch == null) {
        currentBatch = [];
      } else {
        // If the batch was already downloaded then it is ignored
        if (currentBatch.length === 0) {
          return result;
        }
      }
    
      // If the fragment from the batch was already loaded then it is ignored
      let isAlreadyLoaded = currentBatch.some((index, content) => index === (e % batchSize));
      if (isAlreadyLoaded) {
        return result;
      }
      currentBatch.push([e % batchSize, t]);
      let isLastPiece = this.chunks.length === COUNT_FRAGMENTS;
    
      // If a batch is completed or this is the last video fragment
      if (currentBatch.length === batchSize || isLastPiece) {
        // Previously loaded fragments from that batch are sorted by the fragment index and then concatenated into a single fragment
        currentBatch.sort((tuple1, tuple2) => tuple1[0] - tuple2[0]);
        let concatCurrentBatch = [];
        currentBatch.forEach(tuple => {
          concatCurrentBatch.push(...tuple[1]);
        });
    
        // Converts the concatenated batch to blob
        const batchBlob = new Blob([new Uint8Array(concatCurrentBatch)], { type: 'application/octet-stream' });
    
        // Spawns a download button, then automatically clicks it, and then removes the button
        const downloadLink = document.createElement('a');
        downloadLink.href = URL.createObjectURL(batchBlob);
        downloadLink.download = "v" + batchIndex + ".mp4";
        document.body.appendChild(downloadLink);
        downloadLink.click();
        document.body.removeChild(downloadLink);
    
        // Batch is emptied to know it was previously sent
        currentBatch = [];
      }
    
      batchMap.set(batchIndex, currentBatch);
      // If the fragment is the last piece then the Map object is emptied
      if (isLastPiece) {
        batchMap = new Map();
      }
      return result;
    }
    Make sure DEBUG_MODE is set to true and that you picked your wanted video quality and then refresh the page.

    4. Keep dev tools open and go to console output. Skip the video ahead until the last minute and let it load. You can increase the video speed to save time. You need to copy the last value displayed in the console after the video is done playing.

    Image
    [Attachment 76167 - Click to enlarge]


    The value in the picture indicates that this video for its selected quality, is made up of 1983 fragments.

    5. Initialise the variable COUNT_FRAGMENTS using the displayed console value and switch DEBUG_MODE to false. Set the batchSize value to something around 150-500. Refresh the page.

    6. Load the video and set it to the highest possible speed. The goal is to force the video player to request all video fragments (1983 in this case). And to do that you need to "watch" the whole video. What if 2x is too slow especially if you want to download a 3-hour movie? Then you can install a browser addon that lets you set an even higher speed. I personally use the "Video Speed Controller" addon and I have set it up to 16x speed. That means a 3h movie "could" be downloaded in ~12 minutes which is not that bad (ignoring the internet speed of course).

    Image
    [Attachment 76168 - Click to enlarge]


    Simply put the highest speed and let the video play out until the end (personally I let it play in the background while it downloads). If the video player gets stuck then simply go backwards 10 seconds using the video player interface. The JS code from step 3 makes sure that each fragment is sent only once and no duplicates happen.

    Make sure your browser downloads by default in your folder of choice and also that it downloads without asking you the path. The first batch of downloads may be blocked by the browser because they are too many. You need to temporarily enable "Automatic downloads" for your specific site. Don't forget to disable it back after you're done with the video!

    To save time, when the downloads happen you can check the v0.mp4 (the first fragment). If it can be played in your local video player (the first 2-3 seconds at least, since it's just a fragment), then there is a high chance that the entire video may be good. Otherwise, close the browser to stop downloading since it won't work for your specific site.

    7. After the video ends and the downloads stop, go to your download folder and you should see the files: v0.mp4, v1.mp4, ..., vN.mp4. Run the following command.
    Code:
    cat v{0..N}.mp4 >> bigfile.mp4
    For example (for N=12):
    Code:
    cat v{0..12}.mp4 >> bigfile.mp4
    8. The resulting mp4 file is your fully downloaded video. Check if it's a valid file by playing the video and that's it, done.

    Out of curiosity, I checked if the downloaded file is the same as the one uploaded on mega.nz in the first post reply and they match indeed.

    Image
    [Attachment 76169 - Click to enlarge]


    Now I wanted to test this solution more so I grabbed some hydrax videos from past videohelp forum posts and I added some of my own.
    https://clbphimxua.com/biet-doi-rong-1983/

    Image
    [Attachment 76170 - Click to enlarge]


    https://vlist.se/hydrax.html#OHBuc0c4VE41

    Image
    [Attachment 76171 - Click to enlarge]


    https://thiendang.vn/movie/s1e2-lawn-gnome-beach-party-of-terror/

    Image
    [Attachment 76172 - Click to enlarge]


    https://ww1.m4uhd.cc/watch-movie-passa-sartana--lombra-della-tua-morte-1969-255412.html

    Image
    [Attachment 77864 - Click to enlarge]


    Even though it works for the previous sites, it couldn't possibly work for all of them. So I began looking for places where it doesn't and found this one:
    https://animet.net/phim-doraemon-new-tv-series-tap-688-1591.138916.html (use the Hydrax player - HRX#1).
    But at least as a starting point, it looks good. If you were interested only in the practical part of this solution then you can skip entirely the next theoretical part.

    Now how exactly is the video getting downloaded? If you didn't guess until now, the video fragments aren't directly requested from the Hydrax server. But rather the video player is used as an intermediate. So I simply "intercept" the video fragments, divide them into batches, then download them for my use, and then reassemble the final video. The video player keeps doing its job in the background and the video is downloading in the intermediate layer.

    That isn't exactly the most efficient way. A proper alternative would be to directly call the Hydrax server from a script using specific URLs. But the bad thing is that Hydrax uses web sockets. So if you were to do that, you would need to reverse engineer code like this.

    Image
    [Attachment 76174 - Click to enlarge]


    And trying to understand obfuscated garbage code like that is a major headache. It is not easy and if you were to make the written script public, it would get patched and their websocket protocol changed again. It wouldn't be the first time as seen in this forum post: https://forum.videohelp.com/threads/401803-Winevine-decryptor-didn-t-work#post_2619636

    The worst that could happen with the JS code approach is that they simply obfuscate the code even more. The main idea should remain the same. Moving on, knowing the video was sent somehow with WebSockets, I needed to find a fragment.

    Image
    [Attachment 76175 - Click to enlarge]


    That fragment contains additional data that is used in maintaining their websocket protocol. And even if you captured that fragment, you still needed to "alter" it somehow to construct the full video. Knowing that the video fragment needs to be sent to the video player, then there is some piece of code that alters it. All I did was find a random function that handles the final video fragment and especially receives as another parameter, its index.

    Now this solution obviously isn't meant to be casually used since it's not presented as an add-on or even some basic script. Also, it definitely isn’t helpful in mass downloading lists of videos. But rather is meant to help you if you desperately need a specific video of specific quality on some obscure site that uses hydrax. Otherwise, just look for another site source.

    I have no idea though why for some sites it's not working. Maybe my logic is flawed, maybe I missed something. I hope at least this post can help others start from something if they want to develop a proper way of downloading since I've seen quite a few forum posts left unanswered regarding Hydrax (the more recent Hydrax since it was easier downloading from it before). For me personally, this method + hellabyte is good enough.

    Originally Posted by lomero View Post
    nice video! and nice explanation
    Thank you!

    Thanks for the uploaded video. I used it as a reference to compare its data to some fragments I downloaded and it helped me to reach a somewhat working solution on my own.
    Last edited by 2nHxWW6GkN1l916N3ayz8HQoi; 22nd Mar 2024 at 07:20. Reason: added clarifications
    Quote Quote  
  5. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Alright, so I think I may have found a solution that could work for any Hydrax video by trying to find a workaround for this problematic site:
    https://animet.net/phim-doraemon-new-tv-series-tap-688-1591.138916.html

    I still didn't find out why the batch JS code wasn't working properly but debugging around that site was a big headache, especially with their overkill debugger detector so I thought, why not play that specific video on another site where the script works because these Hydrax videos are always being played on the jw player.

    Now I'll explain how you can attach a hydrax video from one site to another.
    1. In the first step go to your site and get the video ID by opening the "Frame Info" (as explained in the hellabyte solution). Then keep in mind the resolution you want from that video (1080p for example). This is all the information you need and you can close that site now because it's of no use anymore.

    2. On every page that uses a JW player, the player instance is initialized using a base64 value. Example:
    Code:
    eyJzdGF0dXMiOnRydWUsImlkIjoiZjMwYzUwZjQ0N2MwMDQ2YmJmIiwibWQ1X2lkIjoxNTY4MTEyNiwidXNlcl9pZCI6MjIwMiwic291cmNlcyI6WyJzZCIsImhkIiwiZnVsbEhkIl0sInNvdXJjZV9icmVha3MiOltdLCJjZG5faWQiOm51bGwsImRvbWFpbiI6ImhlZ3ZndWpsODEuYXBpY2RuMTIub25lIiwiZG9tYWluX2NkbiI6bnVsbCwiZG9tYWluX21vcmUiOltdLCJ1c2VfcDJwIjpmYWxzZSwidXNlX2Rvd24iOmZhbHNlLCJwcmV2aWV3Ijp0cnVlLCJzdWJ0aXRsZXMiOmZhbHNlfQ==
    Which translates to (I added newlines and spaces to make it readable):
    Code:
    {
      "status": true,
      "id": "f30c50f447c0046bbf",
      "md5_id": 15681126,
      "user_id": 2202,
      "sources": [
        "sd",
        "hd",
        "fullHd"
      ],
      "source_breaks": [],
      "cdn_id": null,
      "domain": "hegvgujl81.apicdn12.one",
      "domain_cdn": null,
      "domain_more": [],
      "use_p2p": false,
      "use_down": false,
      "preview": true,
      "subtitles": false
    }
    Those variables are used to load a specific video into the JW player. So obviously, if we want to attach a video from one site to another, we would need its initiating base64 value. The Python script below does that. It uses the video ID and extracts the base64 value by sending a GET request to the player URL and by using regular expressions.
    Code:
    import re
    
    import requests
    
    HYDRAX_PLAYER_URL = "https://player-cdn.com/?v="
    ATOB_PATTERN = r'atob\("([^"]+)"\)'
    hydrax_id = input("Insert the Hydrax video ID: ")  # Example: kpzR4_Ugg
    
    response = requests.get(HYDRAX_PLAYER_URL + hydrax_id)
    match = re.search(ATOB_PATTERN, response.text)
    
    if match:
        print(match.group(1))
    else:
        print("No atob found for this hydrax id")
    3. Now load the page where you want to attach your video. The only conditions for that page are:
    a. It needs to have a JW player obviously.
    b. It doesn't have a too complex debugger detector.
    c. It is better if you can download existing original videos from that page using the batch JS method. It is not mandatory but it does increase the chances of successfully downloading your newly attached video.

    For the sake of this tutorial, I will use https://abyss.to/ since it has been already proved you can download from it.

    4. Load the chosen page. Break its debugger detector. Try to find the page in the Sources tab that deals with the JW player creation. The code may look something like:
    Code:
    new PLAYER(atob("string"))
    Image
    [Attachment 76189 - Click to enlarge]


    Replace the atob parameter with the base64 value returned by the Python script from step 2. Reload the page and you should now see your video attached to it, instead of the old one. Interestingly, if you hover over the video bar, you will get previews of the old video. However, that is no problem so don't worry.

    Image
    [Attachment 76184 - Click to enlarge]


    5. You need to make sure that your desired level of quality is properly set by default by the JW player on every page reload. A problem is that if the original video had only 360p/720p and your new attached video also has 1080p, then you need to somehow add that option to the page source code so that it can be set by default if you want to download it. If it's not set by default, then the batch JS code fails. First, see what the corresponding name is for your wanted quality. I found in the source code this information.

    Image
    [Attachment 76186 - Click to enlarge]


    So if you attached a video for which you know for sure 1080p is available, you will be interested in the "fullHd" value. Then look again in the sources tab and try to find where the resolutions are configured by default. Usually, that piece of code is found in the same page as the PLAYER initialization from step 4.

    Image
    [Attachment 76187 - Click to enlarge]


    If you don't see your wanted resolution written in that piece of code, simply add it together with some random values. It seems that they don't matter that much. Doing that, you will get something like this:
    Code:
    window.SoTrymConfigDefault = {
       "pieceLength": 65536,
       "sd": [35336170, 35388949],
       "hd": [129914119, 129929472],
       "fullHd": [1, 2]
    };
    Override the source code. Now reload the page, set your wanted resolution, and refresh a couple of times. If your specific resolution is set by default properly that's it, done. You can now download the video by following the tutorial from the batch JS method. Initially, it didn't work on the problem site for some unknown reasons but on this one where we attached the video it works.

    Image
    [Attachment 76188 - Click to enlarge]


    Now concluding. In theory as of now, the attaching method + batch JS should work for any hydrax video on any site you want and with any level of quality you need. You are not relying anymore on external sites and have a little more freedom of choice. The best thing is that you don't even care about their websocket streaming protocol since you "intercept" their raw video fragments by using the JW player as an intermediate. Of course if the "bundle.min.js" file from hydrax changes then the batch JS solution needs to be modified for another function of interest that deals with video fragments. But that remains a problem for the future.

    If someone finds a site where the entire explained method doesn't work then I'll gladly look into it.

    I downloaded it from hellabyte to compare the video fragments. Funnily enough, the original bad file I got was almost the same size as the one from hellabyte. A couple of kilobytes were missing. My guess is probably the debugger detector is messing with something and I didn't notice. But at least you can completely ignore any source site now by attaching the video somewhere else.

    Edit: as of 15-aug-2024, they refactored some code. The trick is 99.99% identical, except you apply it to the file "core.bundle.js" and you look for the text "? (clearTimeout" to find the place where you inject code.
    Last edited by 2nHxWW6GkN1l916N3ayz8HQoi; 15th Aug 2024 at 07:08. Reason: added clarifications
    Quote Quote  
  6. Every now and then someone come up with a great essay such as this. Highly impressive. Thanks for sharing.
    Quote Quote  
  7. yes, right jack. amazing explanation
    Quote Quote  
  8. Member
    Join Date
    Mar 2024
    Location
    Africa
    Search Comp PM
    the hellabyte trick does not work anymore, is there a way for someone without coding knowledge to download them now?
    Quote Quote  
  9. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Originally Posted by smile0 View Post
    the hellabyte trick does not work anymore, is there a way for someone without coding knowledge to download them now?
    Try this one, I'm curious to see if it works

    https://forum.videohelp.com/threads/408582-How-to-download-video-from-embedded-link#post2721544
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  10. Member
    Join Date
    Mar 2024
    Location
    Africa
    Search Comp PM
    Originally Posted by 2nHxWW6GkN1l916N3ayz8HQoi View Post
    Originally Posted by smile0 View Post
    the hellabyte trick does not work anymore, is there a way for someone without coding knowledge to download them now?
    Try this one, I'm curious to see if it works

    https://forum.videohelp.com/threads/408582-How-to-download-video-from-embedded-link#post2721544
    It works but you can't choose the definition.
    Quote Quote  
  11. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Originally Posted by smile0 View Post
    It works but you can't choose the definition.
    Does it get the highest one? (or at least an acceptable one).
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  12. Member
    Join Date
    Mar 2024
    Location
    Africa
    Search Comp PM
    Originally Posted by 2nHxWW6GkN1l916N3ayz8HQoi View Post
    Originally Posted by smile0 View Post
    It works but you can't choose the definition.
    Does it get the highest one? (or at least an acceptable one).
    after multiple tries it only generates 360p videos on my phone.
    Quote Quote  
  13. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Originally Posted by smile0 View Post
    after multiple tries it only generates 360p videos on my phone.
    Then it is what it is. Wait for someone to reverse engineer their websocket protocol and also to be willing to share it publicly. Or if you're desperate, either look for another source or record the screen.
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  14. update on my newest comment
    Last edited by cibkosglowendnl; 11th May 2024 at 02:39.
    Quote Quote  
  15. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Originally Posted by cibkosglowendnl View Post
    working on multiple sites tested using abyss.to
    original post
    https://github.com/thorio/KGrabber/issues/35#issuecomment-1997482075
    And the cat and mouse game starts again. Nice find! Seems to me this is the proper solution.
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  16. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Code:
    import re
    import base64
    import requests
    import json
    
    H_VIDEO_ID = "<VIDEO_ID>"
    H_PLAYER = "https://player-cdn.com"
    H_CDN = "https://abysscdn.com"
    H_DOWNLOAD_LINK = "https://{domain}/{prefix}{v_id}"
    
    QUALITY_PREFIX = {
        "360p": "",
        "720p": "www",
        "1080p": "whw"
    }
    DOWNLOAD_RES = "1080p"
    
    response = requests.get(f"{H_PLAYER}/?v={H_VIDEO_ID}")
    b64_value = re.search(r'atob\("([^"]+)"\)', response.text).group(1)
    content = json.loads(base64.b64decode(b64_value).decode())
    
    domain, v_id = content["domain"], content["id"]
    
    print("Starting download...")
    try:
        response = requests.get(
            H_DOWNLOAD_LINK.format(domain=domain, prefix=QUALITY_PREFIX[DOWNLOAD_RES], v_id=v_id),
            headers={"Referer": f"{H_CDN}/?v={H_VIDEO_ID}"}
        )
        with open("video.mp4", "wb") as f:
            f.write(response.content)
    except:
        print(f"Resolution {DOWNLOAD_RES} is not available")
    Here is a short script to download any Hydrax video at any wanted quality (inspired by the GitHub post, kudos to those who found the solution, well done @PatrickL546). You still need to get the embedded video hydrax ID manually using the frame info trick. I guess you could design a smarter data scraper that can deal with any site where there is a hydrax video embedded but I don't care that much to generalize the solution.

    Edit: as of June 2024 this stopped working.
    Last edited by 2nHxWW6GkN1l916N3ayz8HQoi; 11th Jun 2024 at 09:52.
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  17. Member
    Join Date
    Mar 2024
    Location
    Africa
    Search Comp PM
    Originally Posted by 2nHxWW6GkN1l916N3ayz8HQoi View Post
    Code:
    import re
    import base64
    import requests
    import json
    
    H_VIDEO_ID = "<VIDEO_ID>"
    H_PLAYER = "https://player-cdn.com"
    H_CDN = "https://abysscdn.com"
    H_DOWNLOAD_LINK = "https://{domain}/{prefix}{v_id}"
    
    QUALITY_PREFIX = {
        "360p": "",
        "720p": "www",
        "1080p": "whw"
    }
    DOWNLOAD_RES = "1080p"
    
    response = requests.get(f"{H_PLAYER}/?v={H_VIDEO_ID}")
    b64_value = re.search(r'atob\("([^"]+)"\)', response.text).group(1)
    content = json.loads(base64.b64decode(b64_value).decode())
    
    domain, v_id = content["domain"], content["id"]
    
    print("Starting download...")
    try:
        response = requests.get(
            H_DOWNLOAD_LINK.format(domain=domain, prefix=QUALITY_PREFIX[DOWNLOAD_RES], v_id=v_id),
            headers={"Referer": f"{H_CDN}/?v={H_VIDEO_ID}"}
        )
        with open("video.mp4", "wb") as f:
            f.write(response.content)
    except:
        print(f"Resolution {DOWNLOAD_RES} is not available")
    Here is a short script to download any Hydrax video at any wanted quality (inspired by the GitHub post, kudos to those who found the solution, well done @PatrickL546). You still need to get the embedded video hydrax ID manually using the frame info trick. I guess you could design a smarter data scraper that can deal with any site where there is a hydrax video embedded but I don't care that much to generalize the solution.
    Do I just fill in the blanks and paste the script in the command prompt?
    Quote Quote  
  18. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Originally Posted by smile0 View Post
    Do I just fill in the blanks and paste the script in the command prompt?
    That's a Python script. You replace <VIDEO_ID> with the hydrax ID taken from the frame info. And you replace the DOWNLOAD_RES value with the value of your wanted quality (360p, 720p, or 1080p). It will try to download that resolution or at least the next highest one. So if you want to try 1080p for a 720p max video only, you will get 720p.
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  19. update on my newest comment
    Last edited by cibkosglowendnl; 11th May 2024 at 02:40.
    Quote Quote  
  20. long time not update, today i just see this thread getting updated. damn your code is good. with that i can embed into one click download website
    Quote Quote  
  21. Last edited by cibkosglowendnl; 14th May 2024 at 08:52.
    Quote Quote  
  22. is it still working solution? i've tried to download the video from m4uhd and I got the error Image
    [Attachment 79545 - Click to enlarge]
    Quote Quote  
  23. Try the python downloader
    Quote Quote  
  24. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Lmao. They changed something and broke the python code. Took them long enough. Was kinda ridiculous. What a silly game. At least the js code injection still works so they still have work to do.

    Originally Posted by LZAA View Post
    Url?
    Just try the bunny demo. I'm curious if your method still works.
    https://abyss.to/
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  25. OK. Scripts don't work.
    The previous algorithm does not work. The new one works.
    Quote Quote  
  26. Feels Good Man 2nHxWW6GkN1l916N3ayz8HQoi's Avatar
    Join Date
    Jan 2024
    Location
    Pepe Island
    Search Comp PM
    Originally Posted by LZAA View Post
    OK. Scripts don't work.
    The previous algorithm does not work. The new one works.
    Bit confused here. By "new one" you mean the one in github/tampermonkey script? Or something else that you came up with just recently? If so, then congrats!
    --[----->+<]>.++++++++++++.---.--------.
    [*drm mass downloader: widefrog*]~~~[*how to make your own mass downloader: guide*]
    Quote Quote  
  27. I specifically used the term 'algorithm' in order to separate this tool from the public ones (Python Scripts&JS).
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!