Skip to content

Commit f1d3ab9

Browse files
committed
Bug 1972830 - [marionette] Add support to interact with CHIPS cookies - r=anti-tracking-reviewers,webdriver-reviewers,timhuang,Sasha
Differential Revision: https://phabricator.services.mozilla.com/D254249 UltraBlame original commit: 38d3dab5d8c8f0b3adfea3cc94a8cf7567da2071
1 parent 03bdb11 commit f1d3ab9

File tree

5 files changed

+94
-81
lines changed

5 files changed

+94
-81
lines changed

remote/marionette/cookie.sys.mjs

Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1735,6 +1735,36 @@ for
17351735
*
17361736
param
17371737
{
1738+
BrowsingContext
1739+
=
1740+
}
1741+
[
1742+
browsingContext
1743+
=
1744+
undefined
1745+
]
1746+
browsingContext
1747+
*
1748+
The
1749+
BrowsingContext
1750+
that
1751+
is
1752+
reading
1753+
these
1754+
cookies
1755+
.
1756+
*
1757+
Used
1758+
to
1759+
get
1760+
the
1761+
correct
1762+
partitioned
1763+
cookies
1764+
.
1765+
*
1766+
param
1767+
{
17381768
string
17391769
=
17401770
}
@@ -1793,6 +1823,9 @@ function
17931823
*
17941824
(
17951825
host
1826+
browsingContext
1827+
=
1828+
undefined
17961829
currentPath
17971830
=
17981831
"
@@ -1875,6 +1908,52 @@ host
18751908
}
18761909
)
18771910
;
1911+
if
1912+
(
1913+
browsingContext
1914+
)
1915+
{
1916+
let
1917+
partitionedOriginAttributes
1918+
=
1919+
{
1920+
partitionKey
1921+
:
1922+
browsingContext
1923+
.
1924+
currentWindowGlobal
1925+
?
1926+
.
1927+
cookieJarSettings
1928+
?
1929+
.
1930+
partitionKey
1931+
}
1932+
;
1933+
let
1934+
cookiesPartitioned
1935+
=
1936+
cookie
1937+
.
1938+
manager
1939+
.
1940+
getCookiesFromHost
1941+
(
1942+
host
1943+
partitionedOriginAttributes
1944+
)
1945+
;
1946+
cookies
1947+
.
1948+
push
1949+
(
1950+
.
1951+
.
1952+
.
1953+
cookiesPartitioned
1954+
)
1955+
;
1956+
}
18781957
for
18791958
(
18801959
let

remote/marionette/driver.sys.mjs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16718,6 +16718,11 @@ cookie
1671816718
iter
1671916719
(
1672016720
hostname
16721+
this
16722+
.
16723+
getBrowsingContext
16724+
(
16725+
)
1672116726
pathname
1672216727
)
1672316728
]
@@ -16851,6 +16856,11 @@ cookie
1685116856
iter
1685216857
(
1685316858
hostname
16859+
this
16860+
.
16861+
getBrowsingContext
16862+
(
16863+
)
1685416864
pathname
1685516865
)
1685616866
)
@@ -17026,6 +17036,11 @@ cookie
1702617036
iter
1702717037
(
1702817038
hostname
17039+
this
17040+
.
17041+
getBrowsingContext
17042+
(
17043+
)
1702917044
pathname
1703017045
)
1703117046
)

testing/web-platform/meta/cookies/partitioned-cookies/partitioned-cookies-samesite-attribute.https.html.ini

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -13,54 +13,6 @@ html
1313
]
1414
[
1515
In
16-
top
17-
-
18-
level
19-
contexts
20-
partitioned
21-
cookies
22-
default
23-
to
24-
the
25-
same
26-
SameSite
27-
attribute
28-
as
29-
unpartitioned
30-
cookies
31-
.
32-
]
33-
expected
34-
:
35-
if
36-
nightly_build
37-
:
38-
FAIL
39-
[
40-
In
41-
top
42-
-
43-
level
44-
contexts
45-
partitioned
46-
cookies
47-
can
48-
be
49-
set
50-
with
51-
all
52-
SameSite
53-
attributes
54-
.
55-
]
56-
expected
57-
:
58-
if
59-
nightly_build
60-
:
61-
FAIL
62-
[
63-
In
6416
embedded
6517
cross
6618
-

testing/web-platform/meta/infrastructure/testdriver/get_all_cookies.sub.https.html.ini

Lines changed: 0 additions & 21 deletions
This file was deleted.

testing/web-platform/meta/infrastructure/testdriver/get_named_cookie.sub.https.html.ini

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,3 @@ fission
2525
OK
2626
TIMEOUT
2727
]
28-
[
29-
Get
30-
Named
31-
HTTPS
32-
cookie
33-
]
34-
expected
35-
:
36-
if
37-
nightly_build
38-
:
39-
FAIL

0 commit comments

Comments
 (0)