Andrews54757
Joined 9 years ago
Joined 9 years ago
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
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.
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.
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.
1. Browser extension has a wildcard pattern for content script.
2. Content script passes postMessage messages to the background script using sendMessage.
3. Background script passes the message to native application using sendNativeMessage.
4. Native application handles the message dangerously, leading to code execution.
Requirement 2 seems to be the most important. postMessage messages should never be passed to sendMessage raw without validation. Fortunately, this should be a rare occurrence in the wild. It only provides very specific benefits to use postMessage in an extension to begin with, and developers who do need to use it are more likely to be aware of the potential vulnerability.
This and other inconveniences motivated me to make a browser extension to fix bad video players on the internet. It works by replacing the video player with a custom one. It also allows me to see what the manifest URL is and what headers it uses so I can copy it over to VLC if I need to.
The extension is available on Github, you can find it here
[1] https://github.com/LuanRT/BgUtils