Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How are YouTube and Google accessing each others cookies?

Tags:

http

cookies

A lot of researching on stackoverflow told me that getting/setting cookies from other domains isn't possible.

but I can see youtube.com is doing that with google.com enter image description here

How are they doing that then?

like image 510
user3571278 Avatar asked Jun 04 '15 07:06

user3571278


People also ask

How are cookies used on YouTube?

Cookies are files created by sites you visit. They make your online experience easier by saving browsing data. The cache remembers parts of pages, like images, to help them open faster during your next visit.

Does YouTube use tracking cookies?

YouTube by default sets a tracking cookie for marketing purposes. In other words, when you embed a video, you are inviting third-party cookies onto your site.

Are cookies shared between accounts?

Cookies are set on a per-user basis only.

Do cookies get shared between browsers?

Cookies are per-browser, but plugins (such as Flash) have their own storage and can be used to share information between browsers.


1 Answers

Your first statement is correct - it is not possible to get/set cookies from other domains.

That list of cookies shows what was set when you viewed the page, but you must remember that the page includes resources from different locations (images and scripts). When a script or an image is pulled from a different server, it has the opportunity to set a cookie as well. Although the page on youtube.com caused all of those cookies to be set, it only has access to the ones actually on youtube.com.

like image 76
Richard Avatar answered Nov 15 '22 06:11

Richard