{"id":445,"date":"2012-07-20T12:11:11","date_gmt":"2012-07-20T16:11:11","guid":{"rendered":"http:\/\/jclark.org\/weblog\/?p=445"},"modified":"2012-07-21T11:35:03","modified_gmt":"2012-07-21T15:35:03","slug":"google-chrome-does-not-honor-cookie-blocking-for-youtube-com","status":"publish","type":"post","link":"https:\/\/jclark.org\/weblog\/2012\/07\/20\/google-chrome-does-not-honor-cookie-blocking-for-youtube-com\/","title":{"rendered":"Google Chrome does not honor Cookie Blocking for Youtube.com"},"content":{"rendered":"<p><strong>UPDATE:<\/strong> Chrome <strong>will<\/strong> correctly block youtube (and other cookies).  Thanks to <a href=\"https:\/\/mikewest.org\">Mike West<\/a> at Google for taking the time to leave a comment outlining the fix.  The crux of the issue is that a literal pattern like I was using ( <code>youtube.com<\/code> ) will only match the literal domain &#8220;youtube.com&#8221;.  To match all sub-domains, you need to use a wildcard, although the syntax is non-obvious (to me).  The correct pattern is <code>[*.]youtube.com<\/code>.  Interestingly, if you try to use <code>*.youtube.com<\/code>, the field turns red and you cannot save the pattern, which is what led me to try <code>youtube.com<\/code>.  I have also updated my article on <a href=\"http:\/\/jclark.org\/weblog\/2011\/10\/23\/howto-prevent-youtube-from-tracking-your-gmail-credentials\/\">HOWTO prevent youtube from tracking your gmail-credentials<\/a>.<\/p>\n<p>Here&#8217;s the original post:<\/p>\n<hr \/>\n<p>A few (wow, 10?) months ago, I posted <a href=\"http:\/\/jclark.org\/weblog\/2011\/10\/23\/howto-prevent-youtube-from-tracking-your-gmail-credentials\/\">instructions for preventing youtube from tracking your gmail credentials<\/a>, which amounts to blocking youtube from setting cookies in your browser, and removing any existing youtube cookies.  However, I&#8217;ve noticed that every so often, youtube once again identifies me by my GMail account, and I have to clear the cookies again, even though I am still blocking all cookies matching &#8220;youtube.com&#8221;.<\/p>\n<p>I finally decided to investigate, and it appears that Chrome is not honoring my blocked cookies settings at all.  Clear all cookies prevents youtube from identifying my GMail account, until I click on a youtube link in an email in GMail, and then the cookie is set and I&#8217;m identified until I clear it (don&#8217;t log out of youtube, you will be logged out of GMail too).  For reference, my Chrome version is currently 20.0.1132.57, and is &#8220;Up to date&#8221; as of this writing, but I have been having this issue for some time.<\/p>\n<p>Steps to reproduce:<\/p>\n<ol start=\"0\">\n<li>Close any open windows\/tabs for youtube.com<\/li>\n<li>Open Settings, Advanced Settings; under Privacy click &#8220;Content Settings&#8230;&#8221;<\/li>\n<li>Click &#8220;Content Settings&#8230;&#8221;<\/li>\n<li>Under Cookies make sure the &#8220;allow local data to be set (recommended)&#8221; is selected.<\/li>\n<li>Click &#8220;Manage exceptions&#8230;&#8221;<\/li>\n<li>in the box &#8220;Add a new hostname pattern&#8221;, enter &#8220;youtube.com&#8221; (without quotes); set the behavior dropdown to &#8220;block&#8221;, and click ok.<\/li>\n<li>You are returned to the Content Settings dialog; click &#8220;All cookies and site data&#8230;&#8221;<\/li>\n<li>in the &#8220;Search Cookies&#8221; box (top right), type &#8220;youtube&#8221; (no quotes).<\/li>\n<li>If the list contains any cookies, click &#8220;Remove all&#8221;.<\/li>\n<li>Close the cookie dialog, content settings dialog, and the settings tab.<\/li>\n<li>Navigate to youtube.com<\/li>\n<li>Return to settings, advanced settings, content settings, All cookies and site data<\/li>\n<li>Search again for &#8220;youtube&#8221; (no quotes).  You will see cookies from youtube.  If you return to youtube and watch some videos, and then search again, you will have more cookies, plus &#8220;local storage&#8221;.<\/li>\n<\/ol>\n<p>Just because youtube is a google property is no reason for Chrome to not honor my cookie settings.  I don&#8217;t know if that is the case; I don&#8217;t know if Chrome ignores all cookie blocking settings, but this is a case I discovered and can reproduce.  I submitted a bug report (essentially the same as this post) via Chrome&#8217;s &#8220;report an issue&#8221; feature.  We&#8217;ll see if it gets addressed; I&#8217;ll post an update if I hear directly from Google.<\/p>","protected":false},"excerpt":{"rendered":"<p>UPDATE: Chrome will correctly block youtube (and other cookies). Thanks to Mike West at Google for taking the time to leave a comment outlining the fix. The crux of the issue is that a literal pattern like I was using ( youtube.com ) will only match the literal domain &#8220;youtube.com&#8221;. To match all sub-domains, you [&hellip;]<\/p>","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-445","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/posts\/445","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/comments?post=445"}],"version-history":[{"count":7,"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/posts\/445\/revisions"}],"predecessor-version":[{"id":451,"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/posts\/445\/revisions\/451"}],"wp:attachment":[{"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/media?parent=445"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/categories?post=445"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jclark.org\/weblog\/wp-json\/wp\/v2\/tags?post=445"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}