From 4264e50e8a9985f20289ae5790660b49e2cb219a Mon Sep 17 00:00:00 2001 From: Lilith Date: Sun, 30 Mar 2025 13:37:09 -0400 Subject: [PATCH] Fix cookie validation error Closes #259 by changing cookie validation to check all cookies, instead of only cookies from `https://patreon.com/`. This should be future-proof as well, in the event that Patreon further changes their cookies to use other domains. --- PatreonDownloader.Implementation/PatreonCookieValidator.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PatreonDownloader.Implementation/PatreonCookieValidator.cs b/PatreonDownloader.Implementation/PatreonCookieValidator.cs index 00d8f63..05e3fa8 100644 --- a/PatreonDownloader.Implementation/PatreonCookieValidator.cs +++ b/PatreonDownloader.Implementation/PatreonCookieValidator.cs @@ -26,7 +26,7 @@ public async Task ValidateCookies(CookieContainer cookieContainer) if (cookieContainer == null) throw new ArgumentNullException(nameof(cookieContainer)); - CookieCollection cookies = cookieContainer.GetCookies(new Uri("https://patreon.com")); + CookieCollection cookies = cookieContainer.GetAllCookies(); if (cookies["__cf_bm"] == null) throw new CookieValidationException("__cf_bm cookie not found");