Changeset 272607 in webkit


Ignore:
Timestamp:
Feb 9, 2021, 1:21:26 PM (5 years ago)
Author:
Chris Dumez
Message:

Disallow alert/confirm/prompt in cross-origin-domain subframes
https://bugs.webkit.org/show_bug.cgi?id=221568

Reviewed by Geoff Garen.

Source/WebCore:

Disallow alert/confirm/prompt in cross-origin-domain subframes as per the latest HTML specification:

Tests: http/tests/security/cross-origin-js-prompt-forbidden.html

http/tests/security/same-origin-different-domain-js-prompt-forbidden.html

  • page/DOMWindow.cpp:

(WebCore::DOMWindow::alert):
(WebCore::DOMWindow::confirmForBindings):
(WebCore::DOMWindow::prompt):

  • page/SecurityOrigin.cpp:
  • page/SecurityOrigin.h:

LayoutTests:

Add layout test coverage and update existing tests to stop using alert() in cross-origin iframes.

  • fast/events/popup-blocked-from-unique-frame-via-window-open-named-sibling-frame-expected.txt:
  • fast/events/popup-blocked-from-unique-frame-via-window-open-named-sibling-frame.html:
  • fast/events/popup-when-select-change-expected.txt:
  • fast/events/popup-when-select-change.html:
  • fast/events/resize-subframe-expected.txt:
  • fast/events/resize-subframe.html:
  • fast/forms/autofocus-in-sandbox-with-allow-scripts-expected.txt:
  • fast/forms/autofocus-in-sandbox-with-allow-scripts.html:
  • fast/frames/resources/navigate-top-by-name-to-fail.html:
  • fast/frames/sandboxed-iframe-navigation-top-by-name-denied-expected.txt:
  • http/tests/cookies/resources/third-party-cookie-relaxing-iframe.html:
  • http/tests/cookies/third-party-cookie-relaxing-expected.txt:
  • http/tests/history/cross-origin-replace-history-object-child-expected.txt:
  • http/tests/history/cross-origin-replace-history-object-expected.txt:
  • http/tests/history/resources/cross-origin-replaces-history-object-child-iframe.html:
  • http/tests/history/resources/cross-origin-replaces-history-object-iframe.html:
  • http/tests/plugins/resources/third-party-cookie-accept-policy-iframe.html:
  • http/tests/plugins/third-party-cookie-accept-policy-expected.txt:
  • http/tests/security/contentSecurityPolicy/embed-redirect-allowed-expected.txt:
  • http/tests/security/contentSecurityPolicy/embed-redirect-allowed2-expected.txt:
  • http/tests/security/contentSecurityPolicy/frame-src-cross-origin-load-expected.txt:
  • http/tests/security/contentSecurityPolicy/iframe-allowed-when-loaded-via-javascript-url-expected.txt:
  • http/tests/security/contentSecurityPolicy/iframe-inside-csp-expected.txt:
  • http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-child-src-expected.txt:
  • http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-child-src2-expected.txt:
  • http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-frame-src-expected.txt:
  • http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-frame-src2-expected.txt:
  • http/tests/security/contentSecurityPolicy/object-redirect-allowed-expected.txt:
  • http/tests/security/contentSecurityPolicy/object-redirect-allowed2-expected.txt:
  • http/tests/security/contentSecurityPolicy/resources/alert-fail.html:
  • http/tests/security/contentSecurityPolicy/resources/alert-fail.js:

(catch):

  • http/tests/security/contentSecurityPolicy/resources/alert-pass.html:
  • http/tests/security/contentSecurityPolicy/resources/alert-pass.js:

(catch):

  • http/tests/security/contentSecurityPolicy/resources/sandbox.php:
  • http/tests/security/contentSecurityPolicy/resources/sandboxed-eval.php:
  • http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header-control-expected.txt:
  • http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header-expected.txt:
  • http/tests/security/contentSecurityPolicy/sandbox-report-only-expected.txt:
  • http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/proper-nested-upgrades-expected.txt:
  • http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/upgrades-mixed-content-expected.txt:
  • http/tests/security/cross-origin-js-prompt-forbidden-expected.txt: Added.
  • http/tests/security/cross-origin-js-prompt-forbidden.html: Added.
  • http/tests/security/dataURL/resources/foreign-domain-data-url-accessor-iframe.html:
  • http/tests/security/dataURL/resources/foreign-domain-data-url-accessor-opened-frame.html:
  • http/tests/security/dataURL/xss-DENIED-from-data-url-in-foreign-domain-subframe-expected.txt:
  • http/tests/security/dataURL/xss-DENIED-from-data-url-in-foreign-domain-window-open-expected.txt:
  • http/tests/security/mixedContent/resources/frame-with-insecure-websocket.html:
  • http/tests/security/mixedContent/websocket/insecure-websocket-in-iframe-expected.txt:
  • http/tests/security/resources/cross-origin-js-prompt-forbidden.html: Added.
  • http/tests/security/same-origin-different-domain-js-prompt-forbidden-expected.txt: Added.
  • http/tests/security/same-origin-different-domain-js-prompt-forbidden.html: Added.
  • http/tests/security/xssAuditor/base-href-control-char-expected.txt:
  • http/tests/security/xssAuditor/base-href-direct-expected.txt:
  • http/tests/security/xssAuditor/base-href-expected.txt:
  • http/tests/security/xssAuditor/base-href-null-char-expected.txt:
  • http/tests/security/xssAuditor/base-href-safe-expected.txt:
  • http/tests/security/xssAuditor/base-href-safe2-expected.txt:
  • http/tests/security/xssAuditor/base-href-safe3-expected.txt:
  • http/tests/security/xssAuditor/base-href-scheme-relative-expected.txt:
  • http/tests/security/xssAuditor/cached-frame-expected.txt:
  • http/tests/security/xssAuditor/cached-frame.html:
  • http/tests/security/xssAuditor/cookie-injection-expected.txt:
  • http/tests/security/xssAuditor/data-urls-work-expected.txt:
  • http/tests/security/xssAuditor/data-urls-work.html:
  • http/tests/security/xssAuditor/dom-write-innerHTML-expected.txt:
  • http/tests/security/xssAuditor/dom-write-innerHTML.html:
  • http/tests/security/xssAuditor/form-action-expected.txt:
  • http/tests/security/xssAuditor/formaction-on-button-expected.txt:
  • http/tests/security/xssAuditor/formaction-on-input-expected.txt:
  • http/tests/security/xssAuditor/javascript-link-safe-expected.txt:
  • http/tests/security/xssAuditor/javascript-link-safe.html:
  • http/tests/security/xssAuditor/property-escape-noquotes-expected.txt:
  • http/tests/security/xssAuditor/property-escape-noquotes-tab-slash-chars-expected.txt:
  • http/tests/security/xssAuditor/property-escape-noquotes-tab-slash-chars.html:
  • http/tests/security/xssAuditor/property-escape-noquotes.html:
  • http/tests/security/xssAuditor/property-inject-expected.txt:
  • http/tests/security/xssAuditor/property-inject.html:
  • http/tests/security/xssAuditor/resources/base-href/really-safe-script.js:
  • http/tests/security/xssAuditor/resources/base-href/safe-script.js:
  • http/tests/security/xssAuditor/resources/echo-intertag.pl:
  • http/tests/security/xssAuditor/resources/javascript-link-safe.html:
  • http/tests/security/xssAuditor/resources/nph-cached.pl:
  • http/tests/security/xssAuditor/resources/safe-script-noquotes.js:
  • http/tests/security/xssAuditor/resources/safe-script.js:
  • http/tests/security/xssAuditor/resources/script-tag-safe2.html:
  • http/tests/security/xssAuditor/script-tag-near-start-expected.txt:
  • http/tests/security/xssAuditor/script-tag-near-start.html:
  • http/tests/security/xssAuditor/script-tag-safe2-expected.txt:
  • http/tests/security/xssAuditor/script-tag-safe2.html:
  • http/tests/security/xssAuditor/script-tag-safe3-expected.txt:
  • http/tests/security/xssAuditor/script-tag-safe3.html:
  • http/tests/security/xssAuditor/script-tag-src-redirect-safe-expected.txt:
  • http/tests/security/xssAuditor/script-tag-with-injected-comment-expected.txt:
  • http/tests/security/xssAuditor/script-tag-with-injected-comment.html:
  • http/tests/security/xssAuditor/script-tag-with-source-same-host-expected.txt:
  • platform/wk2/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/proper-nested-upgrades-expected.txt:
Location:
trunk
Files:
6 added
131 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r272600 r272607  
     12021-02-09  Chris Dumez  <cdumez@apple.com>
     2
     3        Disallow alert/confirm/prompt in cross-origin-domain subframes
     4        https://bugs.webkit.org/show_bug.cgi?id=221568
     5
     6        Reviewed by Geoff Garen.
     7
     8        Add layout test coverage and update existing tests to stop using alert() in cross-origin iframes.
     9
     10        * fast/events/popup-blocked-from-unique-frame-via-window-open-named-sibling-frame-expected.txt:
     11        * fast/events/popup-blocked-from-unique-frame-via-window-open-named-sibling-frame.html:
     12        * fast/events/popup-when-select-change-expected.txt:
     13        * fast/events/popup-when-select-change.html:
     14        * fast/events/resize-subframe-expected.txt:
     15        * fast/events/resize-subframe.html:
     16        * fast/forms/autofocus-in-sandbox-with-allow-scripts-expected.txt:
     17        * fast/forms/autofocus-in-sandbox-with-allow-scripts.html:
     18        * fast/frames/resources/navigate-top-by-name-to-fail.html:
     19        * fast/frames/sandboxed-iframe-navigation-top-by-name-denied-expected.txt:
     20        * http/tests/cookies/resources/third-party-cookie-relaxing-iframe.html:
     21        * http/tests/cookies/third-party-cookie-relaxing-expected.txt:
     22        * http/tests/history/cross-origin-replace-history-object-child-expected.txt:
     23        * http/tests/history/cross-origin-replace-history-object-expected.txt:
     24        * http/tests/history/resources/cross-origin-replaces-history-object-child-iframe.html:
     25        * http/tests/history/resources/cross-origin-replaces-history-object-iframe.html:
     26        * http/tests/plugins/resources/third-party-cookie-accept-policy-iframe.html:
     27        * http/tests/plugins/third-party-cookie-accept-policy-expected.txt:
     28        * http/tests/security/contentSecurityPolicy/embed-redirect-allowed-expected.txt:
     29        * http/tests/security/contentSecurityPolicy/embed-redirect-allowed2-expected.txt:
     30        * http/tests/security/contentSecurityPolicy/frame-src-cross-origin-load-expected.txt:
     31        * http/tests/security/contentSecurityPolicy/iframe-allowed-when-loaded-via-javascript-url-expected.txt:
     32        * http/tests/security/contentSecurityPolicy/iframe-inside-csp-expected.txt:
     33        * http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-child-src-expected.txt:
     34        * http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-child-src2-expected.txt:
     35        * http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-frame-src-expected.txt:
     36        * http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-frame-src2-expected.txt:
     37        * http/tests/security/contentSecurityPolicy/object-redirect-allowed-expected.txt:
     38        * http/tests/security/contentSecurityPolicy/object-redirect-allowed2-expected.txt:
     39        * http/tests/security/contentSecurityPolicy/resources/alert-fail.html:
     40        * http/tests/security/contentSecurityPolicy/resources/alert-fail.js:
     41        (catch):
     42        * http/tests/security/contentSecurityPolicy/resources/alert-pass.html:
     43        * http/tests/security/contentSecurityPolicy/resources/alert-pass.js:
     44        (catch):
     45        * http/tests/security/contentSecurityPolicy/resources/sandbox.php:
     46        * http/tests/security/contentSecurityPolicy/resources/sandboxed-eval.php:
     47        * http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header-control-expected.txt:
     48        * http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header-expected.txt:
     49        * http/tests/security/contentSecurityPolicy/sandbox-report-only-expected.txt:
     50        * http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/proper-nested-upgrades-expected.txt:
     51        * http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/upgrades-mixed-content-expected.txt:
     52        * http/tests/security/cross-origin-js-prompt-forbidden-expected.txt: Added.
     53        * http/tests/security/cross-origin-js-prompt-forbidden.html: Added.
     54        * http/tests/security/dataURL/resources/foreign-domain-data-url-accessor-iframe.html:
     55        * http/tests/security/dataURL/resources/foreign-domain-data-url-accessor-opened-frame.html:
     56        * http/tests/security/dataURL/xss-DENIED-from-data-url-in-foreign-domain-subframe-expected.txt:
     57        * http/tests/security/dataURL/xss-DENIED-from-data-url-in-foreign-domain-window-open-expected.txt:
     58        * http/tests/security/mixedContent/resources/frame-with-insecure-websocket.html:
     59        * http/tests/security/mixedContent/websocket/insecure-websocket-in-iframe-expected.txt:
     60        * http/tests/security/resources/cross-origin-js-prompt-forbidden.html: Added.
     61        * http/tests/security/same-origin-different-domain-js-prompt-forbidden-expected.txt: Added.
     62        * http/tests/security/same-origin-different-domain-js-prompt-forbidden.html: Added.
     63        * http/tests/security/xssAuditor/base-href-control-char-expected.txt:
     64        * http/tests/security/xssAuditor/base-href-direct-expected.txt:
     65        * http/tests/security/xssAuditor/base-href-expected.txt:
     66        * http/tests/security/xssAuditor/base-href-null-char-expected.txt:
     67        * http/tests/security/xssAuditor/base-href-safe-expected.txt:
     68        * http/tests/security/xssAuditor/base-href-safe2-expected.txt:
     69        * http/tests/security/xssAuditor/base-href-safe3-expected.txt:
     70        * http/tests/security/xssAuditor/base-href-scheme-relative-expected.txt:
     71        * http/tests/security/xssAuditor/cached-frame-expected.txt:
     72        * http/tests/security/xssAuditor/cached-frame.html:
     73        * http/tests/security/xssAuditor/cookie-injection-expected.txt:
     74        * http/tests/security/xssAuditor/data-urls-work-expected.txt:
     75        * http/tests/security/xssAuditor/data-urls-work.html:
     76        * http/tests/security/xssAuditor/dom-write-innerHTML-expected.txt:
     77        * http/tests/security/xssAuditor/dom-write-innerHTML.html:
     78        * http/tests/security/xssAuditor/form-action-expected.txt:
     79        * http/tests/security/xssAuditor/formaction-on-button-expected.txt:
     80        * http/tests/security/xssAuditor/formaction-on-input-expected.txt:
     81        * http/tests/security/xssAuditor/javascript-link-safe-expected.txt:
     82        * http/tests/security/xssAuditor/javascript-link-safe.html:
     83        * http/tests/security/xssAuditor/property-escape-noquotes-expected.txt:
     84        * http/tests/security/xssAuditor/property-escape-noquotes-tab-slash-chars-expected.txt:
     85        * http/tests/security/xssAuditor/property-escape-noquotes-tab-slash-chars.html:
     86        * http/tests/security/xssAuditor/property-escape-noquotes.html:
     87        * http/tests/security/xssAuditor/property-inject-expected.txt:
     88        * http/tests/security/xssAuditor/property-inject.html:
     89        * http/tests/security/xssAuditor/resources/base-href/really-safe-script.js:
     90        * http/tests/security/xssAuditor/resources/base-href/safe-script.js:
     91        * http/tests/security/xssAuditor/resources/echo-intertag.pl:
     92        * http/tests/security/xssAuditor/resources/javascript-link-safe.html:
     93        * http/tests/security/xssAuditor/resources/nph-cached.pl:
     94        * http/tests/security/xssAuditor/resources/safe-script-noquotes.js:
     95        * http/tests/security/xssAuditor/resources/safe-script.js:
     96        * http/tests/security/xssAuditor/resources/script-tag-safe2.html:
     97        * http/tests/security/xssAuditor/script-tag-near-start-expected.txt:
     98        * http/tests/security/xssAuditor/script-tag-near-start.html:
     99        * http/tests/security/xssAuditor/script-tag-safe2-expected.txt:
     100        * http/tests/security/xssAuditor/script-tag-safe2.html:
     101        * http/tests/security/xssAuditor/script-tag-safe3-expected.txt:
     102        * http/tests/security/xssAuditor/script-tag-safe3.html:
     103        * http/tests/security/xssAuditor/script-tag-src-redirect-safe-expected.txt:
     104        * http/tests/security/xssAuditor/script-tag-with-injected-comment-expected.txt:
     105        * http/tests/security/xssAuditor/script-tag-with-injected-comment.html:
     106        * http/tests/security/xssAuditor/script-tag-with-source-same-host-expected.txt:
     107        * platform/wk2/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/proper-nested-upgrades-expected.txt:
     108
    11092021-02-09  Peng Liu  <peng.liu6@apple.com>
    2110
  • trunk/LayoutTests/fast/events/popup-blocked-from-unique-frame-via-window-open-named-sibling-frame-expected.txt

    r267644 r272607  
    1 CONSOLE MESSAGE: Unsafe JavaScript attempt to initiate navigation for frame with URL 'about:blank' from frame with URL 'data:text/html,<script>alert(window.open('about:blank', 'A') ?%20'FAIL'%20:%20'PASS');%3C/script%3E'. The frame attempting navigation is neither same-origin with the target, nor is it the target's parent or opener.
     1CONSOLE MESSAGE: Unsafe JavaScript attempt to initiate navigation for frame with URL 'about:blank' from frame with URL 'data:text/html,<script>console.log(window.open('about:blank', 'A') ?%20'FAIL'%20:%20'PASS');%3C/script%3E'. The frame attempting navigation is neither same-origin with the target, nor is it the target's parent or opener.
    22
    3 ALERT: PASS
     3CONSOLE MESSAGE: PASS
    44
  • trunk/LayoutTests/fast/events/popup-blocked-from-unique-frame-via-window-open-named-sibling-frame.html

    r269236 r272607  
    1212<body>
    1313<iframe name="A"></iframe>
    14 <iframe name="B" src="data:text/html,<script>alert(window.open('about:blank', 'A') ? 'FAIL' : 'PASS');</script>"></iframe>
     14<iframe name="B" src="data:text/html,<script>console.log(window.open('about:blank', 'A') ? 'FAIL' : 'PASS');</script>"></iframe>
    1515</body>
    1616</html>
  • trunk/LayoutTests/fast/events/popup-when-select-change-expected.txt

    r61941 r272607  
    1 ALERT: PASSED
     1CONSOLE MESSAGE: PASSED
    22 If the pop-up was not blocked then there will be an PASS message. Otherwise, the test fails.
    33
  • trunk/LayoutTests/fast/events/popup-when-select-change.html

    r269236 r272607  
    3939<select onchange="onpopup()" id="control1"><option value="0">abcd</option><option value="0">efgh</option></select>
    4040If the pop-up was not blocked then there will be an PASS message. Otherwise, the test fails.
    41 <form id="form" action="data:text/html,<script>alert('PASSED')</script>" target="target">
     41<form id="form" action="data:text/html,<script>console.log('PASSED')</script>" target="target">
    4242<input id="control2" type="submit" value="Submit to new window"/>
    4343</form>
  • trunk/LayoutTests/fast/events/resize-subframe-expected.txt

    r28371 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/fast/events/resize-subframe.html

    r120792 r272607  
    1919                    if (window.testRunner)
    2020                    {
    21                         alert('PASS');
     21                        console.log('PASS');
    2222                        testRunner.notifyDone();
    2323                    }
  • trunk/LayoutTests/fast/forms/autofocus-in-sandbox-with-allow-scripts-expected.txt

    r267644 r272607  
    1 ALERT: INPUT
     1CONSOLE MESSAGE: INPUT
    22This test passes if the activeElement is the input element rather than the body (which it would be if the sandbox didn't allow autofocus although allow-scripts flag is set).
  • trunk/LayoutTests/fast/forms/autofocus-in-sandbox-with-allow-scripts.html

    r221193 r272607  
    66(which it would be if the sandbox didn't allow autofocus although allow-scripts flag is set).
    77<iframe sandbox="allow-scripts allow-modals"
    8     src="data:text/html,<input autofocus onfocus><script>window.onload = function() { alert(document.activeElement.tagName) }</script>"></iframe>
     8    src="data:text/html,<input autofocus onfocus><script>window.onload = function() { console.log(document.activeElement.tagName) }</script>"></iframe>
  • trunk/LayoutTests/fast/frames/resources/navigate-top-by-name-to-fail.html

    r56591 r272607  
    11<script>
    22if (window.open("fail-and-notify-done.html", "target"))
    3     alert("FAIL");
     3    console.log("FAIL");
    44if (window.open("fail-and-notify-done.html", "_top"))
    5     alert("FAIL");
     5    console.log("FAIL");
    66if (window.open("fail-and-notify-done.html", "_parent"))
    7     alert("FAIL");
     7    console.log("FAIL");
    88if (window.open("fail-and-notify-done.html", "_blank"))
    9     alert("FAIL");
    10 alert("PASS");
     9    console.log("FAIL");
     10console.log("PASS");
    1111</script>
  • trunk/LayoutTests/fast/frames/sandboxed-iframe-navigation-top-by-name-denied-expected.txt

    r259900 r272607  
    77
    88CONSOLE MESSAGE: Blocked opening 'fail-and-notify-done.html' in a new window because the request was made in a sandboxed frame whose 'allow-popups' permission is not set.
    9 ALERT: PASS
     9CONSOLE MESSAGE: PASS
    1010This test verifies that a sandboxed IFrame cannot navigate the top-level frame without allow-top-navigation. This test passes if the navigation does not occur.
    1111
  • trunk/LayoutTests/fast/frames/sandboxed-iframe-parsing-space-characters-expected.txt

    r267644 r272607  
    1 ALERT: PASS: Form feed is a delimiter.
     1CONSOLE MESSAGE: PASS: Form feed is a delimiter.
    22CONSOLE MESSAGE: Error while parsing the 'sandbox' attribute: 'allow-scripts
    33allow-forms' is an invalid sandbox flag.
    4 CONSOLE MESSAGE: Blocked script execution in 'data:text/html,<script>alert('FAIL: Vertical tab is not a delimiter.');</script>' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.
    5 ALERT: PASS: Newline is a delimiter.
    6 ALERT: PASS: Return is a delimiter.
     4CONSOLE MESSAGE: Blocked script execution in 'data:text/html,<script>console.log('FAIL: Vertical tab is not a delimiter.');</script>' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.
     5CONSOLE MESSAGE: PASS: Newline is a delimiter.
     6CONSOLE MESSAGE: PASS: Return is a delimiter.
    77CONSOLE MESSAGE: Error while parsing the 'sandbox' attribute: 'allow-scriptsxallow-forms' is an invalid sandbox flag.
    8 CONSOLE MESSAGE: Blocked script execution in 'data:text/html,<script>alert('FAIL: x is not a delimiter.');</script>' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.
    9 ALERT: PASS: Tab is a delimiter.
    10 ALERT: PASS: Space is a delimiter character.
     8CONSOLE MESSAGE: Blocked script execution in 'data:text/html,<script>console.log('FAIL: x is not a delimiter.');</script>' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.
     9CONSOLE MESSAGE: PASS: Tab is a delimiter.
     10CONSOLE MESSAGE: PASS: Space is a delimiter character.
    1111This tests whether we correct parse various space characters in the sandbox attribute.
    1212
  • trunk/LayoutTests/fast/frames/sandboxed-iframe-parsing-space-characters.html

    r221193 r272607  
    2626    var iframe = document.createElement('iframe');
    2727    iframe.sandbox = policy;
    28     iframe.src = "data:text/html,<script>alert('" + message + "');<\/script>";
     28    iframe.src = "data:text/html,<script>console.log('" + message + "');<\/script>";
    2929    iframe.onload = next;
    3030    document.body.appendChild(iframe);
  • trunk/LayoutTests/fast/frames/sandboxed-iframe-scripting-02-expected.txt

    r145993 r272607  
    1 ALERT: PASS: Executed script in data URL
     1CONSOLE MESSAGE: PASS: Executed script in data URL
    22Verify that sandboxed frames with sandbox='allow-scripts' can execute script from data: URLs.
    33
  • trunk/LayoutTests/fast/frames/sandboxed-iframe-scripting-02.html

    r221193 r272607  
    2525<body>
    2626    <iframe sandbox="allow-same-origin allow-scripts allow-modals"
    27             src="data:text/html,<script>alert('PASS: Executed script in data URL');window.parent.postMessage({'pass': true}, '*');</script>">
     27            src="data:text/html,<script>console.log('PASS: Executed script in data URL');window.parent.postMessage({'pass': true}, '*');</script>">
    2828    </iframe>
    2929    <script>
  • trunk/LayoutTests/http/tests/cookies/resources/third-party-cookie-relaxing-iframe.html

    r205854 r272607  
    1919        return;
    2020    } else
    21         alert("Unknown message.");
     21        console.log("Unknown message.");
    2222}
    2323
     
    3232function showCookies()
    3333{
    34     alert("Test stage " + stage++ + " document.cookie is: " + sortCookie(document.cookie));
     34    console.log("Test stage " + stage++ + " document.cookie is: " + sortCookie(document.cookie));
    3535    parent.window.postMessage("done", "*");
    3636}
     
    4040    var baseurl = "http://localhost:8000/cookies/resources/cookie-utility.php";
    4141    var url = queryCommand ? baseurl + "?queryfunction=" + queryCommand : baseurl;
    42     alert(url);
     42    console.log(url);
    4343    var req = new XMLHttpRequest();
    4444    req.open('GET', url, false);
     
    4646
    4747    if (req.status == 200)
    48         alert("XHR response - " + req.responseText);
     48        console.log("XHR response - " + req.responseText);
    4949    else
    50         alert("xhr error");
     50        console.log("xhr error");
    5151   
    5252    parent.window.postMessage("done", "*");   
  • trunk/LayoutTests/http/tests/cookies/third-party-cookie-relaxing-expected.txt

    r267644 r272607  
    22
    33ALERT: Allowing all cookies
    4 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
    5 ALERT: XHR response - Deleted all cookies
    6 ALERT: Test stage 1 document.cookie is:
     4CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
     5CONSOLE MESSAGE: XHR response - Deleted all cookies
     6CONSOLE MESSAGE: Test stage 1 document.cookie is:
    77ALERT: Restricting to first party only cookies
    8 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
    9 ALERT: XHR response - Set the foo cookie
    10 ALERT: Test stage 2 document.cookie is:
     8CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
     9CONSOLE MESSAGE: XHR response - Set the foo cookie
     10CONSOLE MESSAGE: Test stage 2 document.cookie is:
    1111ALERT:
    1212
    1313ALERT: Allowing all cookies
    14 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
    15 ALERT: XHR response - Deleted all cookies
    16 ALERT: Test stage 3 document.cookie is:
     14CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
     15CONSOLE MESSAGE: XHR response - Deleted all cookies
     16CONSOLE MESSAGE: Test stage 3 document.cookie is:
    1717ALERT: Restricting to first party only cookies
    18 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooAndBarCookie
    19 ALERT: XHR response - Set the foo and bar cookies
    20 ALERT: Test stage 4 document.cookie is:
     18CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooAndBarCookie
     19CONSOLE MESSAGE: XHR response - Set the foo and bar cookies
     20CONSOLE MESSAGE: Test stage 4 document.cookie is:
    2121ALERT:
    2222
    2323ALERT: Allowing all cookies
    24 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
    25 ALERT: XHR response - Deleted all cookies
    26 ALERT: Test stage 5 document.cookie is:
    27 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
    28 ALERT: XHR response - Set the foo cookie
    29 ALERT: Test stage 6 document.cookie is: foo=awesomevalue
     24CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
     25CONSOLE MESSAGE: XHR response - Deleted all cookies
     26CONSOLE MESSAGE: Test stage 5 document.cookie is:
     27CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
     28CONSOLE MESSAGE: XHR response - Set the foo cookie
     29CONSOLE MESSAGE: Test stage 6 document.cookie is: foo=awesomevalue
    3030ALERT: Restricting to first party only cookies
    31 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
    32 ALERT: XHR response - Deleted all cookies
    33 ALERT: Test stage 7 document.cookie is:
     31CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
     32CONSOLE MESSAGE: XHR response - Deleted all cookies
     33CONSOLE MESSAGE: Test stage 7 document.cookie is:
    3434ALERT:
    3535
    3636ALERT: Allowing all cookies
    37 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
    38 ALERT: XHR response - Deleted all cookies
    39 ALERT: Test stage 8 document.cookie is:
    40 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
    41 ALERT: XHR response - Set the foo cookie
    42 ALERT: Test stage 9 document.cookie is: foo=awesomevalue
     37CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=deleteCookies
     38CONSOLE MESSAGE: XHR response - Deleted all cookies
     39CONSOLE MESSAGE: Test stage 8 document.cookie is:
     40CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
     41CONSOLE MESSAGE: XHR response - Set the foo cookie
     42CONSOLE MESSAGE: Test stage 9 document.cookie is: foo=awesomevalue
    4343ALERT: Restricting to first party only cookies
    44 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooAndBarCookie
    45 ALERT: XHR response - Set the foo and bar cookies
    46 ALERT: Test stage 10 document.cookie is: bar=anotherawesomevalue; foo=awesomevalue
     44CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooAndBarCookie
     45CONSOLE MESSAGE: XHR response - Set the foo and bar cookies
     46CONSOLE MESSAGE: Test stage 10 document.cookie is: bar=anotherawesomevalue; foo=awesomevalue
    4747
  • trunk/LayoutTests/http/tests/history/cross-origin-replace-history-object-child-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: SecurityError: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a cross-origin frame. Protocols, domains, and ports must match.
    22ALERT: Child window's history object before attempt to clear: undefined
    3 ALERT: About to shadow child window's history object: [object History]
    4 ALERT: PASS: Could not shadow child window's history object: [object History]
     3CONSOLE MESSAGE: Use of window.alert is not allowed in different origin-domain iframes.
     4CONSOLE MESSAGE: PASS: Could not shadow child window's history object: [object History]
    55CONSOLE MESSAGE: SecurityError: Blocked a frame with origin "http://127.0.0.1:8000" from accessing a cross-origin frame. Protocols, domains, and ports must match.
    66ALERT: Child window's history object after attempt to clear: undefined
  • trunk/LayoutTests/http/tests/history/cross-origin-replace-history-object-expected.txt

    r259900 r272607  
    11ALERT: Parent window's history object before attempt to clear: [object History]
    2 ALERT: Attempting to clear parent window's history object:
     2CONSOLE MESSAGE: Attempting to clear parent window's history object:
    33CONSOLE MESSAGE: SecurityError: Blocked a frame with origin "http://localhost:8000" from accessing a cross-origin frame. Protocols, domains, and ports must match.
    44ALERT: Parent window's history object after attempt to clear: [object History]
  • trunk/LayoutTests/http/tests/history/resources/cross-origin-replaces-history-object-child-iframe.html

    r196797 r272607  
    1010        return;
    1111    } else
    12         alert("Unknown message.");
     12        console.log("Unknown message.");
    1313}
    1414
     
    1818    window.history = "";
    1919    if (window.history === "")
    20         alert("FAIL: Shadowed child window's history object: " + window.history);
     20        console.log("FAIL: Shadowed child window's history object: " + window.history);
    2121    else
    22         alert("PASS: Could not shadow child window's history object: " + window.history);
     22        console.log("PASS: Could not shadow child window's history object: " + window.history);
    2323    parent.window.postMessage("done", "*");
    2424}
  • trunk/LayoutTests/http/tests/history/resources/cross-origin-replaces-history-object-iframe.html

    r205148 r272607  
    1010        return;
    1111    } else
    12         alert("Unknown message.");
     12        console.log("Unknown message.");
    1313}
    1414
    1515function setHistoryLength()
    1616{
    17     alert("Attempting to clear parent window's history object:");
     17    console.log("Attempting to clear parent window's history object:");
    1818    try {
    1919        parent.window.history = "";
  • trunk/LayoutTests/http/tests/misc/frame-default-enc-different-domain-expected.txt

    r204605 r272607  
    1 ALERT: windows-1252
     1CONSOLE MESSAGE: windows-1252
    22
  • trunk/LayoutTests/http/tests/misc/frame-default-enc-same-domain-expected.txt

    r37775 r272607  
    1 ALERT: windows-1256
     1CONSOLE MESSAGE: windows-1256
    22
  • trunk/LayoutTests/http/tests/misc/resources/frame-default-enc-frame.html

    r30986 r272607  
    1111        chs = document.characterSet;
    1212
    13     alert(chs);
     13    console.log(chs);
    1414</script>
    1515
  • trunk/LayoutTests/http/tests/plugins/resources/third-party-cookie-accept-policy-iframe.html

    r124692 r272607  
    2323function trySetCookie()
    2424{
    25    alert("Cookies should be clear, and are: '" + document.cookie + "'");
    26    alert("About to set a cookie, but on localhost instead of 127.0.0.1, which is our main document domain - This should fail.");
     25   console.log("Cookies should be clear, and are: '" + document.cookie + "'");
     26   console.log("About to set a cookie, but on localhost instead of 127.0.0.1, which is our main document domain - This should fail.");
    2727    if (window.testRunner)
    2828        testRunner.setAlwaysAcceptCookies(false);
     
    3232function completeTest()
    3333{
    34    alert("Cookies should still be clear, and are: '" + document.cookie + "'");
     34   console.log("Cookies should still be clear, and are: '" + document.cookie + "'");
    3535   resetCookies();
    3636   if (window.testRunner)
  • trunk/LayoutTests/http/tests/plugins/third-party-cookie-accept-policy-expected.txt

    r55738 r272607  
    1 ALERT: Cookies should be clear, and are: ''
    2 ALERT: About to set a cookie, but on localhost instead of 127.0.0.1, which is our main document domain - This should fail.
    3 ALERT: Cookies should still be clear, and are: ''
     1CONSOLE MESSAGE: Cookies should be clear, and are: ''
     2CONSOLE MESSAGE: About to set a cookie, but on localhost instead of 127.0.0.1, which is our main document domain - This should fail.
     3CONSOLE MESSAGE: Cookies should still be clear, and are: ''
    44This tests that plug-ins cannot set cookies in violation of the 3rd party cookie policy.
    55
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/embed-redirect-allowed-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/embed-redirect-allowed2-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/frame-src-cross-origin-load-expected.txt

    r267644 r272607  
    11CONSOLE MESSAGE: Refused to load https://localhost:8443/security/contentSecurityPolicy/resources/alert-fail.html because it does not appear in the frame-src directive of the Content Security Policy.
    22ALERT: PASS
    3 ALERT: PASS
     3CONSOLE MESSAGE: PASS
    44IFrames blocked by CSP should generate a 'load' event, regardless of blocked state. This means they appear to be normal cross-origin loads, thereby not leaking URL information directly to JS.
    55
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/iframe-allowed-when-loaded-via-javascript-url-expected.txt

    r250255 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
    33
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/iframe-inside-csp-expected.txt

    r119913 r272607  
    1 ALERT: PASS (1/2): Script can execute
    2 ALERT: PASS (2/2): Eval works
     1CONSOLE MESSAGE: PASS (1/2): Script can execute
     2CONSOLE MESSAGE: PASS (2/2): Eval works
    33
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-child-src-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-child-src2-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-frame-src-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/iframe-redirect-allowed-by-frame-src2-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/object-redirect-allowed-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/object-redirect-allowed2-expected.txt

    r199612 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/object-src-does-not-affect-child-expected.txt

    r195367 r272607  
    1 ALERT: Plugin Loaded!
     1CONSOLE MESSAGE: Plugin Loaded!
    22This tests that an object-src directive on a top-level page is not inherited by a PluginDocument embedded in an iframe on the page. This test passes if an alert pops up saying that the plugin loaded.
    33
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/resources/alert-fail.html

    r84460 r272607  
    11<script>
    2 alert('FAIL');
     2let isSameOrigin = true;
     3try { top.name } catch (e) { isSameOrigin = false; }
     4if (isSameOrigin)
     5    alert("FAIL");
     6else
     7    console.log("FAIL");
    38</script>
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/resources/alert-fail.js

    r99329 r272607  
    1 alert('FAIL');
     1{
     2let isSameOrigin = true;
     3try { top.name } catch (e) { isSameOrigin = false; }
     4if (isSameOrigin)
     5    alert("FAIL");
     6else
     7    console.log("FAIL");
     8}
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/resources/alert-pass.html

    r199612 r272607  
    11<script>
    2 alert("PASS");
     2let isSameOrigin = true;
     3try { top.name } catch (e) { isSameOrigin = false; }
     4if (isSameOrigin)
     5    alert("PASS");
     6else
     7    console.log("PASS");
    38
    49var shouldNotifyDone = document.location.search.indexOf("?notifyDone=1") !== -1 && window.testRunner;
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/resources/alert-pass.js

    r195367 r272607  
    1 alert('PASS');
     1{
     2let isSameOrigin = true;
     3try { top.name } catch (e) { isSameOrigin = false; }
     4if (isSameOrigin)
     5    alert("PASS");
     6else
     7    console.log("PASS");
     8}
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/resources/sandbox.php

    r195367 r272607  
    99<p>Ready</p>
    1010<script>
    11 alert("Script executed in iframe.");
     11console.log("Script executed in iframe.");
    1212window.secret = "I am a secret";
    1313</script>
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/resources/sandboxed-eval.php

    r221193 r272607  
    33?>
    44<script>
    5 alert('PASS (1/2): Script can execute');
     5console.log('PASS (1/2): Script can execute');
    66</script>
    77<script>
    8 eval("alert('PASS (2/2): Eval works')");
     8eval("console.log('PASS (2/2): Eval works')");
    99</script>
    1010Done.
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header-control-expected.txt

    r119204 r272607  
    1 ALERT: Script executed in iframe.
     1CONSOLE MESSAGE: Script executed in iframe.
    22ALERT: PASS: Iframe was not in a unique origin
    33
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header-expected.txt

    r259900 r272607  
    1 ALERT: Script executed in iframe.
     1CONSOLE MESSAGE: Script executed in iframe.
    22CONSOLE MESSAGE: SecurityError: Sandbox access violation: Blocked a frame at "http://127.0.0.1:8000" from accessing a cross-origin frame.  The frame being accessed is sandboxed and lacks the "allow-same-origin" flag.
    33ALERT: PASS: Iframe was in a unique origin
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-report-only-expected.txt

    r195367 r272607  
    11CONSOLE MESSAGE: The Content Security Policy directive 'sandbox' is ignored when delivered in a report-only policy.
    22CONSOLE MESSAGE: The Content Security Policy 'sandbox' was delivered in report-only mode, but does not specify a 'report-uri'; the policy will have no effect. Please either add a 'report-uri' directive, or deliver the policy via the 'Content-Security-Policy' header.
    3 ALERT: Script executed in iframe.
     3CONSOLE MESSAGE: Script executed in iframe.
    44ALERT: PASS: Iframe was not in a unique origin
    55
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/proper-nested-upgrades-expected.txt

    r231450 r272607  
    22main frame - didFinishDocumentLoadForFrame
    33frame "<!--frame1-->" - didCommitLoadForFrame
    4 ALERT: PASS
     4CONSOLE MESSAGE: PASS
    55frame "<!--frame2-->" - didStartProvisionalLoadForFrame
    66frame "<!--frame1-->" - didFinishDocumentLoadForFrame
    77frame "<!--frame2-->" - didCommitLoadForFrame
    8 ALERT: PASS
    9 ALERT: PASS
     8CONSOLE MESSAGE: PASS
     9CONSOLE MESSAGE: PASS
    1010frame "<!--frame2-->" - didFinishDocumentLoadForFrame
    1111frame "<!--frame2-->" - didHandleOnloadEventsForFrame
  • trunk/LayoutTests/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/upgrades-mixed-content-expected.txt

    r267644 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22This page should alert "PASS" and not generate any mixed content warnings in the console.
  • trunk/LayoutTests/http/tests/security/cross-frame-access-put-expected.txt

    r269612 r272607  
    11CONSOLE MESSAGE: Blocked a frame with origin "http://localhost:8000" from accessing a frame with origin "http://127.0.0.1:8000". Protocols, domains, and ports must match.
    2 ALERT: PASS: window.Attr should be 'function Attr() {    [native code]}' and is.
    3 ALERT: PASS: window.CDATASection should be 'function CDATASection() {    [native code]}' and is.
    4 ALERT: PASS: window.CharacterData should be 'function CharacterData() {    [native code]}' and is.
    5 ALERT: PASS: window.Comment should be 'function Comment() {    [native code]}' and is.
    6 ALERT: PASS: window.CSSPrimitiveValue should be 'function CSSPrimitiveValue() {    [native code]}' and is.
    7 ALERT: PASS: window.CSSRule should be 'function CSSRule() {    [native code]}' and is.
    8 ALERT: PASS: window.CSSStyleDeclaration should be 'function CSSStyleDeclaration() {    [native code]}' and is.
    9 ALERT: PASS: window.CSSValue should be 'function CSSValue() {    [native code]}' and is.
    10 ALERT: PASS: window.Document should be 'function Document() {    [native code]}' and is.
    11 ALERT: PASS: window.DocumentFragment should be 'function DocumentFragment() {    [native code]}' and is.
    12 ALERT: PASS: window.DocumentType should be 'function DocumentType() {    [native code]}' and is.
    13 ALERT: PASS: window.DOMException should be 'function DOMException() {    [native code]}' and is.
    14 ALERT: PASS: window.DOMImplementation should be 'function DOMImplementation() {    [native code]}' and is.
    15 ALERT: PASS: window.DOMParser should be 'function DOMParser() {    [native code]}' and is.
    16 ALERT: PASS: window.Element should be 'function Element() {    [native code]}' and is.
    17 ALERT: PASS: window.EvalError should be 'function EvalError() {    [native code]}' and is.
    18 ALERT: PASS: window.Event should be 'function Event() {    [native code]}' and is.
    19 ALERT: PASS: window.HTMLAnchorElement should be 'function HTMLAnchorElement() {    [native code]}' and is.
    20 ALERT: PASS: window.HTMLAppletElement should be 'undefined' and is.
    21 ALERT: PASS: window.HTMLAreaElement should be 'function HTMLAreaElement() {    [native code]}' and is.
    22 ALERT: PASS: window.HTMLBaseElement should be 'function HTMLBaseElement() {    [native code]}' and is.
    23 ALERT: PASS: window.HTMLBodyElement should be 'function HTMLBodyElement() {    [native code]}' and is.
    24 ALERT: PASS: window.HTMLBRElement should be 'function HTMLBRElement() {    [native code]}' and is.
    25 ALERT: PASS: window.HTMLButtonElement should be 'function HTMLButtonElement() {    [native code]}' and is.
    26 ALERT: PASS: window.HTMLCanvasElement should be 'function HTMLCanvasElement() {    [native code]}' and is.
    27 ALERT: PASS: window.HTMLDirectoryElement should be 'function HTMLDirectoryElement() {    [native code]}' and is.
    28 ALERT: PASS: window.HTMLDivElement should be 'function HTMLDivElement() {    [native code]}' and is.
    29 ALERT: PASS: window.HTMLDListElement should be 'function HTMLDListElement() {    [native code]}' and is.
    30 ALERT: PASS: window.HTMLDocument should be 'function HTMLDocument() {    [native code]}' and is.
    31 ALERT: PASS: window.HTMLElement should be 'function HTMLElement() {    [native code]}' and is.
    32 ALERT: PASS: window.HTMLFieldSetElement should be 'function HTMLFieldSetElement() {    [native code]}' and is.
    33 ALERT: PASS: window.HTMLFontElement should be 'function HTMLFontElement() {    [native code]}' and is.
    34 ALERT: PASS: window.HTMLFormElement should be 'function HTMLFormElement() {    [native code]}' and is.
    35 ALERT: PASS: window.HTMLFrameElement should be 'function HTMLFrameElement() {    [native code]}' and is.
    36 ALERT: PASS: window.HTMLFrameSetElement should be 'function HTMLFrameSetElement() {    [native code]}' and is.
    37 ALERT: PASS: window.HTMLHeadElement should be 'function HTMLHeadElement() {    [native code]}' and is.
    38 ALERT: PASS: window.HTMLHeadingElement should be 'function HTMLHeadingElement() {    [native code]}' and is.
    39 ALERT: PASS: window.HTMLHRElement should be 'function HTMLHRElement() {    [native code]}' and is.
    40 ALERT: PASS: window.HTMLHtmlElement should be 'function HTMLHtmlElement() {    [native code]}' and is.
    41 ALERT: PASS: window.HTMLIFrameElement should be 'function HTMLIFrameElement() {    [native code]}' and is.
    42 ALERT: PASS: window.HTMLImageElement should be 'function HTMLImageElement() {    [native code]}' and is.
    43 ALERT: PASS: window.HTMLInputElement should be 'function HTMLInputElement() {    [native code]}' and is.
    44 ALERT: PASS: window.HTMLIsIndexElement should be 'undefined' and is.
    45 ALERT: PASS: window.HTMLLabelElement should be 'function HTMLLabelElement() {    [native code]}' and is.
    46 ALERT: PASS: window.HTMLLegendElement should be 'function HTMLLegendElement() {    [native code]}' and is.
    47 ALERT: PASS: window.HTMLLIElement should be 'function HTMLLIElement() {    [native code]}' and is.
    48 ALERT: PASS: window.HTMLLinkElement should be 'function HTMLLinkElement() {    [native code]}' and is.
    49 ALERT: PASS: window.HTMLMapElement should be 'function HTMLMapElement() {    [native code]}' and is.
    50 ALERT: PASS: window.HTMLMarqueeElement should be 'function HTMLMarqueeElement() {    [native code]}' and is.
    51 ALERT: PASS: window.HTMLMenuElement should be 'function HTMLMenuElement() {    [native code]}' and is.
    52 ALERT: PASS: window.HTMLMetaElement should be 'function HTMLMetaElement() {    [native code]}' and is.
    53 ALERT: PASS: window.HTMLModElement should be 'function HTMLModElement() {    [native code]}' and is.
    54 ALERT: PASS: window.HTMLOListElement should be 'function HTMLOListElement() {    [native code]}' and is.
    55 ALERT: PASS: window.HTMLOptGroupElement should be 'function HTMLOptGroupElement() {    [native code]}' and is.
    56 ALERT: PASS: window.HTMLOptionElement should be 'function HTMLOptionElement() {    [native code]}' and is.
    57 ALERT: PASS: window.HTMLParagraphElement should be 'function HTMLParagraphElement() {    [native code]}' and is.
    58 ALERT: PASS: window.HTMLParamElement should be 'function HTMLParamElement() {    [native code]}' and is.
    59 ALERT: PASS: window.HTMLPreElement should be 'function HTMLPreElement() {    [native code]}' and is.
    60 ALERT: PASS: window.HTMLQuoteElement should be 'function HTMLQuoteElement() {    [native code]}' and is.
    61 ALERT: PASS: window.HTMLScriptElement should be 'function HTMLScriptElement() {    [native code]}' and is.
    62 ALERT: PASS: window.HTMLSelectElement should be 'function HTMLSelectElement() {    [native code]}' and is.
    63 ALERT: PASS: window.HTMLStyleElement should be 'function HTMLStyleElement() {    [native code]}' and is.
    64 ALERT: PASS: window.HTMLTableCaptionElement should be 'function HTMLTableCaptionElement() {    [native code]}' and is.
    65 ALERT: PASS: window.HTMLTableCellElement should be 'function HTMLTableCellElement() {    [native code]}' and is.
    66 ALERT: PASS: window.HTMLTableColElement should be 'function HTMLTableColElement() {    [native code]}' and is.
    67 ALERT: PASS: window.HTMLTableElement should be 'function HTMLTableElement() {    [native code]}' and is.
    68 ALERT: PASS: window.HTMLTableRowElement should be 'function HTMLTableRowElement() {    [native code]}' and is.
    69 ALERT: PASS: window.HTMLTableSectionElement should be 'function HTMLTableSectionElement() {    [native code]}' and is.
    70 ALERT: PASS: window.HTMLTextAreaElement should be 'function HTMLTextAreaElement() {    [native code]}' and is.
    71 ALERT: PASS: window.HTMLTitleElement should be 'function HTMLTitleElement() {    [native code]}' and is.
    72 ALERT: PASS: window.HTMLUListElement should be 'function HTMLUListElement() {    [native code]}' and is.
    73 ALERT: PASS: window.MutationEvent should be 'function MutationEvent() {    [native code]}' and is.
    74 ALERT: PASS: window.Node should be 'function Node() {    [native code]}' and is.
    75 ALERT: PASS: window.NodeFilter should be 'function NodeFilter() {    [native code]}' and is.
    76 ALERT: PASS: window.ProcessingInstruction should be 'function ProcessingInstruction() {    [native code]}' and is.
    77 ALERT: PASS: window.Range should be 'function Range() {    [native code]}' and is.
    78 ALERT: PASS: window.RangeError should be 'function RangeError() {    [native code]}' and is.
    79 ALERT: PASS: window.RangeException should be 'undefined' and is.
    80 ALERT: PASS: window.ReferenceError should be 'function ReferenceError() {    [native code]}' and is.
    81 ALERT: PASS: window.SyntaxError should be 'function SyntaxError() {    [native code]}' and is.
    82 ALERT: PASS: window.Text should be 'function Text() {    [native code]}' and is.
    83 ALERT: PASS: window.TypeError should be 'function TypeError() {    [native code]}' and is.
    84 ALERT: PASS: window.URIError should be 'function URIError() {    [native code]}' and is.
    85 ALERT: PASS: window.XMLDocument should be 'function XMLDocument() {    [native code]}' and is.
    86 ALERT: PASS: window.XMLSerializer should be 'function XMLSerializer() {    [native code]}' and is.
    87 ALERT: PASS: window.XPathEvaluator should be 'function XPathEvaluator() {    [native code]}' and is.
    88 ALERT: PASS: window.XPathResult should be 'function XPathResult() {    [native code]}' and is.
    89 ALERT: PASS: window.clientInformation should be '[object Navigator]' and is.
    90 ALERT: PASS: window.closed should be 'false' and is.
    91 ALERT: PASS: window.console should be '[object console]' and is.
    92 ALERT: PASS: window.crypto should be '[object Crypto]' and is.
    93 ALERT: PASS: window.defaultStatus should be '' and is.
    94 ALERT: PASS: window.defaultstatus should be '' and is.
    95 ALERT: PASS: window.devicePixelRatio should be '1' and is.
    96 ALERT: PASS: window.document should be '[object HTMLDocument]' and is.
    97 ALERT: PASS: window.embeds should be 'undefined' and is.
    98 ALERT: PASS: window.event should be 'undefined' and is.
     2CONSOLE MESSAGE: PASS: window.Attr should be 'function Attr() {    [native code]}' and is.
     3CONSOLE MESSAGE: PASS: window.CDATASection should be 'function CDATASection() {    [native code]}' and is.
     4CONSOLE MESSAGE: PASS: window.CharacterData should be 'function CharacterData() {    [native code]}' and is.
     5CONSOLE MESSAGE: PASS: window.Comment should be 'function Comment() {    [native code]}' and is.
     6CONSOLE MESSAGE: PASS: window.CSSPrimitiveValue should be 'function CSSPrimitiveValue() {    [native code]}' and is.
     7CONSOLE MESSAGE: PASS: window.CSSRule should be 'function CSSRule() {    [native code]}' and is.
     8CONSOLE MESSAGE: PASS: window.CSSStyleDeclaration should be 'function CSSStyleDeclaration() {    [native code]}' and is.
     9CONSOLE MESSAGE: PASS: window.CSSValue should be 'function CSSValue() {    [native code]}' and is.
     10CONSOLE MESSAGE: PASS: window.Document should be 'function Document() {    [native code]}' and is.
     11CONSOLE MESSAGE: PASS: window.DocumentFragment should be 'function DocumentFragment() {    [native code]}' and is.
     12CONSOLE MESSAGE: PASS: window.DocumentType should be 'function DocumentType() {    [native code]}' and is.
     13CONSOLE MESSAGE: PASS: window.DOMException should be 'function DOMException() {    [native code]}' and is.
     14CONSOLE MESSAGE: PASS: window.DOMImplementation should be 'function DOMImplementation() {    [native code]}' and is.
     15CONSOLE MESSAGE: PASS: window.DOMParser should be 'function DOMParser() {    [native code]}' and is.
     16CONSOLE MESSAGE: PASS: window.Element should be 'function Element() {    [native code]}' and is.
     17CONSOLE MESSAGE: PASS: window.EvalError should be 'function EvalError() {    [native code]}' and is.
     18CONSOLE MESSAGE: PASS: window.Event should be 'function Event() {    [native code]}' and is.
     19CONSOLE MESSAGE: PASS: window.HTMLAnchorElement should be 'function HTMLAnchorElement() {    [native code]}' and is.
     20CONSOLE MESSAGE: PASS: window.HTMLAppletElement should be 'undefined' and is.
     21CONSOLE MESSAGE: PASS: window.HTMLAreaElement should be 'function HTMLAreaElement() {    [native code]}' and is.
     22CONSOLE MESSAGE: PASS: window.HTMLBaseElement should be 'function HTMLBaseElement() {    [native code]}' and is.
     23CONSOLE MESSAGE: PASS: window.HTMLBodyElement should be 'function HTMLBodyElement() {    [native code]}' and is.
     24CONSOLE MESSAGE: PASS: window.HTMLBRElement should be 'function HTMLBRElement() {    [native code]}' and is.
     25CONSOLE MESSAGE: PASS: window.HTMLButtonElement should be 'function HTMLButtonElement() {    [native code]}' and is.
     26CONSOLE MESSAGE: PASS: window.HTMLCanvasElement should be 'function HTMLCanvasElement() {    [native code]}' and is.
     27CONSOLE MESSAGE: PASS: window.HTMLDirectoryElement should be 'function HTMLDirectoryElement() {    [native code]}' and is.
     28CONSOLE MESSAGE: PASS: window.HTMLDivElement should be 'function HTMLDivElement() {    [native code]}' and is.
     29CONSOLE MESSAGE: PASS: window.HTMLDListElement should be 'function HTMLDListElement() {    [native code]}' and is.
     30CONSOLE MESSAGE: PASS: window.HTMLDocument should be 'function HTMLDocument() {    [native code]}' and is.
     31CONSOLE MESSAGE: PASS: window.HTMLElement should be 'function HTMLElement() {    [native code]}' and is.
     32CONSOLE MESSAGE: PASS: window.HTMLFieldSetElement should be 'function HTMLFieldSetElement() {    [native code]}' and is.
     33CONSOLE MESSAGE: PASS: window.HTMLFontElement should be 'function HTMLFontElement() {    [native code]}' and is.
     34CONSOLE MESSAGE: PASS: window.HTMLFormElement should be 'function HTMLFormElement() {    [native code]}' and is.
     35CONSOLE MESSAGE: PASS: window.HTMLFrameElement should be 'function HTMLFrameElement() {    [native code]}' and is.
     36CONSOLE MESSAGE: PASS: window.HTMLFrameSetElement should be 'function HTMLFrameSetElement() {    [native code]}' and is.
     37CONSOLE MESSAGE: PASS: window.HTMLHeadElement should be 'function HTMLHeadElement() {    [native code]}' and is.
     38CONSOLE MESSAGE: PASS: window.HTMLHeadingElement should be 'function HTMLHeadingElement() {    [native code]}' and is.
     39CONSOLE MESSAGE: PASS: window.HTMLHRElement should be 'function HTMLHRElement() {    [native code]}' and is.
     40CONSOLE MESSAGE: PASS: window.HTMLHtmlElement should be 'function HTMLHtmlElement() {    [native code]}' and is.
     41CONSOLE MESSAGE: PASS: window.HTMLIFrameElement should be 'function HTMLIFrameElement() {    [native code]}' and is.
     42CONSOLE MESSAGE: PASS: window.HTMLImageElement should be 'function HTMLImageElement() {    [native code]}' and is.
     43CONSOLE MESSAGE: PASS: window.HTMLInputElement should be 'function HTMLInputElement() {    [native code]}' and is.
     44CONSOLE MESSAGE: PASS: window.HTMLIsIndexElement should be 'undefined' and is.
     45CONSOLE MESSAGE: PASS: window.HTMLLabelElement should be 'function HTMLLabelElement() {    [native code]}' and is.
     46CONSOLE MESSAGE: PASS: window.HTMLLegendElement should be 'function HTMLLegendElement() {    [native code]}' and is.
     47CONSOLE MESSAGE: PASS: window.HTMLLIElement should be 'function HTMLLIElement() {    [native code]}' and is.
     48CONSOLE MESSAGE: PASS: window.HTMLLinkElement should be 'function HTMLLinkElement() {    [native code]}' and is.
     49CONSOLE MESSAGE: PASS: window.HTMLMapElement should be 'function HTMLMapElement() {    [native code]}' and is.
     50CONSOLE MESSAGE: PASS: window.HTMLMarqueeElement should be 'function HTMLMarqueeElement() {    [native code]}' and is.
     51CONSOLE MESSAGE: PASS: window.HTMLMenuElement should be 'function HTMLMenuElement() {    [native code]}' and is.
     52CONSOLE MESSAGE: PASS: window.HTMLMetaElement should be 'function HTMLMetaElement() {    [native code]}' and is.
     53CONSOLE MESSAGE: PASS: window.HTMLModElement should be 'function HTMLModElement() {    [native code]}' and is.
     54CONSOLE MESSAGE: PASS: window.HTMLOListElement should be 'function HTMLOListElement() {    [native code]}' and is.
     55CONSOLE MESSAGE: PASS: window.HTMLOptGroupElement should be 'function HTMLOptGroupElement() {    [native code]}' and is.
     56CONSOLE MESSAGE: PASS: window.HTMLOptionElement should be 'function HTMLOptionElement() {    [native code]}' and is.
     57CONSOLE MESSAGE: PASS: window.HTMLParagraphElement should be 'function HTMLParagraphElement() {    [native code]}' and is.
     58CONSOLE MESSAGE: PASS: window.HTMLParamElement should be 'function HTMLParamElement() {    [native code]}' and is.
     59CONSOLE MESSAGE: PASS: window.HTMLPreElement should be 'function HTMLPreElement() {    [native code]}' and is.
     60CONSOLE MESSAGE: PASS: window.HTMLQuoteElement should be 'function HTMLQuoteElement() {    [native code]}' and is.
     61CONSOLE MESSAGE: PASS: window.HTMLScriptElement should be 'function HTMLScriptElement() {    [native code]}' and is.
     62CONSOLE MESSAGE: PASS: window.HTMLSelectElement should be 'function HTMLSelectElement() {    [native code]}' and is.
     63CONSOLE MESSAGE: PASS: window.HTMLStyleElement should be 'function HTMLStyleElement() {    [native code]}' and is.
     64CONSOLE MESSAGE: PASS: window.HTMLTableCaptionElement should be 'function HTMLTableCaptionElement() {    [native code]}' and is.
     65CONSOLE MESSAGE: PASS: window.HTMLTableCellElement should be 'function HTMLTableCellElement() {    [native code]}' and is.
     66CONSOLE MESSAGE: PASS: window.HTMLTableColElement should be 'function HTMLTableColElement() {    [native code]}' and is.
     67CONSOLE MESSAGE: PASS: window.HTMLTableElement should be 'function HTMLTableElement() {    [native code]}' and is.
     68CONSOLE MESSAGE: PASS: window.HTMLTableRowElement should be 'function HTMLTableRowElement() {    [native code]}' and is.
     69CONSOLE MESSAGE: PASS: window.HTMLTableSectionElement should be 'function HTMLTableSectionElement() {    [native code]}' and is.
     70CONSOLE MESSAGE: PASS: window.HTMLTextAreaElement should be 'function HTMLTextAreaElement() {    [native code]}' and is.
     71CONSOLE MESSAGE: PASS: window.HTMLTitleElement should be 'function HTMLTitleElement() {    [native code]}' and is.
     72CONSOLE MESSAGE: PASS: window.HTMLUListElement should be 'function HTMLUListElement() {    [native code]}' and is.
     73CONSOLE MESSAGE: PASS: window.MutationEvent should be 'function MutationEvent() {    [native code]}' and is.
     74CONSOLE MESSAGE: PASS: window.Node should be 'function Node() {    [native code]}' and is.
     75CONSOLE MESSAGE: PASS: window.NodeFilter should be 'function NodeFilter() {    [native code]}' and is.
     76CONSOLE MESSAGE: PASS: window.ProcessingInstruction should be 'function ProcessingInstruction() {    [native code]}' and is.
     77CONSOLE MESSAGE: PASS: window.Range should be 'function Range() {    [native code]}' and is.
     78CONSOLE MESSAGE: PASS: window.RangeError should be 'function RangeError() {    [native code]}' and is.
     79CONSOLE MESSAGE: PASS: window.RangeException should be 'undefined' and is.
     80CONSOLE MESSAGE: PASS: window.ReferenceError should be 'function ReferenceError() {    [native code]}' and is.
     81CONSOLE MESSAGE: PASS: window.SyntaxError should be 'function SyntaxError() {    [native code]}' and is.
     82CONSOLE MESSAGE: PASS: window.Text should be 'function Text() {    [native code]}' and is.
     83CONSOLE MESSAGE: PASS: window.TypeError should be 'function TypeError() {    [native code]}' and is.
     84CONSOLE MESSAGE: PASS: window.URIError should be 'function URIError() {    [native code]}' and is.
     85CONSOLE MESSAGE: PASS: window.XMLDocument should be 'function XMLDocument() {    [native code]}' and is.
     86CONSOLE MESSAGE: PASS: window.XMLSerializer should be 'function XMLSerializer() {    [native code]}' and is.
     87CONSOLE MESSAGE: PASS: window.XPathEvaluator should be 'function XPathEvaluator() {    [native code]}' and is.
     88CONSOLE MESSAGE: PASS: window.XPathResult should be 'function XPathResult() {    [native code]}' and is.
     89CONSOLE MESSAGE: PASS: window.clientInformation should be '[object Navigator]' and is.
     90CONSOLE MESSAGE: PASS: window.closed should be 'false' and is.
     91CONSOLE MESSAGE: PASS: window.console should be '[object console]' and is.
     92CONSOLE MESSAGE: PASS: window.crypto should be '[object Crypto]' and is.
     93CONSOLE MESSAGE: PASS: window.defaultStatus should be '' and is.
     94CONSOLE MESSAGE: PASS: window.defaultstatus should be '' and is.
     95CONSOLE MESSAGE: PASS: window.devicePixelRatio should be '1' and is.
     96CONSOLE MESSAGE: PASS: window.document should be '[object HTMLDocument]' and is.
     97CONSOLE MESSAGE: PASS: window.embeds should be 'undefined' and is.
     98CONSOLE MESSAGE: PASS: window.event should be 'undefined' and is.
    9999CONSOLE MESSAGE: Blocked a frame with origin "http://localhost:8000" from accessing a frame with origin "http://127.0.0.1:8000". Protocols, domains, and ports must match.
    100 ALERT: PASS: window.frameElement should be 'null' and is.
    101 ALERT: PASS: window.frames should be '[object Window]' and is.
    102 ALERT: PASS: window.history should be '[object History]' and is.
    103 ALERT: PASS: window.images should be 'undefined' and is.
    104 ALERT: PASS: window.innerHeight should be '150' and is.
    105 ALERT: PASS: window.innerWidth should be '300' and is.
    106 ALERT: PASS: window.length should be '0' and is.
    107 ALERT: PASS: window.locationbar should be '[object BarProp]' and is.
    108 ALERT: PASS: window.menubar should be '[object BarProp]' and is.
    109 ALERT: PASS: window.name should be '' and is.
    110 ALERT: PASS: window.navigator should be '[object Navigator]' and is.
    111 ALERT: PASS: window.offscreenBuffering should be 'true' and is.
    112 ALERT: PASS: window.onabort should be 'null' and is.
    113 ALERT: PASS: window.onbeforeunload should be 'null' and is.
    114 ALERT: PASS: window.onblur should be 'null' and is.
    115 ALERT: PASS: window.onchange should be 'null' and is.
    116 ALERT: PASS: window.onclick should be 'null' and is.
    117 ALERT: PASS: window.ondblclick should be 'null' and is.
    118 ALERT: PASS: window.onerror should be 'null' and is.
    119 ALERT: PASS: window.onfocus should be 'null' and is.
    120 ALERT: PASS: window.onkeydown should be 'null' and is.
    121 ALERT: PASS: window.onkeypress should be 'null' and is.
    122 ALERT: PASS: window.onkeyup should be 'null' and is.
    123 ALERT: PASS: window.onload should be 'null' and is.
    124 ALERT: PASS: window.onmousedown should be 'null' and is.
    125 ALERT: PASS: window.onmousemove should be 'null' and is.
    126 ALERT: PASS: window.onmouseout should be 'null' and is.
    127 ALERT: PASS: window.onmouseover should be 'null' and is.
    128 ALERT: PASS: window.onmouseup should be 'null' and is.
    129 ALERT: PASS: window.onmousewheel should be 'null' and is.
    130 ALERT: PASS: window.onreset should be 'null' and is.
    131 ALERT: PASS: window.onresize should be 'null' and is.
    132 ALERT: PASS: window.onscroll should be 'null' and is.
    133 ALERT: PASS: window.onsearch should be 'null' and is.
    134 ALERT: PASS: window.onselect should be 'null' and is.
    135 ALERT: PASS: window.onsubmit should be 'null' and is.
    136 ALERT: PASS: window.onunload should be 'null' and is.
    137 ALERT: PASS: window.opener should be 'null' and is.
    138 ALERT: PASS: window.outerHeight matched the expected value.
    139 ALERT: PASS: window.outerWidth matched the expected value.
    140 ALERT: PASS: window.pageXOffset should be '0' and is.
    141 ALERT: PASS: window.pageYOffset should be '0' and is.
    142 ALERT: PASS: window.personalbar should be '[object BarProp]' and is.
    143 ALERT: PASS: window.plugins should be 'undefined' and is.
    144 ALERT: PASS: window.screen should be '[object Screen]' and is.
    145 ALERT: PASS: window.screenLeft should be '0' and is.
    146 ALERT: PASS: window.screenTop matched the expected value.
    147 ALERT: PASS: window.screenX should be '0' and is.
    148 ALERT: PASS: window.screenY matched the expected value.
    149 ALERT: PASS: window.scrollbars should be '[object BarProp]' and is.
    150 ALERT: PASS: window.scrollX should be '0' and is.
    151 ALERT: PASS: window.scrollY should be '0' and is.
    152 ALERT: PASS: window.self should be '[object Window]' and is.
    153 ALERT: PASS: window.status should be '' and is.
    154 ALERT: PASS: window.statusbar should be '[object BarProp]' and is.
    155 ALERT: PASS: window.toolbar should be '[object BarProp]' and is.
    156 ALERT: PASS: window.window should be '[object Window]' and is.
    157 ALERT: PASS: window.parent should be parentOld and is.
    158 ALERT: PASS: window.top should be topOld and is.
    159 ALERT: PASS: window.addEventListener should be 'function addEventListener() {    [native code]}' and is.
    160 ALERT: PASS: window.alert should be 'function alert() {    [native code]}' and is.
    161 ALERT: PASS: window.atob should be 'function atob() {    [native code]}' and is.
    162 ALERT: PASS: window.btoa should be 'function btoa() {    [native code]}' and is.
    163 ALERT: PASS: window.captureEvents should be 'function captureEvents() {    [native code]}' and is.
    164 ALERT: PASS: window.clearInterval should be 'function clearInterval() {    [native code]}' and is.
    165 ALERT: PASS: window.clearTimeout should be 'function clearTimeout() {    [native code]}' and is.
    166 ALERT: PASS: window.confirm should be 'function confirm() {    [native code]}' and is.
    167 ALERT: PASS: window.eval should be 'function eval() {    [native code]}' and is.
    168 ALERT: PASS: window.find should be 'function find() {    [native code]}' and is.
    169 ALERT: PASS: window.getComputedStyle should be 'function getComputedStyle() {    [native code]}' and is.
    170 ALERT: PASS: window.getMatchedCSSRules should be 'function getMatchedCSSRules() {    [native code]}' and is.
    171 ALERT: PASS: window.getSelection should be 'function getSelection() {    [native code]}' and is.
    172 ALERT: PASS: window.moveBy should be 'function moveBy() {    [native code]}' and is.
    173 ALERT: PASS: window.moveTo should be 'function moveTo() {    [native code]}' and is.
    174 ALERT: PASS: window.open should be 'function open() {    [native code]}' and is.
    175 ALERT: PASS: window.print should be 'function print() {    [native code]}' and is.
    176 ALERT: PASS: window.prompt should be 'function prompt() {    [native code]}' and is.
    177 ALERT: PASS: window.releaseEvents should be 'function releaseEvents() {    [native code]}' and is.
    178 ALERT: PASS: window.removeEventListener should be 'function removeEventListener() {    [native code]}' and is.
    179 ALERT: PASS: window.resizeBy should be 'function resizeBy() {    [native code]}' and is.
    180 ALERT: PASS: window.resizeTo should be 'function resizeTo() {    [native code]}' and is.
    181 ALERT: PASS: window.scroll should be 'function scroll() {    [native code]}' and is.
    182 ALERT: PASS: window.scrollBy should be 'function scrollBy() {    [native code]}' and is.
    183 ALERT: PASS: window.scrollTo should be 'function scrollTo() {    [native code]}' and is.
    184 ALERT: PASS: window.setInterval should be 'function setInterval() {    [native code]}' and is.
    185 ALERT: PASS: window.setTimeout should be 'function setTimeout() {    [native code]}' and is.
    186 ALERT: PASS: window.showModalDialog matched the expected value.
    187 ALERT: PASS: window.stop should be 'function stop() {    [native code]}' and is.
     100CONSOLE MESSAGE: PASS: window.frameElement should be 'null' and is.
     101CONSOLE MESSAGE: PASS: window.frames should be '[object Window]' and is.
     102CONSOLE MESSAGE: PASS: window.history should be '[object History]' and is.
     103CONSOLE MESSAGE: PASS: window.images should be 'undefined' and is.
     104CONSOLE MESSAGE: PASS: window.innerHeight should be '150' and is.
     105CONSOLE MESSAGE: PASS: window.innerWidth should be '300' and is.
     106CONSOLE MESSAGE: PASS: window.length should be '0' and is.
     107CONSOLE MESSAGE: PASS: window.locationbar should be '[object BarProp]' and is.
     108CONSOLE MESSAGE: PASS: window.menubar should be '[object BarProp]' and is.
     109CONSOLE MESSAGE: PASS: window.name should be '' and is.
     110CONSOLE MESSAGE: PASS: window.navigator should be '[object Navigator]' and is.
     111CONSOLE MESSAGE: PASS: window.offscreenBuffering should be 'true' and is.
     112CONSOLE MESSAGE: PASS: window.onabort should be 'null' and is.
     113CONSOLE MESSAGE: PASS: window.onbeforeunload should be 'null' and is.
     114CONSOLE MESSAGE: PASS: window.onblur should be 'null' and is.
     115CONSOLE MESSAGE: PASS: window.onchange should be 'null' and is.
     116CONSOLE MESSAGE: PASS: window.onclick should be 'null' and is.
     117CONSOLE MESSAGE: PASS: window.ondblclick should be 'null' and is.
     118CONSOLE MESSAGE: PASS: window.onerror should be 'null' and is.
     119CONSOLE MESSAGE: PASS: window.onfocus should be 'null' and is.
     120CONSOLE MESSAGE: PASS: window.onkeydown should be 'null' and is.
     121CONSOLE MESSAGE: PASS: window.onkeypress should be 'null' and is.
     122CONSOLE MESSAGE: PASS: window.onkeyup should be 'null' and is.
     123CONSOLE MESSAGE: PASS: window.onload should be 'null' and is.
     124CONSOLE MESSAGE: PASS: window.onmousedown should be 'null' and is.
     125CONSOLE MESSAGE: PASS: window.onmousemove should be 'null' and is.
     126CONSOLE MESSAGE: PASS: window.onmouseout should be 'null' and is.
     127CONSOLE MESSAGE: PASS: window.onmouseover should be 'null' and is.
     128CONSOLE MESSAGE: PASS: window.onmouseup should be 'null' and is.
     129CONSOLE MESSAGE: PASS: window.onmousewheel should be 'null' and is.
     130CONSOLE MESSAGE: PASS: window.onreset should be 'null' and is.
     131CONSOLE MESSAGE: PASS: window.onresize should be 'null' and is.
     132CONSOLE MESSAGE: PASS: window.onscroll should be 'null' and is.
     133CONSOLE MESSAGE: PASS: window.onsearch should be 'null' and is.
     134CONSOLE MESSAGE: PASS: window.onselect should be 'null' and is.
     135CONSOLE MESSAGE: PASS: window.onsubmit should be 'null' and is.
     136CONSOLE MESSAGE: PASS: window.onunload should be 'null' and is.
     137CONSOLE MESSAGE: PASS: window.opener should be 'null' and is.
     138CONSOLE MESSAGE: PASS: window.outerHeight matched the expected value.
     139CONSOLE MESSAGE: PASS: window.outerWidth matched the expected value.
     140CONSOLE MESSAGE: PASS: window.pageXOffset should be '0' and is.
     141CONSOLE MESSAGE: PASS: window.pageYOffset should be '0' and is.
     142CONSOLE MESSAGE: PASS: window.personalbar should be '[object BarProp]' and is.
     143CONSOLE MESSAGE: PASS: window.plugins should be 'undefined' and is.
     144CONSOLE MESSAGE: PASS: window.screen should be '[object Screen]' and is.
     145CONSOLE MESSAGE: PASS: window.screenLeft should be '0' and is.
     146CONSOLE MESSAGE: PASS: window.screenTop matched the expected value.
     147CONSOLE MESSAGE: PASS: window.screenX should be '0' and is.
     148CONSOLE MESSAGE: PASS: window.screenY matched the expected value.
     149CONSOLE MESSAGE: PASS: window.scrollbars should be '[object BarProp]' and is.
     150CONSOLE MESSAGE: PASS: window.scrollX should be '0' and is.
     151CONSOLE MESSAGE: PASS: window.scrollY should be '0' and is.
     152CONSOLE MESSAGE: PASS: window.self should be '[object Window]' and is.
     153CONSOLE MESSAGE: PASS: window.status should be '' and is.
     154CONSOLE MESSAGE: PASS: window.statusbar should be '[object BarProp]' and is.
     155CONSOLE MESSAGE: PASS: window.toolbar should be '[object BarProp]' and is.
     156CONSOLE MESSAGE: PASS: window.window should be '[object Window]' and is.
     157CONSOLE MESSAGE: PASS: window.parent should be parentOld and is.
     158CONSOLE MESSAGE: PASS: window.top should be topOld and is.
     159CONSOLE MESSAGE: PASS: window.addEventListener should be 'function addEventListener() {    [native code]}' and is.
     160CONSOLE MESSAGE: PASS: window.alert should be 'function alert() {    [native code]}' and is.
     161CONSOLE MESSAGE: PASS: window.atob should be 'function atob() {    [native code]}' and is.
     162CONSOLE MESSAGE: PASS: window.btoa should be 'function btoa() {    [native code]}' and is.
     163CONSOLE MESSAGE: PASS: window.captureEvents should be 'function captureEvents() {    [native code]}' and is.
     164CONSOLE MESSAGE: PASS: window.clearInterval should be 'function clearInterval() {    [native code]}' and is.
     165CONSOLE MESSAGE: PASS: window.clearTimeout should be 'function clearTimeout() {    [native code]}' and is.
     166CONSOLE MESSAGE: PASS: window.confirm should be 'function confirm() {    [native code]}' and is.
     167CONSOLE MESSAGE: PASS: window.eval should be 'function eval() {    [native code]}' and is.
     168CONSOLE MESSAGE: PASS: window.find should be 'function find() {    [native code]}' and is.
     169CONSOLE MESSAGE: PASS: window.getComputedStyle should be 'function getComputedStyle() {    [native code]}' and is.
     170CONSOLE MESSAGE: PASS: window.getMatchedCSSRules should be 'function getMatchedCSSRules() {    [native code]}' and is.
     171CONSOLE MESSAGE: PASS: window.getSelection should be 'function getSelection() {    [native code]}' and is.
     172CONSOLE MESSAGE: PASS: window.moveBy should be 'function moveBy() {    [native code]}' and is.
     173CONSOLE MESSAGE: PASS: window.moveTo should be 'function moveTo() {    [native code]}' and is.
     174CONSOLE MESSAGE: PASS: window.open should be 'function open() {    [native code]}' and is.
     175CONSOLE MESSAGE: PASS: window.print should be 'function print() {    [native code]}' and is.
     176CONSOLE MESSAGE: PASS: window.prompt should be 'function prompt() {    [native code]}' and is.
     177CONSOLE MESSAGE: PASS: window.releaseEvents should be 'function releaseEvents() {    [native code]}' and is.
     178CONSOLE MESSAGE: PASS: window.removeEventListener should be 'function removeEventListener() {    [native code]}' and is.
     179CONSOLE MESSAGE: PASS: window.resizeBy should be 'function resizeBy() {    [native code]}' and is.
     180CONSOLE MESSAGE: PASS: window.resizeTo should be 'function resizeTo() {    [native code]}' and is.
     181CONSOLE MESSAGE: PASS: window.scroll should be 'function scroll() {    [native code]}' and is.
     182CONSOLE MESSAGE: PASS: window.scrollBy should be 'function scrollBy() {    [native code]}' and is.
     183CONSOLE MESSAGE: PASS: window.scrollTo should be 'function scrollTo() {    [native code]}' and is.
     184CONSOLE MESSAGE: PASS: window.setInterval should be 'function setInterval() {    [native code]}' and is.
     185CONSOLE MESSAGE: PASS: window.setTimeout should be 'function setTimeout() {    [native code]}' and is.
     186CONSOLE MESSAGE: PASS: window.showModalDialog matched the expected value.
     187CONSOLE MESSAGE: PASS: window.stop should be 'function stop() {    [native code]}' and is.
    188188ALERT: continue test in parent frame
    189189This test checks cross-frame access security of window attribute setters (rdar://problem/5326791).
  • trunk/LayoutTests/http/tests/security/data-url-inline.css-expected.txt

    r61391 r272607  
    1 ALERT: 1 rules found
     1CONSOLE MESSAGE: 1 rules found
    22This test ensures that a data URL can access its own inline style sheets. Sorry for the obscurity of the test case, but it's the repro from Bug 32309, which has an "unobfuscated" version of the code.
    33
  • trunk/LayoutTests/http/tests/security/data-url-inline.css.html

    r120174 r272607  
    88has an "unobfuscated" version of the code.</p>
    99<p>This test passes if it alerts that it found 1 rule.</p>
    10 <iframe src="data:text/html;base64,PGh0bWw+CiAgPHN0eWxlPgogICAgYm9keSB7CiAgICAgIGJhY2tncm91bmQ6IGdyZWVuOwogICAgfQogIDwvc3R5bGU+CiAgPGJvZHk+CiAgICA8c2NyaXB0PgogICAgICB2YXIgc3R5bGVzaGVldHMgPSBkb2N1bWVudC5zdHlsZVNoZWV0czsKICAgICAgdmFyIHN0eWxlc2hlZXQgPSBzdHlsZXNoZWV0c1tzdHlsZXNoZWV0cy5sZW5ndGgtMV07CiAgICAgIHZhciBydWxlcyA9IHN0eWxlc2hlZXQuY3NzUnVsZXM7CiAgICAgIGFsZXJ0KHJ1bGVzLmxlbmd0aCArICcgcnVsZXMgZm91bmQnKTsKICAgIDwvc2NyaXB0PgogIDwvYm9keT4KPC9odG1sPgo="></iframe>
     10<iframe src="data:text/html;base64,PGh0bWw+DQogIDxzdHlsZT4NCiAgICBib2R5IHsNCiAgICAgIGJhY2tncm91bmQ6IGdyZWVuOw0KICAgIH0NCiAgPC9zdHlsZT4NCiAgPGJvZHk+DQogICAgPHNjcmlwdD4NCiAgICAgIHZhciBzdHlsZXNoZWV0cyA9IGRvY3VtZW50LnN0eWxlU2hlZXRzOw0KICAgICAgdmFyIHN0eWxlc2hlZXQgPSBzdHlsZXNoZWV0c1tzdHlsZXNoZWV0cy5sZW5ndGgtMV07DQogICAgICB2YXIgcnVsZXMgPSBzdHlsZXNoZWV0LmNzc1J1bGVzOw0KICAgICAgY29uc29sZS5sb2cocnVsZXMubGVuZ3RoICsgJyBydWxlcyBmb3VuZCcpOw0KICAgIDwvc2NyaXB0Pg0KICA8L2JvZHk+DQo8L2h0bWw+DQo="></iframe>
  • trunk/LayoutTests/http/tests/security/dataURL/resources/foreign-domain-data-url-accessor-iframe.html

    r205136 r272607  
    1212            +             "try {"
    1313            +                 "top.document.getElementById('accessMe').innerHTML = 'FAIL: Cross frame access from a data: URL on a different domain was allowed';"
    14             +                 "alert('FAIL: No exception thrown.');"
     14            +                 "console.log('FAIL: No exception thrown.');"
    1515            +             "} catch (e) {"
    1616            +                 "console.log(e);"
    17             +                 "alert('PASS: Exception thrown successfully.');"
     17            +                 "console.log('PASS: Exception thrown successfully.');"
    1818            +             "}"
    1919            +             "if (window.testRunner)"
  • trunk/LayoutTests/http/tests/security/dataURL/resources/foreign-domain-data-url-accessor-opened-frame.html

    r205136 r272607  
    1111            +             "try {"
    1212            +                 "parent.opener.document.getElementById('accessMe').innerHTML = 'FAIL: Cross frame access from a data: URL on a different domain was allowed';"
    13             +                 "alert('FAIL: No exception thrown.');"
     13            +                 "console.log('FAIL: No exception thrown.');"
    1414            +             "} catch (e) {"
    1515            +                 "console.log(e);"
    16             +                 "alert('PASS: Exception thrown successfully.');"
     16            +                 "console.log('PASS: Exception thrown successfully.');"
    1717            +             "}"
    1818            +             "if (window.testRunner)"
  • trunk/LayoutTests/http/tests/security/dataURL/xss-DENIED-from-data-url-in-foreign-domain-subframe-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: SecurityError: Blocked a frame with origin "null" from accessing a cross-origin frame. Protocols, domains, and ports must match.
    2 ALERT: PASS: Exception thrown successfully.
     2CONSOLE MESSAGE: PASS: Exception thrown successfully.
    33The scenario for this test is that you have an iframe with content from a foreign domain. In that foreign content is an iframe which loads a data: URL. This tests that the data: URL loaded iframe does not have access to the main frame using top.document.
    44
  • trunk/LayoutTests/http/tests/security/dataURL/xss-DENIED-from-data-url-in-foreign-domain-window-open-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: SecurityError: Blocked a frame with origin "null" from accessing a cross-origin frame. Protocols, domains, and ports must match.
    2 ALERT: PASS: Exception thrown successfully.
     2CONSOLE MESSAGE: PASS: Exception thrown successfully.
    33Opener Frame
    44
  • trunk/LayoutTests/http/tests/security/drag-drop-different-origin-expected.txt

    r267644 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22Dragme
  • trunk/LayoutTests/http/tests/security/drag-drop-local-file-expected.txt

    r267644 r272607  
    11CONSOLE MESSAGE: Not allowed to drag local resource: foobar
    2 ALERT: PASS
     2CONSOLE MESSAGE: PASS
    33Dragme
  • trunk/LayoutTests/http/tests/security/drag-drop-same-unique-origin-expected.txt

    r72644 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/mixedContent/resources/frame-with-insecure-websocket.html

    r187556 r272607  
    66
    77function onSocketOpened() {
    8     alert("WebSocket connection opened.");
     8    console.log("WebSocket connection opened.");
    99    finishJSTest();
    1010}
    1111
    1212function onSocketError() {
    13     alert("WebSocket connection failed.");
     13    console.log("WebSocket connection failed.");
    1414    ws.close();
    1515    finishJSTest();
     
    1717
    1818function onSocketClosed() {
    19     alert("WebSocket closed.");
     19    console.log("WebSocket closed.");
    2020    finishJSTest();
    2121}
     
    2727    ws.onclose = onSocketClosed;
    2828} catch (e) {
    29     alert("Test failed: exception thrown");
     29    console.log("Test failed: exception thrown");
    3030    finishJSTest();
    3131}
  • trunk/LayoutTests/http/tests/security/mixedContent/websocket/insecure-websocket-in-iframe-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: [blocked] The page at https://127.0.0.1:8443/security/mixedContent/resources/frame-with-insecure-websocket.html was not allowed to run insecure content from ws://127.0.0.1:8880/websocket/tests/hybi/echo.
    22
    3 ALERT: WebSocket connection failed.
     3CONSOLE MESSAGE: WebSocket connection failed.
    44CONSOLE MESSAGE: WebSocket connection failed: WebSocket is closed before the connection is established.
    55This test loads an iframe that creates an insecure WebSocket connection. We should block the connection and trigger a mixed content callback because the main frame is HTTPS, but the data sent over the socket could be recorded or controlled by an attacker.
  • trunk/LayoutTests/http/tests/security/mixedContent/websocket/insecure-websocket-in-main-frame-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: [blocked] The page at https://127.0.0.1:8443/security/mixedContent/resources/frame-with-insecure-websocket.html was not allowed to run insecure content from ws://127.0.0.1:8880/websocket/tests/hybi/echo.
    22
    3 ALERT: WebSocket connection failed.
     3CONSOLE MESSAGE: WebSocket connection failed.
    44CONSOLE MESSAGE: WebSocket connection failed: WebSocket is closed before the connection is established.
    55This test opens a window that connects to an insecure ws:// WebSocket. We should block the connection and trigger a mixed content callback because the main frame is HTTPS, but the data sent over the socket could be recorded or controlled by an attacker.
  • trunk/LayoutTests/http/tests/security/no-indexeddb-from-sandbox-expected.txt

    r141621 r272607  
    1 ALERT: PASS: db.open() threw a SECURITY_ERR!
     1CONSOLE MESSAGE: PASS: db.open() threw a SECURITY_ERR!
    22
  • trunk/LayoutTests/http/tests/security/no-indexeddb-from-sandbox.html

    r221193 r272607  
    99             try {
    1010                 db.open('test');
    11                  alert('FAIL: db.open() should throw a SECURITY_ERR in a sandbox.');
     11                 console.log('FAIL: db.open() should throw a SECURITY_ERR in a sandbox.');
    1212             } catch (e) {
    1313                 if (e.code === DOMException.SECURITY_ERR)
    14                      alert('PASS: db.open() threw a SECURITY_ERR!');
     14                     console.log('PASS: db.open() threw a SECURITY_ERR!');
    1515                 else
    16                      alert('FAIL: db.open() threw a ' + e.name);
     16                     console.log('FAIL: db.open() threw a ' + e.name);
    1717             }
    1818         </script>"
  • trunk/LayoutTests/http/tests/security/no-popup-from-sandbox-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: Blocked opening 'about:blank' in a new window because the request was made in a sandboxed frame whose 'allow-popups' permission is not set.
    2 ALERT: PASS
     2CONSOLE MESSAGE: PASS
    33To run this test outside of DumpRenderTree, please disable your popup blocker!
    44
  • trunk/LayoutTests/http/tests/security/no-popup-from-sandbox-top-expected.txt

    r259900 r272607  
    1 CONSOLE MESSAGE: Unsafe JavaScript attempt to initiate navigation for frame with URL 'http://127.0.0.1:8000/security/no-popup-from-sandbox-top.html' from frame with URL 'data:text/html,       <script>       var win = window.open('about:blank', '_top');       alert(win ?%20'FAIL'%20:%20'PASS');%20%20%20%20%20%20%20%3C/script%3E'. The frame attempting navigation of the top-level window is sandboxed, but the 'allow-top-navigation' flag is not set.
     1CONSOLE MESSAGE: Unsafe JavaScript attempt to initiate navigation for frame with URL 'http://127.0.0.1:8000/security/no-popup-from-sandbox-top.html' from frame with URL 'data:text/html,       <script>       var win = window.open('about:blank', '_top');       console.log(win ?%20'FAIL'%20:%20'PASS');%20%20%20%20%20%20%20%3C/script%3E'. The frame attempting navigation of the top-level window is sandboxed, but the 'allow-top-navigation' flag is not set.
    22
    3 ALERT: PASS
     3CONSOLE MESSAGE: PASS
    44To run this test outside of DumpRenderTree, please disable your popup blocker!
    55
  • trunk/LayoutTests/http/tests/security/no-popup-from-sandbox-top.html

    r221193 r272607  
    1010       <script>
    1111       var win = window.open('about:blank', '_top');
    12        alert(win ? 'FAIL' : 'PASS');
     12       console.log(win ? 'FAIL' : 'PASS');
    1313       </script>"
    1414  ></iframe>
  • trunk/LayoutTests/http/tests/security/no-popup-from-sandbox.html

    r221193 r272607  
    1010       <script>
    1111       var win = window.open('about:blank', '_blank');
    12        alert(win ? 'FAIL' : 'PASS');
     12       console.log(win ? 'FAIL' : 'PASS');
    1313       </script>"
    1414  ></iframe>
  • trunk/LayoutTests/http/tests/security/popup-allowed-by-sandbox-when-allowed-expected.txt

    r99301 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22To run this test outside of DumpRenderTree, please disable your popup blocker!
    33
  • trunk/LayoutTests/http/tests/security/popup-allowed-by-sandbox-when-allowed.html

    r221193 r272607  
    1212       <script>
    1313       var win = window.open('data:text/html,<script>if (window.testRunner) testRunner.notifyDone();<\/script>', '_blank');
    14        alert(win ? 'PASS' : 'FAIL');
     14       console.log(win ? 'PASS' : 'FAIL');
    1515       </script>"
    1616  ></iframe>
  • trunk/LayoutTests/http/tests/security/resources/cross-frame-iframe-for-put-test.html

    r223556 r272607  
    3232            message = String(message).replace(/\n/g, "");
    3333            if (window.testRunner) {
    34                 alert(message);
     34                console.log(message);
    3535            } else {
    3636                log(message);
     
    409409            // Using shouldBe for parent and top causes extraneous warnings due to cross-orgin toString'ing.
    410410            if (window.parent === parentOld) {
    411                 alert("PASS: window.parent should be parentOld and is.");
     411                console.log("PASS: window.parent should be parentOld and is.");
    412412            } else {
    413                 alert("*** FAIL: window.parent should be parentOld but instead is " + window.parent + ". ***");
     413                console.log("*** FAIL: window.parent should be parentOld but instead is " + window.parent + ". ***");
    414414            }
    415415
    416416            if (window.top === topOld) {
    417                 alert("PASS: window.top should be topOld and is.");
     417                console.log("PASS: window.top should be topOld and is.");
    418418            } else {
    419                 alert("*** FAIL: window.top should be topOld but instead is " + window.top + ". ***");
     419                console.log("*** FAIL: window.top should be topOld but instead is " + window.top + ". ***");
    420420            }
    421421
  • trunk/LayoutTests/http/tests/security/resources/drag-drop-allowed.html

    r120174 r272607  
    2020
    2121    if (document.getElementById("dragme").parentNode.tagName == "SPAN" && document.getElementById("dragme").src.length > 10)
    22         alert("PASS");
     22        console.log("PASS");
    2323    else
    24         alert("FAIL");
     24        console.log("FAIL");
    2525
    2626    testRunner.notifyDone();
  • trunk/LayoutTests/http/tests/security/resources/drag-drop.html

    r120174 r272607  
    55    {
    66        if (document.body.innerHTML.match(/Dragme/i))
    7             alert("FAIL");
     7            console.log("FAIL");
    88        else
    9             alert("PASS");
     9            console.log("PASS");
    1010       
    1111        if (window.testRunner)
  • trunk/LayoutTests/http/tests/security/sandboxed-iframe-ALLOWED-modals.html

    r221193 r272607  
    44</script>
    55<p>This test passes if opening modal dialogs is allowed and no error message is logged in the console.</p>
    6 <iframe sandbox="allow-scripts allow-modals"
    7         src="data:text/html,<script>
    8             alert('MESSAGE');
    9             </script>"></iframe>
    10 <iframe sandbox="allow-scripts allow-modals"
    11         src="data:text/html,<script>
    12             confirm('MESSAGE?');
    13             </script>"></iframe>
    14 <iframe sandbox="allow-scripts allow-modals"
    15         src="data:text/html,<script>
    16             prompt('MESSAGE:', 'DEFAULT');
    17             </script>"></iframe>
    18 <iframe sandbox="allow-scripts allow-modals"
    19         src="data:text/html,<script>
    20             print();
    21             </script>"></iframe>
    22 <iframe sandbox="allow-scripts allow-modals"
    23         src="data:text/html,<script>
    24             document.execCommand('print', true, null);
    25             </script>"></iframe>
     6<iframe sandbox="allow-scripts allow-modals allow-same-origin" src="resources/sandboxed-iframe-ALLOWED-modals-iframe.html"></iframe>
  • trunk/LayoutTests/http/tests/security/xss-DENIED-window-index-assign-expected.txt

    r259900 r272607  
    1 ALERT: undefined
     1CONSOLE MESSAGE: undefined
    22CONSOLE MESSAGE: TypeError: parent[0].f is not a function. (In 'parent[0].f()', 'parent[0].f' is undefined)
    33
  • trunk/LayoutTests/http/tests/security/xss-DENIED-window-index-assign.html

    r153526 r272607  
    66    a: "1",
    77    f: function() {
    8         alert("FAIL: Child called parent.f()");
     8        console.log("FAIL: Child called parent.f()");
    99    }
    1010};
    1111</script>
    12 <iframe src="data:text/html,<script>alert(parent[0].a);</script><script>parent[0].f();</script>"></iframe><br>
     12<iframe src="data:text/html,<script>console.log(parent[0].a);</script><script>parent[0].f();</script>"></iframe><br>
    1313This test passes if the access is forbidden.
  • trunk/LayoutTests/http/tests/security/xss-DENIED-window-name-alert-expected.txt

    r150403 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/xss-DENIED-window-name-alert.html

    r221193 r272607  
    66        src="data:text/html,<script>
    77            window.name='alert2';
    8             alert(top.alert2 === window ? 'PASS' : 'FAIL');
     8            console.log(top.alert2 === window ? 'PASS' : 'FAIL');
    99            </script>"></iframe>
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-control-char-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-head-base-href.pl?q=%3Cbase%20href=%27http://127.0.0.1:8000/sec%01urity/xssAuditor/resources/base-href/%27%3E' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    2 ALERT: This is a safe script.
     2CONSOLE MESSAGE: This is a safe script.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-direct-expected.txt

    r54010 r272607  
    1 ALERT: /XSS/
     1CONSOLE MESSAGE: /XSS/
    22We allow direct injections into base tags to reduce false positives.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-head-base-href.pl?q=%3Cbase%20href=%27http://127.0.0.1:8000/security/xssAuditor/resources/base-href/%27%3E' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    2 ALERT: This is a safe script.
     2CONSOLE MESSAGE: This is a safe script.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-null-char-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-head-base-href.pl?q=%3Cbase%20href=%27http://127.0.0.1:8000/sec%00urity/xssAuditor/resources/base-href/%27%3E' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    2 ALERT: This is a safe script.
     2CONSOLE MESSAGE: This is a safe script.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-safe-expected.txt

    r45642 r272607  
    1 ALERT: This is a safe script.
     1CONSOLE MESSAGE: This is a safe script.
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-safe2-expected.txt

    r45642 r272607  
    1 ALERT: This is a safe script.
     1CONSOLE MESSAGE: This is a safe script.
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-safe3-expected.txt

    r45763 r272607  
    1 ALERT: This is a safe script.
     1CONSOLE MESSAGE: This is a safe script.
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/base-href-scheme-relative-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-head-base-href.pl?q=%3Cbase%20href=%27//127.0.0.1:8000/security/xssAuditor/resources/base-href/%27%3E' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    2 ALERT: This is a safe script.
     2CONSOLE MESSAGE: This is a safe script.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/cached-frame-expected.txt

    r267644 r272607  
    1 CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://127.0.0.1:8000/security/xssAuditor/resources/nph-cached.pl?q=%3cscript%3ealert(/XSS/);%3c/script%3e' because its source code was found within the request. The server sent an 'X-XSS-Protection' header requesting this behavior.
    2 CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://127.0.0.1:8000/security/xssAuditor/resources/nph-cached.pl?q=%3cscript%3ealert(/XSS/);%3c/script%3e' because its source code was found within the request. The server sent an 'X-XSS-Protection' header requesting this behavior.
     1CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://127.0.0.1:8000/security/xssAuditor/resources/nph-cached.pl?q=%3cscript%3econsole.log(/XSS/);%3c/script%3e' because its source code was found within the request. The server sent an 'X-XSS-Protection' header requesting this behavior.
     2CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://127.0.0.1:8000/security/xssAuditor/resources/nph-cached.pl?q=%3cscript%3econsole.log(/XSS/);%3c/script%3e' because its source code was found within the request. The server sent an 'X-XSS-Protection' header requesting this behavior.
    33Check that an X-XSS-Protection header added by a 304 response does not override one from the original request.
    44
  • trunk/LayoutTests/http/tests/security/xssAuditor/cached-frame.html

    r269236 r272607  
    2929</head>
    3030<body>
    31     <iframe src="http://127.0.0.1:8000/security/xssAuditor/resources/nph-cached.pl?q=%3cscript%3ealert(/XSS/);%3c/script%3e" onload="frameLoaded()"></iframe>
     31    <iframe src="http://127.0.0.1:8000/security/xssAuditor/resources/nph-cached.pl?q=%3cscript%3econsole.log(/XSS/);%3c/script%3e" onload="frameLoaded()"></iframe>
    3232</body>
    3333</html>
  • trunk/LayoutTests/http/tests/security/xssAuditor/cookie-injection-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The Set-Cookie meta tag is obsolete and was ignored. Use the HTTP header Set-Cookie or document.cookie instead.
    2 ALERT: PASS
     2CONSOLE MESSAGE: PASS
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/data-urls-work-expected.txt

    r77470 r272607  
    1 ALERT: PASS
     1CONSOLE MESSAGE: PASS
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/data-urls-work.html

    r269236 r272607  
    99</head>
    1010<body>
    11 <iframe src="data:text/html,<script>alert('PASS');</script>"></iframe>
     11<iframe src="data:text/html,<script>console.log('PASS');</script>"></iframe>
    1212</body>
    1313</html>
  • trunk/LayoutTests/http/tests/security/xssAuditor/dom-write-innerHTML-expected.txt

    r95161 r272607  
    1 ALERT: XSS
     1CONSOLE MESSAGE: XSS
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/dom-write-innerHTML.html

    r269236 r272607  
    1515</head>
    1616<body>
    17 <iframe src="http://localhost:8000/security/xssAuditor/resources/echo-dom-write-innerHTML.html?q=<img src='about:blank' onerror='alert(String.fromCharCode(0x58,0x53,0x53))'>">
     17<iframe src="http://localhost:8000/security/xssAuditor/resources/echo-dom-write-innerHTML.html?q=<img src='about:blank' onerror='console.log(String.fromCharCode(0x58,0x53,0x53))'>">
    1818</iframe>
    1919</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/form-action-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?test=/security/xssAuditor/form-action.html&q=%3Cform%20action=http://127.0.0.1:8000/%20method=x%3E%3Cinput%20type=submit%3E%3Cinput%20name=x%20value=%27Please%20type%20your%20PIN.%27%3E&notifyDone=1&showAction=1' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    2 ALERT: Form action set to about:blank
     2CONSOLE MESSAGE: Form action set to about:blank
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/formaction-on-button-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?test=/security/xssAuditor/formaction-on-button.html&q=%3Cform%3E%3Cbutton%20formaction=%27http://example.com/%27%3E&notifyDone=1&showFormaction=1' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    2 ALERT: formaction present on BUTTON with value of about:blank
     2CONSOLE MESSAGE: formaction present on BUTTON with value of about:blank
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/formaction-on-input-expected.txt

    r259900 r272607  
    11CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?test=/security/xssAuditor/formaction-on-input.html&q=%3Cform%3E%3Cinput%20formaction=%27http://example.com/%27%3E&notifyDone=1&showFormaction=1' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    2 ALERT: formaction present on INPUT with value of about:blank
     2CONSOLE MESSAGE: formaction present on INPUT with value of about:blank
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/javascript-link-safe-expected.txt

    r60014 r272607  
    1 ALERT: This is a safe script.
     1CONSOLE MESSAGE: This is a safe script.
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/javascript-link-safe.html

    r269236 r272607  
    1010</head>
    1111<body>
    12 <iframe src="http://localhost:8000/security/xssAuditor/resources/javascript-link-safe.html?q=alert('This is a safe script.')">
     12<iframe src="http://localhost:8000/security/xssAuditor/resources/javascript-link-safe.html?q=console.log('This is a safe script.')">
    1313</iframe>
    1414</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/property-escape-noquotes-expected.txt

    r95161 r272607  
    1 ALERT: XSS
     1CONSOLE MESSAGE: XSS
    22This test fails because the XSSAuditor allows requests that do not contain illegal URI characters. Thus, the XSSAuditor does not detect breaking out of an unquoted property. A future update may reinstate this functionality.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/property-escape-noquotes-tab-slash-chars-expected.txt

    r95161 r272607  
    1 ALERT: XSS
     1CONSOLE MESSAGE: XSS
    22This test fails because the XSSAuditor allows requests that do not contain illegal URI characters. Thus, the XSSAuditor does not detect breaking out of an unquoted property. A future update may reinstate this functionality.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/property-escape-noquotes-tab-slash-chars.html

    r269236 r272607  
    1212the XSSAuditor does not detect breaking out of an unquoted property. A future update may reinstate this
    1313functionality.</p>
    14 <iframe src="http://localhost:8000/security/xssAuditor/resources/echo-property-noquotes.pl?q=dummy%09/onload=alert(String.fromCharCode(0x58,0x53,0x53))&dummy=dummy">
     14<iframe src="http://localhost:8000/security/xssAuditor/resources/echo-property-noquotes.pl?q=dummy%09/onload=console.log(String.fromCharCode(0x58,0x53,0x53))&dummy=dummy">
    1515</iframe>
    1616</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/property-escape-noquotes.html

    r269236 r272607  
    1212the XSSAuditor does not detect breaking out of an unquoted property. A future update may reinstate this
    1313functionality.</p>
    14 <iframe src="http://localhost:8000/security/xssAuditor/resources/echo-property-noquotes.pl?q=1%20onload=alert(String.fromCharCode(0x58,0x53,0x53))">
     14<iframe src="http://localhost:8000/security/xssAuditor/resources/echo-property-noquotes.pl?q=1%20onload=console.log(String.fromCharCode(0x58,0x53,0x53))">
    1515</iframe>
    1616</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/property-inject-expected.txt

    r95161 r272607  
    1 ALERT: XSS
     1CONSOLE MESSAGE: XSS
    22This test fails because the XSSAuditor allows requests that do not contain illegal URI characters. Thus, the XSSAuditor does not detect the injection of an inline event handler within a tag. A future update may reinstate this functionality.
    33
  • trunk/LayoutTests/http/tests/security/xssAuditor/property-inject.html

    r269236 r272607  
    1212the XSSAuditor does not detect the injection of an inline event handler within a tag. A future update may
    1313reinstate this functionality.</p>
    14 <iframe src="http://localhost:8000/security/xssAuditor/resources/echo-inner-tag.pl?q=onload=alert(String.fromCharCode(0x58,0x53,0x53))">
     14<iframe src="http://localhost:8000/security/xssAuditor/resources/echo-inner-tag.pl?q=onload=console.log(String.fromCharCode(0x58,0x53,0x53))">
    1515</iframe>
    1616</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/base-href/really-safe-script.js

    r45642 r272607  
    1 alert('This is a safe script.');
     1console.log('This is a safe script.');
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/base-href/safe-script.js

    r45642 r272607  
    1 alert(/XSS/);
     1console.log(/XSS/);
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/echo-intertag.pl

    r261946 r272607  
    106106if ($cgi->param('showAction')) {
    107107    print "<script>\n";
    108     print "    alert('Form action set to ' + document.forms[0].action);\n";
     108    print "    console.log('Form action set to ' + document.forms[0].action);\n";
    109109    print "</script>\n";
    110110}
     
    113113    print "    var e = document.querySelector('[formaction]');\n";
    114114    print "    if (e)\n";
    115     print "        alert('formaction present on ' + e.nodeName + ' with value of ' + e.getAttribute('formaction'));\n";
     115    print "        console.log('formaction present on ' + e.nodeName + ' with value of ' + e.getAttribute('formaction'));\n";
    116116    print "</script>\n";
    117117}
     
    127127    print "        document.getElementById('console').innerText = log;\n";
    128128    print "    } else\n";
    129     print "        alert('No element matched the given selector.');\n";
     129    print "        console.log('No element matched the given selector.');\n";
    130130    print "</script>\n";
    131131}
     
    140140}
    141141if ($cgi->param('alert-cookie')) {
    142     print "<script>if (/xssAuditorTestCookie/.test(document.cookie)) { alert('FAIL: ' + document.cookie); document.cookie = 'xssAuditorTestCookie=remove; max-age=-1'; } else alert('PASS');</script>\n";
     142    print "<script>if (/xssAuditorTestCookie/.test(document.cookie)) { console.log('FAIL: ' + document.cookie); document.cookie = 'xssAuditorTestCookie=remove; max-age=-1'; } else console.log('PASS');</script>\n";
    143143}
    144144if ($cgi->param('echo-report')) {
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/javascript-link-safe.html

    r120174 r272607  
    44</head>
    55<body>
    6 <a id="anchorLink" href="javascript:alert('This is a safe script.')">test</a>
     6<a id="anchorLink" href="javascript:console.log('This is a safe script.')">test</a>
    77<script>
    88    var event = document.createEvent('MouseEvent');
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/nph-cached.pl

    r142068 r272607  
    2727print "<body>\r\n";
    2828print "<input id=\"rand\" type=\"text\" value=\"$nonce\"/>\r\n";
    29 print "<script>alert(/XSS/);</script>\r\n";
     29print "<script>console.log(/XSS/);</script>\r\n";
    3030print "</body>\r\n";
    3131print "</html>\r\n";
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/safe-script-noquotes.js

    r48961 r272607  
    1 alert(/This is a safe script./);
     1console.log(/This is a safe script./);
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/safe-script.js

    r45642 r272607  
    1 alert('This is a safe script.');
     1console.log('This is a safe script.');
  • trunk/LayoutTests/http/tests/security/xssAuditor/resources/script-tag-safe2.html

    r48961 r272607  
    22<html>
    33<head>
    4 <script>alert(/This is a safe script./)</script>
     4<script>console.log(/This is a safe script./)</script>
    55</head>
    66<body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-near-start-expected.txt

    r259900 r272607  
    1 CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?test=/security/xssAuditor/script-tag-near-start.html&script-expression-follows=1&q=%3Cscript%3E%22%3Cscript%3E%22-alert(/XSS/)' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
     1CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?test=/security/xssAuditor/script-tag-near-start.html&script-expression-follows=1&q=%3Cscript%3E%22%3Cscript%3E%22-console.log(/XSS/)' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-near-start.html

    r269236 r272607  
    99</head>
    1010<body>
    11 <iframe src="http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?test=/security/xssAuditor/script-tag-near-start.html&script-expression-follows=1&q=<script>%22<script>%22-alert(/XSS/)">
     11<iframe src="http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?test=/security/xssAuditor/script-tag-near-start.html&script-expression-follows=1&q=<script>%22<script>%22-console.log(/XSS/)">
    1212</iframe>
    1313</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-safe2-expected.txt

    r48961 r272607  
    1 ALERT: /This is a safe script./
     1CONSOLE MESSAGE: /This is a safe script./
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-safe2.html

    r269236 r272607  
    99</head>
    1010<body>
    11 <iframe src='http://localhost:8000/security/xssAuditor/resources/script-tag-safe2.html?q=alert(/This+is+a+safe+script./)'>
     11<iframe src='http://localhost:8000/security/xssAuditor/resources/script-tag-safe2.html?q=console.log(/This+is+a+safe+script./)'>
    1212</iframe>
    1313</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-safe3-expected.txt

    r48961 r272607  
    1 ALERT: /This is a safe script./
     1CONSOLE MESSAGE: /This is a safe script./
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-safe3.html

    r269236 r272607  
    99</head>
    1010<body>
    11 <iframe src='http://localhost:8000/security/xssAuditor/resources/script-tag-safe3.html?q=alert(/This+is+a+safe+script./)%3B'>
     11<iframe src='http://localhost:8000/security/xssAuditor/resources/script-tag-safe3.html?q=console.log(/This+is+a+safe+script./)%3B'>
    1212</iframe>
    1313</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-src-redirect-safe-expected.txt

    r45787 r272607  
    1 ALERT: This is a safe script.
     1CONSOLE MESSAGE: This is a safe script.
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-with-injected-comment-expected.txt

    r259900 r272607  
    1 CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?clutter=/*]]%3E*/&q=%3Cscript%3E/*%3C!CDATA[*/alert(/XSS/)&q2=%3C/script%3E' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
     1CONSOLE MESSAGE: The XSS Auditor refused to execute a script in 'http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?clutter=/*]]%3E*/&q=%3Cscript%3E/*%3C!CDATA[*/console.log(/XSS/)&q2=%3C/script%3E' because its source code was found within the request. The auditor was enabled because the server did not send an 'X-XSS-Protection' header.
    22
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-with-injected-comment.html

    r269236 r272607  
    99</head>
    1010<body>
    11 <iframe src="http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?clutter=/*]]>*/&q=<script>/*<!CDATA[*/alert(/XSS/)&q2=</script>">
     11<iframe src="http://localhost:8000/security/xssAuditor/resources/echo-intertag.pl?clutter=/*]]>*/&q=<script>/*<!CDATA[*/console.log(/XSS/)&q2=</script>">
    1212</iframe>
    1313</body>
  • trunk/LayoutTests/http/tests/security/xssAuditor/script-tag-with-source-same-host-expected.txt

    r49605 r272607  
    1 ALERT: This is a safe script.
     1CONSOLE MESSAGE: This is a safe script.
    22
  • trunk/LayoutTests/http/tests/xmlhttprequest/access-control-preflight-credential-async-expected.txt

    r113589 r272607  
    1 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
    2 ALERT: XHR response - Set the foo cookie
     1CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
     2CONSOLE MESSAGE: XHR response - Set the foo cookie
    33Test case for bug 37781: [XHR] Cross-Origin asynchronous request with credential raises NETWORK_ERR
    44
  • trunk/LayoutTests/http/tests/xmlhttprequest/access-control-preflight-credential-sync-expected.txt

    r113589 r272607  
    1 ALERT: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
    2 ALERT: XHR response - Set the foo cookie
     1CONSOLE MESSAGE: http://localhost:8000/cookies/resources/cookie-utility.php?queryfunction=setFooCookie
     2CONSOLE MESSAGE: XHR response - Set the foo cookie
    33Test case for bug 37781: [XHR] Cross-Origin synchronous request with credential raises NETWORK_ERR
    44
  • trunk/LayoutTests/platform/wk2/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/proper-nested-upgrades-expected.txt

    r231450 r272607  
    22frame "<!--frame1-->" - didStartProvisionalLoadForFrame
    33frame "<!--frame1-->" - didCommitLoadForFrame
    4 ALERT: PASS
     4CONSOLE MESSAGE: PASS
    55frame "<!--frame1-->" - didFinishDocumentLoadForFrame
    66frame "<!--frame2-->" - didStartProvisionalLoadForFrame
    77frame "<!--frame2-->" - didCommitLoadForFrame
    8 ALERT: PASS
    9 ALERT: PASS
     8CONSOLE MESSAGE: PASS
     9CONSOLE MESSAGE: PASS
    1010frame "<!--frame2-->" - didFinishDocumentLoadForFrame
    1111frame "<!--frame2-->" - didHandleOnloadEventsForFrame
  • trunk/LayoutTests/plugins/fullscreen-plugins-dont-reload-expected.txt

    r95371 r272607  
    1 ALERT: Plugin Loaded!
     1CONSOLE MESSAGE: Plugin Loaded!
    22go fullscreen
    33There should only be one ALERT. If there were two, the plugin was reloaded during the transition to fullscreen.
  • trunk/LayoutTests/plugins/plugin-document-back-forward-expected.txt

    r77706 r272607  
    1 ALERT: Plugin Loaded!
    2 ALERT: Plugin Loaded!
     1CONSOLE MESSAGE: Plugin Loaded!
     2CONSOLE MESSAGE: Plugin Loaded!
    33
  • trunk/Source/WebCore/ChangeLog

    r272603 r272607  
     12021-02-09  Chris Dumez  <cdumez@apple.com>
     2
     3        Disallow alert/confirm/prompt in cross-origin-domain subframes
     4        https://bugs.webkit.org/show_bug.cgi?id=221568
     5
     6        Reviewed by Geoff Garen.
     7
     8        Disallow alert/confirm/prompt in cross-origin-domain subframes as per the latest HTML specification:
     9        - https://github.com/whatwg/html/pull/6297
     10
     11        Tests: http/tests/security/cross-origin-js-prompt-forbidden.html
     12               http/tests/security/same-origin-different-domain-js-prompt-forbidden.html
     13
     14        * page/DOMWindow.cpp:
     15        (WebCore::DOMWindow::alert):
     16        (WebCore::DOMWindow::confirmForBindings):
     17        (WebCore::DOMWindow::prompt):
     18        * page/SecurityOrigin.cpp:
     19        * page/SecurityOrigin.h:
     20
    1212021-02-09  Alex Christensen  <achristensen@webkit.org>
    222
  • trunk/Source/WebCore/page/DOMWindow.cpp

    r272122 r272607  
    11131113    }
    11141114
     1115    if (!document()->securityOrigin().canAccess(document()->topDocument().securityOrigin())) {
     1116        printErrorMessage("Use of window.alert is not allowed in different origin-domain iframes.");
     1117        return;
     1118    }
     1119
    11151120    frame->document()->updateStyleIfNeeded();
    11161121#if ENABLE(POINTER_LOCK)
     
    11411146    }
    11421147
     1148    if (!document()->securityOrigin().canAccess(document()->topDocument().securityOrigin())) {
     1149        printErrorMessage("Use of window.confirm is not allowed in different origin-domain iframes.");
     1150        return false;
     1151    }
     1152
    11431153    frame->document()->updateStyleIfNeeded();
    11441154#if ENABLE(POINTER_LOCK)
     
    11661176    if (!page->arePromptsAllowed()) {
    11671177        printErrorMessage("Use of window.prompt is not allowed while unloading a page.");
     1178        return String();
     1179    }
     1180
     1181    if (!document()->securityOrigin().canAccess(document()->topDocument().securityOrigin())) {
     1182        printErrorMessage("Use of window.prompt is not allowed in different origin-domain iframes.");
    11681183        return String();
    11691184    }
  • trunk/Source/WebCore/page/SecurityOrigin.h

    r269888 r272607  
    9696    // script from one security origin to read or write objects from
    9797    // another SecurityOrigin.
     98    // This method implements the "same origin-domain" algorithm from the HTML Standard:
     99    // https://html.spec.whatwg.org/#same-origin-domain
    98100    WEBCORE_EXPORT bool canAccess(const SecurityOrigin&) const;
    99101
  • trunk/Tools/DumpRenderTree/TestNetscapePlugIn/main.cpp

    r261014 r272607  
    181181        else if (strcasecmp(argn[i], "src") == 0 &&
    182182                 strcasecmp(argv[i], "data:application/x-webkit-test-netscape,alertwhenloaded") == 0)
    183             executeScript(obj, "alert('Plugin Loaded!')");
     183            executeScript(obj, "console.log('Plugin Loaded!')");
    184184        else if (strcasecmp(argn[i], "src") == 0 &&
    185185                 strcasecmp(argv[i], "data:application/x-webkit-test-netscape,logifloaded") == 0) {
Note: See TracChangeset for help on using the changeset viewer.