summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp
diff options
context:
space:
mode:
authorMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
committerMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
commit5f8de423f190bbb79a62f804151bc24824fa32d8 (patch)
tree10027f336435511475e392454359edea8e25895d /testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp
parent49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff)
downloadUXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip
Add m-esr52 at 52.6.0
Diffstat (limited to 'testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp')
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html40
-rw-r--r--testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html40
60 files changed, 2400 insertions, 0 deletions
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..0665510a6
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via fetch-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..a93c94af5
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via fetch-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..6665a2f35
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via fetch-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..b380ce0c9
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via iframe-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..1894667f0
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via iframe-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..033feffcc
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via iframe-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..1f6b62841
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via img-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..88a3e42a5
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via img-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..69d835c3d
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via img-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..ffa234c29
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via script-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..f92abf01b
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via script-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..953805774
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via script-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..b6191fed6
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via xhr-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..635ec9d82
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via xhr-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..00848d660
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via xhr-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..00cacb906
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via fetch-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..68b8f69e5
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via fetch-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..9390b64fd
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via fetch-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..1c12c9ca2
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via iframe-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..a76c98066
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via iframe-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..dd1c82dc6
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via iframe-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..307c76211
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via img-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..30530e663
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via img-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..d6e1c283c
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via img-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..19666416a
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via script-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..f05d225d8
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via script-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..efa96f50f
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via script-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..ecc377c68
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via xhr-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..c5b47ed3b
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via xhr-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..f8b744f61
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/cross-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via xhr-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is cross-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "cross-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..36757f5dc
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via fetch-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..c75ea8d74
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via fetch-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..e765d8200
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/fetch-request/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via fetch-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..5d2c1268c
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via iframe-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..07850f1d2
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via iframe-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..bea31157f
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/iframe-tag/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via iframe-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..b1e6128a3
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via img-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..187644769
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via img-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..621aaf86a
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/img-tag/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via img-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..2c16b549a
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via script-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..2c66e693d
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via script-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..e6c6432c0
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/script-tag/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via script-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..ec52992fd
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via xhr-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html
new file mode 100644
index 000000000..c0aef90b3
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via xhr-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..76e883fce
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-http/xhr-request/insecure-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an http
+ sub-resource via xhr-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "http",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..d719b5135
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via fetch-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..21b899d88
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via fetch-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..e83e55ecc
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/fetch-request/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via fetch-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "fetch-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..fdf3cf38c
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via iframe-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..ff768ca62
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via iframe-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..b36050b5e
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/iframe-tag/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via iframe-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "iframe-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/document.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..943ec5cf3
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via img-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..44cf0ddec
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via img-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..9df29013d
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/img-tag/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via img-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "img-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/image.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..5b392fb53
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via script-tag using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..7d6be6e4d
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via script-tag using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..29c554a2f
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/script-tag/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via script-tag using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "script-tag",
+ "subresource_path": "/referrer-policy/generic/subresource/script.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html
new file mode 100644
index 000000000..2f60784c0
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.keep-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via xhr-request using the http-rp
+ delivery method with keep-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "keep-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html
new file mode 100644
index 000000000..179877264
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.no-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via xhr-request using the http-rp
+ delivery method with no-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "no-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html
new file mode 100644
index 000000000..de46596f9
--- /dev/null
+++ b/testing/web-platform/tests/referrer-policy/unset-referrer-policy/http-rp/same-origin/http-https/xhr-request/upgrade-protocol.swap-origin-redirect.http.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<!-- DO NOT EDIT! Generated by referrer-policy/generic/tools/generate.py using referrer-policy/generic/template/test.release.html.template. -->
+<html>
+ <head>
+ <title>Referrer-Policy: Referrer Policy is not explicitly defined</title>
+ <meta name="description" content="Check that referrer URL follows no-referrer-when-downgrade policy when no explicit Referrer Policy is set.">
+ <link rel="author" title="Kristijan Burnik" href="burnik@chromium.org">
+ <link rel="help" href="https://w3c.github.io/webappsec-referrer-policy/#referrer-policies">
+ <meta name="assert" content="The referrer URL is stripped-referrer when a
+ document served over http requires an https
+ sub-resource via xhr-request using the http-rp
+ delivery method with swap-origin-redirect and when
+ the target request is same-origin.">
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <!-- TODO(kristijanburnik): Minify and merge both: -->
+ <script src="/referrer-policy/generic/common.js"></script>
+ <script src="/referrer-policy/generic/referrer-policy-test-case.js?pipe=sub"></script>
+ </head>
+ <body>
+ <script>
+ ReferrerPolicyTestCase(
+ {
+ "referrer_policy": null,
+ "delivery_method": "http-rp",
+ "redirection": "swap-origin-redirect",
+ "origin": "same-origin",
+ "source_protocol": "http",
+ "target_protocol": "https",
+ "subresource": "xhr-request",
+ "subresource_path": "/referrer-policy/generic/subresource/xhr.py",
+ "referrer_url": "stripped-referrer"
+ },
+ document.querySelector("meta[name=assert]").content,
+ new SanityChecker()
+ ).start();
+ </script>
+ <div id="log"></div>
+ </body>
+</html>