Commit 7d9798f1 authored by abarth@webkit.org's avatar abarth@webkit.org
Browse files

2010-03-03 Adam Barth <abarth@webkit.org>

        Reviewed by Darin Adler.

        Document cookieURL and firstPartyForCookies
        https://bugs.webkit.org/show_bug.cgi?id=35613

        Some folks asked what the cookieURL and the firstPartyForCookies were
        on IRC.  This patch documents these properties in the code so folks
        don't have to ask on IRC anymore.

        * dom/Document.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@55461 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent fc979642
2010-03-03 Adam Barth <abarth@webkit.org>
Reviewed by Darin Adler.
Document cookieURL and firstPartyForCookies
https://bugs.webkit.org/show_bug.cgi?id=35613
Some folks asked what the cookieURL and the firstPartyForCookies were
on IRC. This patch documents these properties in the code so folks
don't have to ask on IRC anymore.
* dom/Document.h:
2010-03-03 Arno Renevier <arno@renevier.net>
 
Reviewed by Gustavo Noronha Silva.
......
......@@ -714,8 +714,28 @@ public:
String lastModified() const;
// The cookieURL is used to query the cookie database for this document's
// cookies. For example, if the cookie URL is http://example.com, we'll
// use the non-Secure cookies for example.com when computing
// document.cookie.
//
// Q: How is the cookieURL different from the document's URL?
// A: The two URLs are the same almost all the time. However, if one
// document inherits the security context of another document, it
// inherits its cookieURL but not its URL.
//
const KURL& cookieURL() const { return m_cookieURL; }
// The firstPartyForCookies is used to compute whether this document
// appears in a "third-party" context for the purpose of third-party
// cookie blocking. The document is in a third-party context if the
// cookieURL and the firstPartyForCookies are from different hosts.
//
// Note: Some ports (including possibly Apple's) only consider the
// document in a third-party context if the cookieURL and the
// firstPartyForCookies have a different registry-controlled
// domain.
//
const KURL& firstPartyForCookies() const { return m_firstPartyForCookies; }
void setFirstPartyForCookies(const KURL& url) { m_firstPartyForCookies = url; }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment