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

Side by Side Diff: LayoutTests/http/tests/security/subresourceIntegrity/subresource-integrity-invalid-integrity.html

Issue 1166003004: SRI fail open on ineligible resources. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 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
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <head>
4 <title>SRI invalid integrity attributes</title>
5 <script src="/resources/testharness.js"></script>
6 <script src="/resources/testharnessreport.js"></script>
7 </head>
3 <body> 8 <body>
4 <script> 9 <script>
5 if (window.testRunner) 10 var count = 0;
6 testRunner.dumpAsText(); 11 function checkDone() {
12 if (count == 2)
13 done();
14 count++;
15 }
16 var success = checkDone;
17 function scriptError() {
18 assert_unreached("Script failed to load.");
19 checkDone();
20 }
7 </script> 21 </script>
8 <p> 22 <script src='call-success.js' onerror="scriptError();" integrity="sha256 ;B0_62fJSJFrdjEFR9ba04m_D-LHQ-zG6PGcaR0Trpxg="></script>
9 This test passes if no 'FAIL' alert appears. 23 <script src='call-success.js' onerror="scriptError();" integrity="sha256 :B0_62fJSJFrdjEFR9ba04m_D-LHQ-zG6PGcaR0Trpxg="></script>
10 </p> 24 <script src='call-success.js' onerror="scriptError();" integrity="sha256 -(B0_62fJSJFrdjEFR9ba04m_D-LHQ-zG6PGcaR0Trpxg=)"></script>
11 <script src='fail.js' integrity="sha256;yM5ZyzNsyKfaXRY78zSGapeQKtl0oGdp PpYxgwl8XW8="></script>
12 <script src='fail.js' integrity="sha256:yM5ZyzNsyKfaXRY78zSGapeQKtl0oGdp PpYxgwl8XW8="></script>
13 <script src='fail.js' integrity="sha256-(yM5ZyzNsyKfaXRY78zSGapeQKtl0oGd pPpYxgwl8XW8=)"></script>
14 </body> 25 </body>
15 </html> 26 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698