Skip to content
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

Error:can't bypass age restriction: login required to confirm your age #343

Open
LaoJiuYes opened this issue Sep 3, 2024 · 6 comments
Open

Comments

@LaoJiuYes
Copy link

Hello everyone!
It used to work fine. Today I got an error message "can't bypass age restriction: login required to confirm your age". My network environment is Tokyo, Japan. Is there any law on age restriction in Japan in the past month (like Korea. Login verification is required)?
Has anyone encountered this problem? How did you solve it? Thank you.

@shoce
Copy link

shoce commented Sep 3, 2024

#336

@shoce
Copy link

shoce commented Sep 3, 2024

#336 (comment)

@LaoJiuYes
Copy link
Author

#336

Thanks for your reply.
I have tried many VPS. Still no use. I tried to access Google Scholar with these IPs and it was accessible. But I couldn't download. I was still using it last month, but it's not working this month.
I can only wait...

@gcottom
Copy link

gcottom commented Sep 13, 2024

To summarize what I've found in other threads among yt downloading applications and my own recent experiences, Google is blocking IPs. If you want to run a yt service on AWS, its a complete no go these days. I switched from running my personal service on AWS to local about a month ago. There appears to be multiple levels to the blocking that happens. On cloud services it seems to be a complete block. I've tested locally and found that you can do about 600 downloads in a row (one after another, continuously) before you incur a temporary block which can last anywhere from about 15 minutes to an hour. This can effectively kill your batch download unless you have a long running retry. Running 5 concurrent downloads at a time, you can get about 1k videos downloaded, however concurrency comes at the price of a longer ban. Since that ban was over a day, I came upon this thread which lead me to others. What I learned from the other threads was that:

  1. You should not pass cookies to youtube http client. Google does something with the cookies for every video and if the transforms don't match, you can get an account level ban.
  2. Google is banning IP addresses that download "too much". How much is too much? That's hard to tell. I'd say the days of downloading in bulk are over though, unless you can change your IP address on demand.
  3. IPv6 fingerprinting/tracking. On some systems IPv6 uses part of your MAC address as part of your IPv6 address. If you don't have IPv6 privacy extensions turned on, you may want to look into it. In my specific case, after changing my IPv6 address, and finding that the issue still persisted, I took drastic measures and changed the IPv6 settings on my Mac to Link-Local Only, effectively, turning IPv6 off as far as this computer and the internet are concerned. Why was the IP on my router not blocked? Now that, I don't know. It's possible that Google is using a form of IPv6 prefix hijacking to ensure you are banned for good. I will note that while I was banned from downloading, I was able to still stream from youtube and youtube music.
  4. The bans don't seem to completely block you from downloading, just hinder you. If you have an application that will relentlessly retry, you may still get through, even while banned. I say this because, while banned, I tried my 1000 video batch download, with a 3 retry for each video. While most failed, I did see a few of them that still managed to go through. So that's food for thought.

@LaoJiuYes
Copy link
Author

To summarize what I've found in other threads among yt downloading applications and my own recent experiences, Google is blocking IPs. If you want to run a yt service on AWS, its a complete no go these days. I switched from running my personal service on AWS to local about a month ago. There appears to be multiple levels to the blocking that happens. On cloud services it seems to be a complete block. I've tested locally and found that you can do about 600 downloads in a row (one after another, continuously) before you incur a temporary block which can last anywhere from about 15 minutes to an hour. This can effectively kill your batch download unless you have a long running retry. Running 5 concurrent downloads at a time, you can get about 1k videos downloaded, however concurrency comes at the price of a longer ban. Since that ban was over a day, I came upon this thread which lead me to others. What I learned from the other threads was that:

  1. You should not pass cookies to youtube http client. Google does something with the cookies for every video and if the transforms don't match, you can get an account level ban.
  2. Google is banning IP addresses that download "too much". How much is too much? That's hard to tell. I'd say the days of downloading in bulk are over though, unless you can change your IP address on demand.
  3. IPv6 fingerprinting/tracking. On some systems IPv6 uses part of your MAC address as part of your IPv6 address. If you don't have IPv6 privacy extensions turned on, you may want to look into it. In my specific case, after changing my IPv6 address, and finding that the issue still persisted, I took drastic measures and changed the IPv6 settings on my Mac to Link-Local Only, effectively, turning IPv6 off as far as this computer and the internet are concerned. Why was the IP on my router not blocked? Now that, I don't know. It's possible that Google is using a form of IPv6 prefix hijacking to ensure you are banned for good. I will note that while I was banned from downloading, I was able to still stream from youtube and youtube music.
  4. The bans don't seem to completely block you from downloading, just hinder you. If you have an application that will relentlessly retry, you may still get through, even while banned. I say this because, while banned, I tried my 1000 video batch download, with a 3 retry for each video. While most failed, I did see a few of them that still managed to go through. So that's food for thought.

Thanks for your reply, brother.
My IP is valid for all Google services, except downloading. I only download one video at a time, not in bulk, and I download about 3-4 videos a month. I will only download if I come across a particularly good work. I think what you said about Google's ban mechanism is correct. I came to the same conclusion after testing, because other services allow access, but only downloading is not allowed. Maybe Google has added its anti-download mechanism.

@ppalone
Copy link
Contributor

ppalone commented Nov 7, 2024

Has anyone found any workaround?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants