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

Fix handling of cookies for absolute domains #50

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

chrisliebaer
Copy link
Contributor

@chrisliebaer chrisliebaer commented Nov 26, 2024

As mentioned in #42, other extensions might introduce additional cookies into the youtube.com cookie space. There appears to be a difference between cookies which are readable from subdomains and cookies which can only be read from the domain that set it. The actual cookies set by YouTube all include subdomains, but the one set by Cookie AutoDelete does not.

This causes the Python cookie file loader to fail, since it expects domains starting with a dot to match the subdomain flag (2nd flag in cookie file): https://github.com/python/cpython/blob/f46d8475749a0eadbc1f37079906a8e1ed5d56dc/Lib/http/cookiejar.py#L2050-L2051

I couldn't figure out, which exact format is represented here, but this commit fixes the browser plugin to respect the wishes of the underlying Python cookie jar.

Closes #42

@bbilly1
Copy link
Member

bbilly1 commented Jan 28, 2025

Sorry for the delay, thanks for looking into this.

@bbilly1 bbilly1 merged commit ea12e6b into tubearchivist:master Jan 28, 2025
1 check passed
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

Successfully merging this pull request may close these issues.

Extension includes cookies from other extensions unrelated to youtube
2 participants