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

Unified Diff: LayoutTests/http/tests/security/xss-DENIED-window-index-assign.html

Issue 19932002: Throw exceptions on all failed cross-origin access checks. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: test. Created 7 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/http/tests/security/xss-DENIED-window-index-assign.html
diff --git a/LayoutTests/http/tests/security/xss-DENIED-window-index-assign.html b/LayoutTests/http/tests/security/xss-DENIED-window-index-assign.html
index a6b54a1fe164a474f4e2257260378346bec97179..693123455a858d779a146b2fe3aa782ea67e81ec 100644
--- a/LayoutTests/http/tests/security/xss-DENIED-window-index-assign.html
+++ b/LayoutTests/http/tests/security/xss-DENIED-window-index-assign.html
@@ -9,5 +9,5 @@ window[0] = {
}
};
</script>
-<iframe src="data:text/html,<script>alert(parent[0].a);</script><script>parent[0].f();</script>"></iframe><br>
+<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>
This test passes if the access is forbidden.

Powered by Google App Engine
This is Rietveld 408576698