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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/security/contentTypeOptions/block-text-as-script.html

Issue 2294283002: Stop sniffing 'audio/', 'video/', and 'text/csv' into script. (Closed)
Patch Set: rebase Created 4 years, 3 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 <!DOCTYPE html>
2 <head>
3 <title>Block 'text/csv' when served as script.</title>
4 <script src="/resources/testharness.js"></script>
5 <script src="/resources/testharnessreport.js"></script>
6 <script>
7 window.scriptsSuccessfullyLoaded = 0;
8 </script>
9 </head>
10 <body>
11 <script src="resources/script-with-header.pl?mime=text/csv&amp;options=inval id"></script>
12 <script>
13 test(function () {
14 assert_equals(window.scriptsSuccessfullyLoaded, 0);
15 }, "text/csv scripts should be blocked.");
16 </script>
17 <script src="resources/script-with-header.pl?mime=text/html&amp;options=inva lid"></script>
18 <script src="resources/script-with-header.pl?mime=text/plain&amp;options=inv alid"></script>
19 <script>
20 test(function () {
21 assert_equals(window.scriptsSuccessfullyLoaded, 2);
22 }, "text/[not-csv] scripts should not be blocked.");
23 </script>
24 </body>
25 </html>
26
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698