OLD | NEW |
(Empty) | |
| 1 <script src="../resources/testharness.js"></script> |
| 2 <script src="../resources/testharnessreport.js"></script> |
| 3 <script> |
| 4 test(function () { |
| 5 // http://username@password:localhost:8000/... should be blocked. |
| 6 var originWithAuth = new URL(document.URL); |
| 7 originWithAuth.username += 'username'; |
| 8 originWithAuth.password += 'password'; |
| 9 originWithAuth = originWithAuth.href; |
| 10 |
| 11 assert_throws('SecurityError', function () { |
| 12 history.pushState(null, null, originWithAuth); |
| 13 }); |
| 14 }, 'pushState that changes credentials should fail with SecurityError'); |
| 15 </script> |
OLD | NEW |