Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(136)

Side by Side Diff: LayoutTests/http/tests/security/contentSecurityPolicy/suborigin-allow.html

Issue 27073003: CSP Suborigins Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Address abarth's comments Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <meta http-equiv="Content-Security-Policy" content="suborigin foobar">
Mike West 2014/10/23 12:59:18 <!doctype html> <html> <head> ... </head> <body> .
Mike West 2014/10/23 12:59:18 As I've noted way down somewhere in the code, we s
jww 2015/03/20 22:50:02 Done.
2 <script>
3 if (window.testRunner) {
4 testRunner.waitUntilDone();
5 testRunner.dumpAsText();
6 }
7
8 function iframeLoaded() {
9 var iframe = document.getElementById('iframe');
10 try {
11 var secret = iframe.contentWindow.secret;
12 alert("PASS: Secret is '" + secret + "'.");
13 } catch(e) {
14 alert('FAIL: Prevented from accessing the content of the iframe in the s ame suborigin.');
15 }
16 testRunner.notifyDone();
Mike West 2014/10/23 12:59:18 Please use testHarness.js instead to make these as
jww 2015/03/20 22:50:02 Done.
17 }
18 </script>
19 <p>
20 This tests whether a frame in a can access secrets in a frame in the same subori gin.
21 </p>
22 <iframe onload="iframeLoaded();" id="iframe" src="resources/suborigin-frame.html "></iframe>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698