| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../resources/testharness.js"></script> | 4 <script src="../resources/testharness.js"></script> |
| 5 <script src="../resources/testharnessreport.js"></script> | 5 <script src="../resources/testharnessreport.js"></script> |
| 6 <script> | 6 <script> |
| 7 testRunner.setAllowUniversalAccessFromFileURLs(false); | 7 testRunner.setAllowUniversalAccessFromFileURLs(false); |
| 8 testRunner.setAllowFileAccessFromFileURLs(false); | 8 testRunner.setAllowFileAccessFromFileURLs(false); |
| 9 | 9 |
| 10 var t = async_test('file: should be a unique-origin protocol for XHR purposes'); | 10 var t = async_test('file: should be a unique-origin protocol for XHR purposes'); |
| 11 window.addEventListener('message', t.step_func(function(evt) { | 11 window.addEventListener('message', t.step_func(function(evt) { |
| 12 assert_equals(evt.data, 'NetworkError'); | 12 assert_equals(evt.data, 'NetworkError'); |
| 13 t.done(); | 13 t.done(); |
| 14 })); | 14 })); |
| 15 </script> | 15 </script> |
| 16 </head> | 16 </head> |
| 17 <body> | 17 <body> |
| 18 <iframe src="resources/cannot-read-self-from-file.html"></iframe> | 18 <iframe src="resources/cannot-read-self-from-file.html"></iframe> |
| 19 Documents loaded from file: shouldn't be able to access themselves via XHR. | |
| 20 </body> | 19 </body> |
| 21 </html> | 20 </html> |
| OLD | NEW |