[html5] r5682 - [agiow] (2) Revert r5277's removal of '/' as a magic value to postMessage(), sin [...]

whatwg at whatwg.org whatwg at whatwg.org
Mon Nov 15 15:25:56 PST 2010


Author: ianh
Date: 2010-11-15 15:25:55 -0800 (Mon, 15 Nov 2010)
New Revision: 5682

Modified:
   complete.html
   index
   source
Log:
[agiow] (2) Revert r5277's removal of '/' as a magic value to postMessage(), since it has useful use cases. Paths in absolute URLs are still ignored without raising an exception.

Modified: complete.html
===================================================================
--- complete.html	2010-11-15 21:47:19 UTC (rev 5681)
+++ complete.html	2010-11-15 23:25:55 UTC (rev 5682)
@@ -72962,7 +72962,7 @@
     send the message to the target regardless of origin, set the
     target origin to "<code title="">*</code>". To restrict the
     message to same-origin targets only, without needing to explicitly
-    state the origin, pass the <code title=dom-location><a href=#dom-location>window.location</a></code> object.</p>
+    state the origin, set the target origin to "<code title="">/</code>".</p>
 
     <p>Throws an <code><a href=#invalid_state_err>INVALID_STATE_ERR</a></code> if the <var title="">ports</var> array is not null and it contains either null
     entries or duplicate ports.</p>
@@ -72990,9 +72990,10 @@
   <ol><li>
 
     <p>If the value of the <var title="">targetOrigin</var> argument
-    is neither a single U+002A ASTERISK character (*) nor an
-    <a href=#absolute-url>absolute URL</a>, then throw a <code><a href=#syntax_err>SYNTAX_ERR</a></code>
-    exception and abort the overall set of steps.</p>
+    is neither a single U+002A ASTERISK character (*), a single U+002F
+    SOLIDUS character (/), nor an <a href=#absolute-url>absolute URL</a>, then
+    throw a <code><a href=#syntax_err>SYNTAX_ERR</a></code> exception and abort the overall
+    set of steps.</p>
 
    </li>
 
@@ -73041,6 +73042,13 @@
 
    <li>
 
+    <p>If the <var title="">targetOrigin</var> argument is a single
+    literal U+002F SOLIDUS character (/), and the
+    <code><a href=#document>Document</a></code> of the <code><a href=#window>Window</a></code> object on which
+    the method was invoked does not have the <a href=#same-origin>same origin</a>
+    as the <a href=#entry-script>entry script</a>'s <a href="#script's-document" title="script's
+    document">document</a>, then abort these steps silently.</p>
+
     <p>Otherwise, if the <var title="">targetOrigin</var> argument is
     an <a href=#absolute-url>absolute URL</a>, and the <code><a href=#document>Document</a></code> of the
     <code><a href=#window>Window</a></code> object on which the method was invoked does

Modified: index
===================================================================
--- index	2010-11-15 21:47:19 UTC (rev 5681)
+++ index	2010-11-15 23:25:55 UTC (rev 5682)
@@ -69611,7 +69611,7 @@
     send the message to the target regardless of origin, set the
     target origin to "<code title="">*</code>". To restrict the
     message to same-origin targets only, without needing to explicitly
-    state the origin, pass the <code title=dom-location><a href=#dom-location>window.location</a></code> object.</p>
+    state the origin, set the target origin to "<code title="">/</code>".</p>
 
     <p>Throws an <code><a href=#invalid_state_err>INVALID_STATE_ERR</a></code> if the <var title="">ports</var> array is not null and it contains either null
     entries or duplicate ports.</p>
@@ -69639,9 +69639,10 @@
   <ol><li>
 
     <p>If the value of the <var title="">targetOrigin</var> argument
-    is neither a single U+002A ASTERISK character (*) nor an
-    <a href=#absolute-url>absolute URL</a>, then throw a <code><a href=#syntax_err>SYNTAX_ERR</a></code>
-    exception and abort the overall set of steps.</p>
+    is neither a single U+002A ASTERISK character (*), a single U+002F
+    SOLIDUS character (/), nor an <a href=#absolute-url>absolute URL</a>, then
+    throw a <code><a href=#syntax_err>SYNTAX_ERR</a></code> exception and abort the overall
+    set of steps.</p>
 
    </li>
 
@@ -69690,6 +69691,13 @@
 
    <li>
 
+    <p>If the <var title="">targetOrigin</var> argument is a single
+    literal U+002F SOLIDUS character (/), and the
+    <code><a href=#document>Document</a></code> of the <code><a href=#window>Window</a></code> object on which
+    the method was invoked does not have the <a href=#same-origin>same origin</a>
+    as the <a href=#entry-script>entry script</a>'s <a href="#script's-document" title="script's
+    document">document</a>, then abort these steps silently.</p>
+
     <p>Otherwise, if the <var title="">targetOrigin</var> argument is
     an <a href=#absolute-url>absolute URL</a>, and the <code><a href=#document>Document</a></code> of the
     <code><a href=#window>Window</a></code> object on which the method was invoked does

Modified: source
===================================================================
--- source	2010-11-15 21:47:19 UTC (rev 5681)
+++ source	2010-11-15 23:25:55 UTC (rev 5682)
@@ -82572,8 +82572,8 @@
     send the message to the target regardless of origin, set the
     target origin to "<code title="">*</code>". To restrict the
     message to same-origin targets only, without needing to explicitly
-    state the origin, pass the <code
-    title="dom-location">window.location</code> object.</p>
+    state the origin, set the target origin to "<code
+    title="">/</code>".</p>
 
     <p>Throws an <code>INVALID_STATE_ERR</code> if the <var
     title="">ports</var> array is not null and it contains either null
@@ -82609,9 +82609,10 @@
    <li>
 
     <p>If the value of the <var title="">targetOrigin</var> argument
-    is neither a single U+002A ASTERISK character (*) nor an
-    <span>absolute URL</span>, then throw a <code>SYNTAX_ERR</code>
-    exception and abort the overall set of steps.</p>
+    is neither a single U+002A ASTERISK character (*), a single U+002F
+    SOLIDUS character (/), nor an <span>absolute URL</span>, then
+    throw a <code>SYNTAX_ERR</code> exception and abort the overall
+    set of steps.</p>
 
    </li>
 
@@ -82664,6 +82665,13 @@
 
    <li>
 
+    <p>If the <var title="">targetOrigin</var> argument is a single
+    literal U+002F SOLIDUS character (/), and the
+    <code>Document</code> of the <code>Window</code> object on which
+    the method was invoked does not have the <span>same origin</span>
+    as the <span>entry script</span>'s <span title="script's
+    document">document</span>, then abort these steps silently.</p>
+
     <p>Otherwise, if the <var title="">targetOrigin</var> argument is
     an <span>absolute URL</span>, and the <code>Document</code> of the
     <code>Window</code> object on which the method was invoked does




More information about the Commit-Watchers mailing list