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

/player Google Videos 403 Which Causes The FFMPEG Issue [Fix Included!] #228

Open
erievs opened this issue Sep 18, 2024 · 5 comments
Open

Comments

@erievs
Copy link

erievs commented Sep 18, 2024

I have a fork in which it is fixed, https://github.com/erievs/FourthTube

But here is the fix

How The Fix Works

So how ThirdTube works is it uses a decrypter and some base.js tomfoolery to access /player (without 403ing).
The issue with this approach is, well, it breaks a lot. It was fine when the dev was active, but the dev has not.

However

We don't need that, we just need to send IOS YouTube app data, and it makes it happy (this is one of the methods YT-DLP uses)

std::string video_content = R"({"videoId": "%0", %1"context": {"client": {"hl": "%2","gl": "%3","clientName": "IOS","clientVersion": "19.29.1","deviceMake": "Apple","deviceModel": "19.29.1","osName": "iPhone","userAgent": "com.google.ios.youtube/19.29.1 (iPhone16,2; U; CPU iOS 17_5_1 like Mac OS X;)\"","osVersion": "17.5.1.21F90"}}, "playbackContext": {"contentPlaybackContext": {"signatureTimestamp": %4}}})";

Issue

This causes the metadata to breaks, thankfully we just have a separate post_content and video_content strings and use both for

 std::string json_str[2]; // {/next, /player}
        json_str[0] = http_post_json(urls[0], post_content).second;
        json_str[1] = http_post_json(urls[1], video_content).second;   /
@reallylonglogholyshit
Copy link

Absolute legend

@kernaltrap8
Copy link

THE GOAT

@nerfr
Copy link

nerfr commented Sep 26, 2024

made a github acc just to say thank you

@cyrill-oss
Copy link

Thank you so much ♪⁠┌⁠|⁠∵⁠|⁠┘⁠♪

@SuperLavaHair1
Copy link

nice

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

7 participants
@erievs @reallylonglogholyshit @cyrill-oss @kernaltrap8 @SuperLavaHair1 @nerfr and others