Readit News logoReadit News
Andrews54757 commented on Yt-dlp: Upcoming new requirements for YouTube downloads   github.com/yt-dlp/yt-dlp/... · Posted by u/phewlink
dylan604 · 3 months ago
> For the web it requires that you run a snippet of javascript code (the challenge) in the browser to prove that you are not a bot.

How does this prove you are not a bot. How does this code not work in a headless Chromimum if it's just client side JS?

Andrews54757 · 3 months ago
Good question! Indeed you can run the challenge code using headless Chromium and it will function [1]. They are constantly updating the challenge however, and may add additional checks in the future. I suppose Google wants to make it more expensive overall to scrape Youtube to deter the most egregious bots.

[1] https://github.com/LuanRT/BgUtils

Andrews54757 commented on Yt-dlp: Upcoming new requirements for YouTube downloads   github.com/yt-dlp/yt-dlp/... · Posted by u/phewlink
Andrews54757 · 3 months ago
Nsig/sig - Special tokens which must be passed to API calls, generated by code in base.js (player code). This is what has broken for yt-dlp and other third party clients. Instead of extracting the code that generates those tokens (eg using regular expressions) like we used to, we now need to run the whole base.js player code to get these tokens because the code is spread out all over the player code.

PoToken - Proof of origin token which Google has lately been enforcing for all clients, or video requests will fail with a 403. On android it uses DroidGuard, for IOS, it uses built in app integrity apis. For the web it requires that you run a snippet of javascript code (the challenge) in the browser to prove that you are not a bot. Previously, you needed an external tool to generate these PoTokens but with the Deno change yt-dlp should be capable of producing these tokens by itself in the near future.

SABR - Server side adaptive bitrate streaming, used alongside Google's UMP protocol to allow the server to have more control over buffering, given data from the client about the current playback position, buffered ranges, and more. This technology is also used to do server-side ad injection. Work is still being done to make 3rd party clients work with this technology (sometimes works, sometimes doesn't).

Nsig/sig extraction example:

- https://github.com/yt-dlp/yt-dlp/blob/4429fd0450a3fbd5e89573...

- https://github.com/yt-dlp/yt-dlp/blob/4429fd0450a3fbd5e89573...

PoToken generation:

- https://github.com/yt-dlp/yt-dlp/wiki/PO-Token-Guide

- https://github.com/LuanRT/BgUtils

SABR:

- https://github.com/LuanRT/googlevideo

EDIT2: Addeded more links to specific code examples/guides

Andrews54757 commented on The Neverending Story   garrettdimon.com/journal/... · Posted by u/sathishmanohar
Andrews54757 · a year ago
In sticking to vanilla HTML/CSS/Javascript for my hobby projects over the past ten years, I've come to enjoy writing "simple" code with minimal dependencies and bare-bones interfaces. I believe that the skills I've learned in doing so has benefited me many times since then, especially during the times when I needed a specific tool, ASAP, for my job as a biomedical researcher. Without having the need to look up documentation, tease apart the workings of frameworks, I've been able to make hyper-specific web based guis for image labeling and more, sometimes quicker and better than the programmers hired for these jobs, who would otherwise need constant communication and supervision to ensure that the correct thing is built.
Andrews54757 commented on Google pulls the plug on uBlock Origin   windowscentral.com/softwa... · Posted by u/SMAAART
Andrews54757 · a year ago
A while back I installed uBlock on my grandparents' computer to help them avoid scammy ads. This change will make it more difficult and dangerous, for elderly users to browse the internet. As a young nerd, I can switch to Firefox easily, but I can't imagine it will be easy for everyone. My experience from using Firefox is that it has its own quirks, and comes with its own learning curve.

I don't know what to say but to encourage everyone to make some noise. Please let your representative know about this. Hopefully we can still put a stop to this before it's too late.

Andrews54757 commented on Four billion years in four minutes – Simulating worlds on the GPU   davidar.io/post/sim-glsl... · Posted by u/diggan
Waterluvian · a year ago
I’m not sure I really know how to handle this. Do I just read the latest version linked at the top of the page? Or is the one offered by this like somehow more canonical or something? I’m not sure I’ve ever been faced with different versions of a fiction before. Just textbooks.

I really love thought pieces like this if you refrain from poking holes in the logic or physics. I love the idea of a multiverse where they’re all actually just identical so it’s mostly moot.

Andrews54757 · a year ago
I read both. They are both great but I like the original better. The new edition is accessible but I think the original's prose is beautiful.
Andrews54757 commented on Show HN: A video editing SDK that runs in the browser   rendley.com/... · Posted by u/bgrigore
Andrews54757 · a year ago
The "get in touch" button on blog.rendley.com leads to a 404 page: https://rendley.com/try-for-free
Andrews54757 commented on MeTube: Self-hosted YouTube downloader   github.com/alexta69/metub... · Posted by u/thunderbong
Andrews54757 · a year ago
It was pretty straightforward for me to install and use yt-dlp. On a Mac with Homebrew you can do `brew install yt-dlp` to install it in one command. IIRC yt-dlp also provides binaries you can install directly. I'm not sure if installing docker and running a web server is any way easier than that.

However, there are ways to download Youtube videos without installing a native app. For example, it is possible to use a library like Youtube.js [0] to make a browser extension that downloads Youtube videos directly. You won't find those on Google's web store due to policy, but you can find a handful on Github.

0: https://github.com/LuanRT/YouTube.js

Andrews54757 commented on Writing an MP4 Muxer for Fun and Profit   obsproject.com/blog/obs-s... · Posted by u/skrrtww
CrendKing · a year ago
Can someone explain how does an existing media player understand the new mdat format without modification? I assume if they find a completed moov at end of the file, it would recognize the file as a unfragmented mp4. It should then try to find a list of recognized codecs directly inside the mdat (like in the first picture), but instead they will find another moov, a bunch of moofs and sub-mdats, all of which are clearly not proper for a unfragmented mp4. Why doesn't the player report this as a "unrecognizable, badly formatted" mp4 file?
Andrews54757 · a year ago
The moov contains a list of byte offsets which the player can use to directly access media data. You can skip the moofs and other headers inside by using gaps in the offsets.
Andrews54757 commented on Writing an MP4 Muxer for Fun and Profit   obsproject.com/blog/obs-s... · Posted by u/skrrtww
Andrews54757 · a year ago
Having worked with some MP4 demuxing for my extension [1], I feel the pain. Lots of times I would play the video only to find inexplicable issues such as drifting audio. I highly recommend using an mp4 inspector tool, such as mp4box [2], to debug these issues.

1: https://github.com/Andrews54757/FastStream

2: https://gpac.github.io/mp4box.js/test/filereader.html

Andrews54757 commented on Who Killed the World?   pudding.cool/2024/07/scif... · Posted by u/surprisetalk
Andrews54757 · a year ago
Great article. I've always thought that pessimistic sci-fi dystopias were on the rise, but it turns out most still have positive endings. The observation about walking out of the theatre, and seeing the worst ahead of us is quite interesting.

It would be cool to compare with other, non sci-fi stories. EG: I have been noticing the rise of escapist fantasy narratives in popular media — wish fulfillment stories where a Mary Sue like main character rises above all challenges without struggle. You can see this particularly in light novels, manga, and anime in the now popularized "isekai", "cultivation", or "system progression" genres. It would be interesting to find out how the public's fascination with these types of stories correlate with economic, social, or political undulations in the real world.

u/Andrews54757

KarmaCake day304October 30, 2017View Original