Index: third_party/WebKit/LayoutTests/http/tests/security/contentSecurityPolicy/embeddedEnforcement/allow_csp_header-cross-origin-enforcement.html |
diff --git a/third_party/WebKit/LayoutTests/http/tests/security/contentSecurityPolicy/embeddedEnforcement/allow_csp_header-cross-origin-enforcement.html b/third_party/WebKit/LayoutTests/http/tests/security/contentSecurityPolicy/embeddedEnforcement/allow_csp_header-cross-origin-enforcement.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..e0b2a07e03b60c0510d58e1ced82c75bfcee145c |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/http/tests/security/contentSecurityPolicy/embeddedEnforcement/allow_csp_header-cross-origin-enforcement.html |
@@ -0,0 +1,14 @@ |
+<head> |
+ <script src="/js-test-resources/js-test.js"></script> |
+ <script src="/security/contentSecurityPolicy/resources/child-src-test.js"></script> |
+</head> |
+<body> |
+ <script> |
+ description("Allow-CSP-From header enforces new policies from the parent."); |
+ csp = "script-src 'unsafe-inline'; img-src 'none'"; |
+ // localhost is cross-origin for 127.0.0.1 |
+ url = "http://localhost:8000/security/contentSecurityPolicy/resources/respond-with-allow-csp-from-header.php?allow_csp_from=" + "http://127.0.0.1:8000"; |
+ injectFrameWithCSP(url, csp, EXPECT_LOAD, CROSS_ORIGIN); |
+ </script> |
+</body> |
+</html> |