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

Unified Diff: third_party/WebKit/LayoutTests/external/wpt/html/webappapis/dynamic-markup-insertion/opening-the-input-stream/origin-check-in-document-open-basic.html

Issue 2707113005: The security check in document.write should test for same-origin (Closed)
Patch Set: updates Created 3 years, 10 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: third_party/WebKit/LayoutTests/external/wpt/html/webappapis/dynamic-markup-insertion/opening-the-input-stream/origin-check-in-document-open-basic.html
diff --git a/third_party/WebKit/LayoutTests/external/wpt/html/webappapis/dynamic-markup-insertion/opening-the-input-stream/origin-check-in-document-open-basic.html b/third_party/WebKit/LayoutTests/external/wpt/html/webappapis/dynamic-markup-insertion/opening-the-input-stream/origin-check-in-document-open-basic.html
index 7335122e28f4214c73ffd3382df4508649b5ac55..118be71af19c88d5fed0a1efe010bbd6868eae9c 100644
--- a/third_party/WebKit/LayoutTests/external/wpt/html/webappapis/dynamic-markup-insertion/opening-the-input-stream/origin-check-in-document-open-basic.html
+++ b/third_party/WebKit/LayoutTests/external/wpt/html/webappapis/dynamic-markup-insertion/opening-the-input-stream/origin-check-in-document-open-basic.html
@@ -14,5 +14,13 @@ testInIFrame(undefined, (ctx) => {
assert_unreached("Opening a same origin document throws");
}
}, "It should be possible to open same origin documents.");
+
+testInIFrame(undefined, (ctx) => {
+ try {
+ ctx.iframes[0].contentDocument.write("");
+ } catch (e) {
+ assert_unreached("Implicitly opening a same origin document throws");
+ }
+}, "It should be possible to implicitly open same origin documents.");
</script>
</body>

Powered by Google App Engine
This is Rietveld 408576698