content/base/test/csp/file_CSP_main.html

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

michael@0 1 <html>
michael@0 2 <head>
michael@0 3 <link rel='stylesheet' type='text/css'
michael@0 4 href='http://example.org/tests/content/base/test/csp/file_CSP.sjs?testid=style_bad&type=text/css' />
michael@0 5 <link rel='stylesheet' type='text/css'
michael@0 6 href='file_CSP.sjs?testid=style_good&type=text/css' />
michael@0 7
michael@0 8 <!-- Used to embed inline styles here for testing fonts, but can't do that -->
michael@0 9 <!-- due to bug 763879 (block inline styles). Moved these to an external, CSS -->
michael@0 10 <!-- file (file_CSP.css). -->
michael@0 11 <link rel='stylesheet' type='text/css' href='file_CSP.css' />
michael@0 12
michael@0 13 </head>
michael@0 14 <body>
michael@0 15 <!-- these should be stopped by CSP. :) -->
michael@0 16 <img src="http://example.org/tests/content/base/test/csp/file_CSP.sjs?testid=img_bad&type=img/png"> </img>
michael@0 17 <audio src="http://example.org/tests/content/base/test/csp/file_CSP.sjs?testid=media_bad&type=audio/vorbis"></audio>
michael@0 18 <script src='http://example.org/tests/content/base/test/csp/file_CSP.sjs?testid=script_bad&type=text/javascript'></script>
michael@0 19 <iframe src='http://example.org/tests/content/base/test/csp/file_CSP.sjs?testid=frame_bad&content=FAIL'></iframe>
michael@0 20 <object width="10" height="10">
michael@0 21 <param name="movie" value="http://example.org/tests/content/base/test/csp/file_CSP.sjs?testid=object_bad&type=application/x-shockwave-flash">
michael@0 22 <embed src="http://example.org/tests/content/base/test/csp/file_CSP.sjs?testid=object_bad&type=application/x-shockwave-flash"></embed>
michael@0 23 </object>
michael@0 24
michael@0 25 <!-- these should load ok. :) -->
michael@0 26 <img src="file_CSP.sjs?testid=img_good&type=img/png" />
michael@0 27 <audio src="file_CSP.sjs?testid=media_good&type=audio/vorbis"></audio>
michael@0 28 <script src='file_CSP.sjs?testid=script_good&type=text/javascript'></script>
michael@0 29 <iframe src='file_CSP.sjs?testid=frame_good&content=PASS'></iframe>
michael@0 30
michael@0 31 <object width="10" height="10">
michael@0 32 <param name="movie" value="file_CSP.sjs?testid=object_good&type=application/x-shockwave-flash">
michael@0 33 <embed src="file_CSP.sjs?testid=object_good&type=application/x-shockwave-flash"></embed>
michael@0 34 </object>
michael@0 35
michael@0 36 <!-- XHR tests... they're taken care of in this script,
michael@0 37 and since the URI doesn't have any 'testid' values,
michael@0 38 it will just be ignored by the test framework. -->
michael@0 39 <script src='file_CSP_main.js'></script>
michael@0 40
michael@0 41 <!-- Support elements for the @font-face test -->
michael@0 42 <div class="div_arbitrary_good">arbitrary good</div>
michael@0 43 <div class="div_arbitrary_bad">arbitrary_bad</div>
michael@0 44 </body>
michael@0 45 </html>

mercurial