Skip to content

Commit

Permalink
Rename COEP:{cors-or-credentialless => credentialless}
Browse files Browse the repository at this point in the history
This was discussed here:
whatwg/html#6637 (comment)

This patch renames "cors-or-credentialless" into "credentialless".

The WPT test directory:
- html/cross-origin-embedder-policy/credentialless/cors-or-credentialess/
- html/cross-origin-embedder-policy/credentialless/full-credentialless/
are renamed:
- html/cross-origin-embedder-policy/cors-or-credentialess/
- html/cross-origin-embedder-policy/anonymous-iframe/

Bug:1175099
Change-Id: Iba052a2b3fbf4b45607c48807622d5ced202d583
  • Loading branch information
ArthurSonzogni authored and chromium-wpt-export-bot committed May 5, 2021
1 parent e6ba4ef commit aee8ccf
Show file tree
Hide file tree
Showing 19 changed files with 43 additions and 46 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../credentialless/resources/common.js"></script>
<script src="../credentialless/resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script>

const same_origin = get_host_info().HTTPS_ORIGIN;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../credentialless/resources/common.js"></script>
<script src="../credentialless/resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script>

const same_origin = get_host_info().HTTPS_ORIGIN;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script>

const http = get_host_info().HTTP_ORIGIN;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
<!doctype html>
<title>CORS or Credentialless and dedicated worker</title>
<meta name="timeout" content="long">
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script>

const same_origin = get_host_info().HTTPS_ORIGIN;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script>

promise_test(async test => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script src="./resources/iframeTest.js"></script>

<script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script src="./resources/iframeTest.js"></script>

<script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script src="./resources/iframeTest.js"></script>

<script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>

<script>
const same_origin = get_host_info().HTTPS_ORIGIN;
Expand All @@ -13,14 +13,14 @@
const cookie_same_origin = "same_origin";
const cookie_cross_origin = "cross_origin";

// Operate on a window with COEP:cors-or-credentialless.
// Operate on a window with COEP:credentialless.
const w_token = token();
const w_url = same_origin + executor_path + coep_credentialless +
`&uuid=${w_token}`
const w = window.open(w_url);
add_completion_callback(() => w.close());

// Check whether COEP:cors-or-credentialless applies to navigation request. It
// Check whether COEP:credentialless applies to navigation request. It
// shouldn't.
const iframeTest = function(name, origin, expected_cookies) {
promise_test_parallel(async test => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>

<script>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>

<script>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>

<script>
const same_origin = get_host_info().HTTPS_ORIGIN;
Expand All @@ -13,7 +13,7 @@
const cookie_same_origin = "same_origin";
const cookie_cross_origin = "cross_origin";

// Operate on a window with COEP:cors-or-credentialless.
// Operate on a window with COEP:credentialless.:
const w_token = token();
const w_url = same_origin + executor_path + coep_credentialless +
`&uuid=${w_token}`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ const executor_js_path = directory + '/resources/executor.js?pipe=';
const coep_none =
'|header(Cross-Origin-Embedder-Policy,none)';
const coep_credentialless =
'|header(Cross-Origin-Embedder-Policy,cors-or-credentialless)';
'|header(Cross-Origin-Embedder-Policy,credentialless)';
const coep_require_corp =
'|header(Cross-Origin-Embedder-Policy,require-corp)';

// COEP-Report-Only
const coep_report_only_credentialless =
'|header(Cross-Origin-Embedder-Policy-Report-Only,cors-or-credentialless)';
'|header(Cross-Origin-Embedder-Policy-Report-Only,credentialless)';

// COOP
const coop_same_origin =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>

<script>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
<!doctype html>
<title>CORS or Credentialless and service worker</title>
<meta name="timeout" content="long">
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script>

const same_origin = get_host_info().HTTPS_ORIGIN;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
<!doctype html>
<title>CORS or Credentialless and Shared worker</title>
<meta name="timeout" content="long">
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>
<script>

const same_origin = get_host_info().HTTPS_ORIGIN;
Expand Down Expand Up @@ -76,9 +75,9 @@
}, `fetch ${description}`)
};

// TODO(https://crbug.com/1200233). A COEP:cors-or-credentialless document
// shouldn't be able to load COEP:none SharedWorker. The sharedWorkerTest
// should listen for worker.onerror events and the expectations updated.
// TODO(https://crbug.com/1200233). A COEP:credentialless document shouldn't
// be able to load COEP:none SharedWorker. The sharedWorkerTest should listen
// for worker.onerror events and the expectations updated.
sharedWorkerTest("same-origin",
same_origin, coep_none,
cookie_same_origin,
Expand All @@ -89,9 +88,9 @@
cookie_same_origin,
cookie_same_origin);

// TODO(https://crbug.com/1200233). A COEP:cors-or-credentialless document
// shouldn't be able to load COEP:none SharedWorker. The sharedWorkerTest
// should listen for worker.onerror events and the expectations updated.
// TODO(https://crbug.com/1200233). A COEP:credentialless document shouldn't
// be able to load COEP:none SharedWorker. The sharedWorkerTest should listen
// for worker.onerror events and the expectations updated.
sharedWorkerTest("cross-origin",
cross_origin, coep_none,
cookie_cross_origin,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/common/get-host-info.sub.js"></script>
<script src="/common/utils.js"></script>
<script src="../resources/common.js"></script>
<script src="../resources/dispatcher.js"></script>
<script src="./resources/common.js"></script>
<script src="./resources/dispatcher.js"></script>

<script>

Expand Down

0 comments on commit aee8ccf

Please sign in to comment.