Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / security / xss-DENIED-window-index-assign.html
blob693123455a858d779a146b2fe3aa782ea67e81ec
1 <script>
2 if (window.testRunner)
3 testRunner.dumpAsText();
5 window[0] = {
6 a: "1",
7 f: function() {
8 alert("FAIL: Child called parent.f()");
11 </script>
12 <iframe src="data:text/html,<script>try { alert(parent[0].a); } catch (e) { alert('PASS: Access to parent[0].a threw exception.'); }</script><script>try { parent[0].f(); } catch (e) { alert('PASS: Access to parent[0].f() threw exception.'); }</script>"></iframe><br>
13 This test passes if the access is forbidden.