← All tests

What this tests

This page tries to set and immediately read back a cookie in two contexts:

  1. The top-level page.
  2. A dynamically created about:blank iframe with inherited origin.

Because the frame inherits the parent origin, a browser that blocks cookies for this site should block both attempts equally.

To test cookie blocking: run the test once with cookies enabled, then disable cookies for this site or the top-level page, reload, and run it again. If the top-level write fails but the about:blank frame still stores its cookie, the cookie policy is not propagating correctly into the frame.

Environment

Origin:

navigator.cookieEnabled:

Frame output

Expected results

Scenario Top-level page about:blank frame Verdict
Cookies allowed Sets cookie Sets cookie Expected
Cookies disabled (protected) Fails Fails Pass — cookie policy propagates to about:blank
Cookies disabled (vulnerable) Fails Sets cookie Fail — about:blank bypasses cookie blocking