Live data from Hacker News

Bypassing YouTube video download throttling

blog.0x7d0.dev

81–90 of 242 posts

Re: Bypassing YouTube video download throttling

#81

Earlier quoted context omitted.

> I wonder what is their reasons for not using it - Introduces a decryption step, which is slow - Forces software video decoding, which is slow - Web browsers only support the weakest form of Widevine which is ineffective It would effectively push a significant portion of their user base off the platform while not being very effective in its goals.

> - Forces software video decoding, which is slow No it doesn't. Heck, forcing software decoding is actually one of the ways to force Widevine down to lower protection levels on general purpose hardware. > - Web browsers only support the weakest form of Widevine which is ineffective It's not fullproof but it would certainly make tools to bypass it clearly illegal in most of the world. There are efficacy reasons for n…

> No it doesn't.

If you're using a PC with a Nvidia GPU, run `nvidia-smi dmon -s u` and start playing a random Youtube video in Chrome. You'll notice how dec% moves from 0% to at least 2%. Pause, and start playing Widevine protected video and notice how dec% stays at 0% because decoding is happening on the CPU.

> It's not fullproof but it would certainly make tools to bypass it clearly illegal in most of the world.

Good luck, copyright infringement is already illegal and yet that hasn't stopped it from being widespread. Tools and techniques to bypass Widevine L3* are widely known and available (yes, even on GitHub).

I was being generous in my previous comment. In reality, deployment of Widevine L3* should be shunned at least as much as Proof-of-work cryptocurrencies. It's completely ineffective in protecting content, it burns unnecessary CPU cycles multiplied by (potentially) billions of users, and significantly degrades user experience.

Even Widevine L1* is ineffective in practice. Techniques to bypass it aren't available to the average Joe, but of course there are groups that will download, decrypt, and re-upload the newest 4K streaming releases to torrent trackers within an hour of them appearing on streaming services.

*edit: Mixed up L3 and L1

Re: Bypassing YouTube video download throttling

#82

I've never tried YouTube, but I have downloaded videos from sketchier streaming websites using the web developer tools. Almost all of them have the same protection: some code that triggers only when you open the tools and stops the video by creating a debugger statement you cannot skip and triggering some cpu-heavy code (probably an infinite loop, although I wouldn't discard cryptominers). More importantly this code…

[deleted]

Re: Bypassing YouTube video download throttling

#83
post #20

Earlier quoted context omitted.

Technically, everyone pays for connecting to the network. I wouldn't say it's unethical to slam YouTube with full speed downloads but at the same time I wouldn't judge YouTube if they take measures against it. I'm using a browser extension to show full size of images on social media when hover and Instagram went crazy about it, warning about unusual activities and threatening to lock my account. I looked into it to s…

> I'm using a browser extension to show full size of images on social media when hover and Instagram went crazy about it, warning about unusual activities and threatening to lock my account. I looked into it to see if the extension does any scrapping behind but no, it all seems fine. I've used such an extension and found dragging the curser over your screen might fire like 25 requests. You might simply be rate-limite…

Maybe, I just speculate over the reason of course but I haven't noticed anything strange like that. That said, the pattern of requests from the client should be obvious to the backend, the preventive measures can be designed around it and the rate Is one of the obvious signals.

Removed the extension anyway

Re: Bypassing YouTube video download throttling

#84

On a sidenote am I imagining things or do videos actually look a tiny bit better in YouTube? This really has puzzled me. I downloaded a few favourites and watch them on VLC or Infuse on my AppleTV. In the YouTube app I can use the "nerd stats" to confirm I am viewing the exact same video/audio streams... ... it could be my imagination but it seems like YouTube does a really subtle kind of filter that makes the "block…

I can answer about the audio.

YouTube (and most other streaming sites like Spotify etc) use something called ReplayGain. It's essentially a tag that specifies the calculated average loudness of the video/song/whatever (this number is calculated at upload time).

Upon playback, the official YT client knows to use that tag and adjust its volume level accordingly, but I'd imagine either the tag isn't getting downloaded, or perhaps MKV doesn't support ReplayGain tags natively.

Re: Bypassing YouTube video download throttling

#85
post #74

I've never tried YouTube, but I have downloaded videos from sketchier streaming websites using the web developer tools. Almost all of them have the same protection: some code that triggers only when you open the tools and stops the video by creating a debugger statement you cannot skip and triggering some cpu-heavy code (probably an infinite loop, although I wouldn't discard cryptominers). More importantly this code…

>Almost all of them have the same protection: some code that triggers only when you open the tools and stops the video by creating a debugger statement you cannot skip If you missed it, not so long ago there was a submission that evaded exactly this. Their solution is so simple yet effective: Recompiling the browser with the debugger keyword renamed. Made me smile. https://news.ycombinator.com/item?id=36961445

Honestly recompilation shouldn't even be necessary, browsers should just let us disable the debugger statement when "clever" sites start taking advantage of it. This usage of debuggers to circumvent our tools is abuse and should be literally impossible unless we consent to it.

Our computers are our realms. God giveth and god taketh away.

Re: Bypassing YouTube video download throttling

#86

I've never tried YouTube, but I have downloaded videos from sketchier streaming websites using the web developer tools. Almost all of them have the same protection: some code that triggers only when you open the tools and stops the video by creating a debugger statement you cannot skip and triggering some cpu-heavy code (probably an infinite loop, although I wouldn't discard cryptominers). More importantly this code…

Try Anti-Anti-Debug [0]. It's a simple extension to bypass those kinds of anti-debugging techniques. Made it in a few hours a while ago for similar reasons.

0: https://chrome.google.com/webstore/detail/anti-anti-debug/mn...

Re: Bypassing YouTube video download throttling

#87

Earlier quoted context omitted.

Well, you go away unless you're another organization that proposes to mirror all of YouTube and eat its lunch. Google can't only think about humans, it's got to also think about competing organizations. That complicates things.

that's their problem to deal with. why is everyone here going all 'think of the poor corporations'

I think you're reading it as "as a user, you must not do this because...", when the GP meant it as "as Google, the reason I'm doing this is because..."

Re: Bypassing YouTube video download throttling

#88

On a sidenote am I imagining things or do videos actually look a tiny bit better in YouTube? This really has puzzled me. I downloaded a few favourites and watch them on VLC or Infuse on my AppleTV. In the YouTube app I can use the "nerd stats" to confirm I am viewing the exact same video/audio streams... ... it could be my imagination but it seems like YouTube does a really subtle kind of filter that makes the "block…

Doesn't youtube ultimately use the browser's video player now that flash is no more?

In addition to what the other poster said about checking if you're downloading the exact same codec etc as you're watching, you could try playing the downloaded video with the browser and see what it looks like.

Re: Bypassing YouTube video download throttling

#89
> To bypass this limitation, we can break the download into several smaller parts using the HTTP Range header. This header allows you to specify which part of the file you want to download with each request (eg: Range bytes=2000-3000). The following code implements this logic.

Last time I read discussion about it in yt-dlp repo [1], you can actually bypass it by just adding range=xxx query parameter (not header), and it will return to full speed even if your range is just the whole thing.

And IIRC YouTube have already lifted this restriction.

Edit: find the ref [1] https://github.com/yt-dlp/yt-dlp/issues/6400

Re: Bypassing YouTube video download throttling

#90
post #24

Earlier quoted context omitted.

The only real thing they could try to do is to try enforcing video/IP speed cap. They probably don't due to false positives - for example people jumping around a long video also make may "range" requests. And the other approach is currently in progress - soon logged users won't be able to view videos without watching(or at least displaying/downloading) adds, so the logical next step is to nerf anonymous(as is without…

There’s plenty they could do. They could flip a switch tomorrow and limit access to only signed-in users, and they could further enable DRM, as pretty much by now the majority of users are already on DRM-handicapped platforms. Any will-be-called "legacy" users would just get limited to 480p.

So suddenly thousands (millions?) of users are unable to view content on YouTube?

Sounds pretty bad for ad-revenue....

Post reply on HN