Name Description Size
__init__.py 0
cookie-helper.sub.js 12154
cookie-test.js 7473
cookie.py Helper method to add a Set-Cookie header 1728
drop.py Respond to `/cookie/drop?name={name}` by expiring the cookie named `{name}`. 673
dropSameSite.py Respond to `/cookie/same-site/resources/dropSameSite.py by dropping the four cookies set by setSameSiteCookies.py 651
dropSameSiteMultiAttribute.py Respond to `/cookies/resources/dropSameSiteMultiAttribute.py by dropping the cookies set by setSameSiteMultiAttribute.py 969
dropSameSiteNone.py Respond to `/cookies/resources/dropSameSiteNone.py by dropping the two cookies set by setSameSiteNone.py 529
dropSecure.py Respond to `/cookie/drop/secure` by dropping the two cookie set by `setSecureTestCookies()` 501
echo-cookie.html helper iframe for matching cookie path tests 1105
echo-json.py 562
helpers.py Set Cache-Control, CORS and Content-Type headers appropriate for the cookie tests. 2203
imgIfMatch.py Respond to `/cookie/imgIfMatch?name={name}&value={value}` with a 404 if the cookie isn't present, and a transparent GIF otherwise. 1065
list-cookies-for-script.py 524
list.py 386
navigate.html 254
postToParent.py <!DOCTYPE html> <script> var data = %s; data.type = "COOKIES"; try { data.domcookies = document.cookie; } catch (e) {} if (window.parent != window) { window.parent.postMessage(data, "*"); if (window.top != window.parent) window.top.postMessage(data, "*"); } if (window.opener) window.opener.postMessage(data, "*"); window.addEventListener("message", e => { console.log(e); if (e.data == "reload") window.location.reload(); }); </script> 977
redirectWithCORSHeaders.py Simple handler that causes redirection. The request should typically have two query parameters: status - The status to use for the redirection. Defaults to 302. location - The resource to redirect to. 667
set-cookie.py Returns cookie name and path from query params in a Set-Cookie header. e.g. > GET /cookies/resources/set-cookie.py?name=match-slash&path=%2F HTTP/1.1 > Host: localhost:8000 > User-Agent: curl/7.43.0 > Accept: */* > < HTTP/1.1 200 OK < Content-Type: application/json < Set-Cookie: match-slash=1; Path=/; Expires=09 Jun 2021 10:18:14 GMT < Server: BaseHTTP/0.3 Python/2.7.12 < Date: Tue, 04 Oct 2016 18:16:06 GMT < Content-Length: 80 1368
set.py Respond to `/cookie/set?{cookie}` by echoing `{cookie}` as a `Set-Cookie` header. 574
setSameSite.py Respond to `/cookie/set/samesite?{value}` by setting four cookies: 1. `samesite_strict={value};SameSite=Strict;path=/` 2. `samesite_lax={value};SameSite=Lax;path=/` 3. `samesite_none={value};SameSite=None;path=/` 4. `samesite_unspecified={value};path=/` Then navigate to a page that will post a message back to the opener with the set cookies 1555
setSameSiteDomain.py Respond to `/cookie/set/samesite?{value}` by setting four cookies: 1. `samesite_strict={value};SameSite=Strict;path=/;domain={host}` 2. `samesite_lax={value};SameSite=Lax;path=/;domain={host}` 3. `samesite_none={value};SameSite=None;path=/;Secure;domain={host}` 4. `samesite_unspecified={value};path=/;domain={host}` Where {host} is the hostname from which this page is served. (Requesting this resource without a Host header will result in a 500 server error.) Then navigate to a page that will post a message back to the opener with the set cookies 1957
setSameSiteMultiAttribute.py Respond to `/cookie/set/samesite?{value}` by setting the following combination of cookies: 1. `samesite_unsupported={value};SameSite=Unsupported;path=/;Secure` 2. `samesite_unsupported_none={value};SameSite=Unsupported;SameSite=None;path=/;Secure` 3. `samesite_unsupported_lax={value};SameSite=Unsupported;SameSite=Lax;path=/` 4. `samesite_unsupported_strict={value};SameSite=Unsupported;SameSite=Strict;path=/` 5. `samesite_none_unsupported={value};SameSite=None;SameSite=Unsupported;path=/;Secure` 6. `samesite_lax_unsupported={value};SameSite=Lax;SameSite=Unsupported;path=/;Secure` 7. `samesite_strict_unsupported={value};SameSite=Strict;SameSite=Unsupported;path=/;Secure` 8. `samesite_lax_none={value};SameSite=Lax;SameSite=None;path=/;Secure` 9. `samesite_lax_strict={value};SameSite=Lax;SameSite=Strict;path=/` 10. `samesite_strict_lax={value};SameSite=Strict;SameSite=Lax;path=/` Then navigate to a page that will post a message back to the opener with the set cookies 3460
setSameSiteNone.py Respond to `/cookies/resources/setSameSiteNone.py?{value}` by setting two cookies: 1. `samesite_none_insecure={value};SameSite=None;path=/` 2. `samesite_none_secure={value};SameSite=None;Secure;path=/` 767
setSecure.py Respond to `/cookie/set/secure?{value}` by setting two cookies: alone_secure={value};secure;path=/` alone_insecure={value};path=/ 649
testharness-helpers.js 1207