New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[YouTube] Tier 2 age-gate bypass implementation #575
Conversation
An update of the current situation for reference: There are 3 tiers of age-gate
tier 3 videos did not used to work with the old There doesn't seem to be any video that works in embed workaround but fails using this new method. So embed-workaround is mostly redundant rn and is kept around only in case this method breaks There are also some non-agegated videos like Edit: |
It looks like it may depend on your location. |
thanks
You are using ouath though? |
exactly. we are talking about unauthenticated access - like I told you before in the other post |
Hello, I have been monitoring this pull request and fork, and I have not yet had a chance to test it. But I will ASAP. @89z I think it is clear that you can download any video, age-gated or not, with a valid login cookie file (or OAuth). youtube-dl even lets you pass in a cookie file that you can read from and write to, via:
The challenge is to avoid authentication, if possible. (I.e., avoid generating and maintaining a login cookie file.) The need for authentication introduces additional problems/challenges in some use cases (at least, it does for me) -- so it is worth exploring an alternative that accommodates anonymous access. At the end of the day, if there is no practical solution to download all or at least the majority of age-gated videos without auth, then so be it -- I will resort to using authentication. |
For a more complete (and arguably less messy) overview of the situation, here are the age-gate tiers turned to embedding tiers:
EDIT: Swapped tier 2 and 3 |
* This allows more videos like `tf2U5Vyj0oU` to become embeddable See #575 (comment) * Also added tests for all types of age-gate Closes #581
* 'master' of https://github.com/yt-dlp/yt-dlp: [adobepass] Add MSO Sling TV (#596) [RCTIPlus] Remove PhantomJS dependency (#595) [youtube] Misc cleanup (#577) [youtube] Add `thirdParty` to agegate clients (#577) * This allows more videos like `tf2U5Vyj0oU` to become embeddable See yt-dlp/yt-dlp#575 (comment) * Also added tests for all types of age-gate [youtube] simplify and de-duplicate client definitions (#577) [youtube] Improve age-gate detection (#577) [youtube] Force `hl=en` for comments (#594)
* Calling the API with `clientScreen=EMBED` allows access to most age-gated videos - discovered by @ccdffddfddfdsfedeee (yt-dlp#574 (comment)) * Adds clients: (web/android/ios)_(embedded/agegate), mweb_embedded * Renamed mobile_web to mweb Closes yt-dlp#574 Authored by pukkandan, MinePlayersPE
* This allows more videos like `tf2U5Vyj0oU` to become embeddable See yt-dlp#575 (comment) * Also added tests for all types of age-gate Closes yt-dlp#581
Please follow the guide below
x
into all the boxes [ ] relevant to your pull request (like that [x])Before submitting a pull request make sure you have:
In order to be accepted and merged into youtube-dl each piece of code must be in public domain or released under Unlicense. Check one of the following options:
What is the purpose of your pull request?
Description of your pull request and other information
Explanation of your pull request in arbitrary form goes here. Please make sure the description explains the purpose and effect of your pull request and is worded well enough to be understood. Provide as much context and examples as possible.
Implements #574 (comment) (tier-2 age-gate bypass).