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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/security/ftp-subresource-blocked.html

Issue 2656443005: Block 'ftp:' subresource requests from non-'ftp:' pages. (Closed)
Patch Set: test 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
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/security/block-test-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/security/ftp-subresource-blocked.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/security/ftp-subresource-blocked.html b/third_party/WebKit/LayoutTests/http/tests/security/ftp-subresource-blocked.html
new file mode 100644
index 0000000000000000000000000000000000000000..f03deb1e387e7e42ec2d93c977b650dddd30b914
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/http/tests/security/ftp-subresource-blocked.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+ async_test(t => {
+ var i = document.createElement('img');
+ i.onload = t.unreached_func('The image should not load.');
+ i.onerror = t.step_func_done(e => {
+ assert_equals(i.naturalWidth, 0);
+ assert_equals(i.naturalHeight, 0);
+ });
+
+ i.src = 'ftp://example.test/image.png';
+ }, "'ftp:' subresource requests fail.");
+</script>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/security/block-test-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698