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

Side by Side Diff: LayoutTests/http/tests/security/contentSecurityPolicy/1.1/scriptnonce-and-scripthash.html

Issue 26481005: Implementation of script hashes for CSP. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase on tip of tree Created 7 years, 1 month 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 <html>
3 <head>
4 <meta http-equiv="Content-Security-Policy" content="script-src 'sha1-Mfu EFRkC2LmR31AMy9KW2ZLDegA=' 'sha1-p70t5PXyndLfjKNjbyBBOL1gFiM=' 'nonce-nonceynonc e'">
5 <script nonce="nonceynonce">
6 if (window.testRunner)
7 testRunner.dumpAsText();
8 alert('PASS (1/3)');
9 </script>
10 <script>
11 alert('PASS (2/3)');
12 </script>
13 <script nonce="nonceynonce">
14 alert('PASS (3/3)');
15 </script>
16 <script>
17 alert('FAIL (1/2)');
18 </script>
19 <script nonce="notanonce">
20 alert('FAIL (2/2)');
21 </script>
22 </head>
23 <body>
24 <p>
25 This tests the combined use of script hash and script nonce. It
26 passes if two console warnings are visible and the three alerts show
27 PASS.
28 </p>
29 </body>
30 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698