[webkit-changes] [WebKit/WebKit] aa9159: Allow expressing more flavors of third-party cooki...

Commit Queue noreply at github.com
Thu Oct 10 18:39:28 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: aa91591c0d60288edd11cdfa21d0ea423519b1a5
      https://github.com/WebKit/WebKit/commit/aa91591c0d60288edd11cdfa21d0ea423519b1a5
  Author: Matthew Finkel <m_finkel at apple.com>
  Date:   2024-10-10 (Thu, 10 Oct 2024)

  Changed paths:
    M Source/WebCore/platform/network/NetworkStorageSession.cpp
    M Source/WebCore/platform/network/NetworkStorageSession.h
    M Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm

  Log Message:
  -----------
  Allow expressing more flavors of third-party cookie blocking
https://bugs.webkit.org/show_bug.cgi?id=281022
rdar://problem/137464465

Reviewed by Sihui Liu.

Use an enum instead of a boolean value to describe the current third-party
cookie blocking behavior. Currently, we only support unpartitioned third-party
cookies and they are either allowed or denied. In the future we will support
partitioned third-party cookies, and we will need a tri-state to describe which
kind is allowed: allow unpartitioned and partitioned, allow only partitioned,
deny all third-party cookies.

This patch introduces an enum that describes these three states and uses it
where we currently make decisions about whether third-party cookies are
blocked.

Covered by existing tests.

* Source/WebCore/platform/network/NetworkStorageSession.cpp:
(WebCore::NetworkStorageSession::thirdPartyCookieBlockingDecisionForRequest const):
(WebCore::NetworkStorageSession::shouldBlockCookies const):
(WebCore::NetworkStorageSession::cookiesEnabled const):
* Source/WebCore/platform/network/NetworkStorageSession.h:
* Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
(WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):

Canonical link: https://commits.webkit.org/285001@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list