Skip to content

Commit

Permalink
[e] (0) make 'cookie-free' an internal term so that XHR doesn't have …
Browse files Browse the repository at this point in the history
…to refer to it; also, let XHR define its own origins.

git-svn-id: http://svn.whatwg.org/webapps@5710 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Dec 7, 2010
1 parent b903be5 commit 62da2b2
Show file tree
Hide file tree
Showing 3 changed files with 98 additions and 63 deletions.
52 changes: 31 additions & 21 deletions complete.html
Expand Up @@ -8333,19 +8333,20 @@ <h4 id=resource-metadata-management><span class=secno>3.1.3 </span><dfn>Resource
attribute represents the cookies of the resource from which the
<code><a href=#document>Document</a></code> was created.</p>

<p>Some <code><a href=#document>Document</a></code> objects are <dfn id=cookie-free-document-object title="cookie-free
Document object">cookie-free <code>Document</code>
objects</dfn>. Any <code><a href=#document>Document</a></code> object created by the <code title="">createDocument()</code> or <code title=dom-DOMHTMLImplementation-createHTMLDocument><a href=#dom-domhtmlimplementation-createhtmldocument>createHTMLDocument()</a></code>
factory methods is a <a href=#cookie-free-document-object>cookie-free <code>Document</code>
object</a>. Any <code><a href=#document>Document</a></code> whose <a href="#the-document's-address" title="the
document's address">address</a> does not use a server-based
naming authority is a <a href=#cookie-free-document-object>cookie-free <code>Document</code>
object</a>. Other specifications can also define
<code><a href=#document>Document</a></code> objects as being <a href=#cookie-free-document-object title="cookie-free
Document object">cookie-free <code>Document</code>
objects</a>.</p>

<p id=sandboxCookies>On getting, if the document is a
<p>A <code><a href=#document>Document</a></code> object that falls into one of the
following conditions is a <dfn id=cookie-free-document-object>cookie-free <code>Document</code>
object</dfn>:</p>

<ul><li>A <code><a href=#document>Document</a></code> that has no <a href=#browsing-context>browsing
context</a>.</li>

<li>A <code><a href=#document>Document</a></code> whose <a href="#the-document's-address" title="the document's
address">address</a> does not use a server-based naming
authority.</li>

</ul><!--Other specifications can also define <code>Document</code>
objects as being <span title="cookie-free Document
object">cookie-free <code>Document</code> objects</span>.--><p id=sandboxCookies>On getting, if the document is a
<a href=#cookie-free-document-object>cookie-free <code>Document</code> object</a>, then the user
agent must return the empty string. Otherwise, if the
<code><a href=#document>Document</a></code>'s <a href=#origin>origin</a> is not a
Expand Down Expand Up @@ -58151,6 +58152,7 @@ <h3 id=origin-0><span class=secno>6.3 </span>Origin</h3>

</dd>


<dt>For scripts</dt>

<dd>
Expand Down Expand Up @@ -58228,6 +58230,7 @@ <h3 id=origin-0><span class=secno>6.3 </span>Origin</h3>

</dd>


<dt>For <code><a href=#document>Document</a></code> objects and images</dt>

<dd>
Expand All @@ -58244,13 +58247,6 @@ <h3 id=origin-0><span class=secno>6.3 </span>Origin</h3>
assigned when the <code><a href=#document>Document</a></code> is created.</dd>


<dt>If a <code><a href=#document>Document</a></code> or image was returned by the
<code>XMLHttpRequest</code> API</dt>

<dd>The <a href=#origin>origin</a> is equal to the <span>XMLHttpRequest
origin</span> of the <code>XMLHttpRequest</code> object. <a href=#refsXHR>[XHR]</a></dd>


<dt>If a <code><a href=#document>Document</a></code> or image was generated from a
<a href=#javascript-protocol title="javascript protocol"><code>javascript:</code>
URL</a></dt>
Expand Down Expand Up @@ -58321,6 +58317,7 @@ <h3 id=origin-0><span class=secno>6.3 </span>Origin</h3>

</dd>


<dt>For <code><a href=#audio>audio</a></code> and <code><a href=#video>video</a></code> elements</dt>

<dd>
Expand All @@ -58336,7 +58333,20 @@ <h3 id=origin-0><span class=secno>6.3 </span>Origin</h3>

</dd>

</dl><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string
</dl><p>Other specifications can override the above definitions by
themselves specifying the origin of a particular URL, script,
<code><a href=#document>Document</a></code>, or image.</p>

<!-- e.g.:

<p>The <span>origin</span> of a <code>Document</code> object
returned by the <code>XMLHttpRequest</code> API is equal to the
<span>XMLHttpRequest origin</span> of the
<code>XMLHttpRequest</code> object.</p>

-->

<hr><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string
obtained by applying the following algorithm to the given
<a href=#origin>origin</a>:</p>

Expand Down
52 changes: 31 additions & 21 deletions index
Expand Up @@ -8311,19 +8311,20 @@ interface <dfn id=htmldocument>HTMLDocument</dfn> {
attribute represents the cookies of the resource from which the
<code><a href=#document>Document</a></code> was created.</p>

<p>Some <code><a href=#document>Document</a></code> objects are <dfn id=cookie-free-document-object title="cookie-free
Document object">cookie-free <code>Document</code>
objects</dfn>. Any <code><a href=#document>Document</a></code> object created by the <code title="">createDocument()</code> or <code title=dom-DOMHTMLImplementation-createHTMLDocument><a href=#dom-domhtmlimplementation-createhtmldocument>createHTMLDocument()</a></code>
factory methods is a <a href=#cookie-free-document-object>cookie-free <code>Document</code>
object</a>. Any <code><a href=#document>Document</a></code> whose <a href="#the-document's-address" title="the
document's address">address</a> does not use a server-based
naming authority is a <a href=#cookie-free-document-object>cookie-free <code>Document</code>
object</a>. Other specifications can also define
<code><a href=#document>Document</a></code> objects as being <a href=#cookie-free-document-object title="cookie-free
Document object">cookie-free <code>Document</code>
objects</a>.</p>

<p id=sandboxCookies>On getting, if the document is a
<p>A <code><a href=#document>Document</a></code> object that falls into one of the
following conditions is a <dfn id=cookie-free-document-object>cookie-free <code>Document</code>
object</dfn>:</p>

<ul><li>A <code><a href=#document>Document</a></code> that has no <a href=#browsing-context>browsing
context</a>.</li>

<li>A <code><a href=#document>Document</a></code> whose <a href="#the-document's-address" title="the document's
address">address</a> does not use a server-based naming
authority.</li>

</ul><!--Other specifications can also define <code>Document</code>
objects as being <span title="cookie-free Document
object">cookie-free <code>Document</code> objects</span>.--><p id=sandboxCookies>On getting, if the document is a
<a href=#cookie-free-document-object>cookie-free <code>Document</code> object</a>, then the user
agent must return the empty string. Otherwise, if the
<code><a href=#document>Document</a></code>'s <a href=#origin>origin</a> is not a
Expand Down Expand Up @@ -58132,6 +58133,7 @@ x === this; // true</pre>

</dd>


<dt>For scripts</dt>

<dd>
Expand Down Expand Up @@ -58209,6 +58211,7 @@ x === this; // true</pre>

</dd>


<dt>For <code><a href=#document>Document</a></code> objects and images</dt>

<dd>
Expand All @@ -58225,13 +58228,6 @@ x === this; // true</pre>
assigned when the <code><a href=#document>Document</a></code> is created.</dd>


<dt>If a <code><a href=#document>Document</a></code> or image was returned by the
<code>XMLHttpRequest</code> API</dt>

<dd>The <a href=#origin>origin</a> is equal to the <span>XMLHttpRequest
origin</span> of the <code>XMLHttpRequest</code> object. <a href=#refsXHR>[XHR]</a></dd>


<dt>If a <code><a href=#document>Document</a></code> or image was generated from a
<a href=#javascript-protocol title="javascript protocol"><code>javascript:</code>
URL</a></dt>
Expand Down Expand Up @@ -58302,6 +58298,7 @@ x === this; // true</pre>

</dd>


<dt>For <code><a href=#audio>audio</a></code> and <code><a href=#video>video</a></code> elements</dt>

<dd>
Expand All @@ -58317,7 +58314,20 @@ x === this; // true</pre>

</dd>

</dl><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string
</dl><p>Other specifications can override the above definitions by
themselves specifying the origin of a particular URL, script,
<code><a href=#document>Document</a></code>, or image.</p>

<!-- e.g.:

<p>The <span>origin</span> of a <code>Document</code> object
returned by the <code>XMLHttpRequest</code> API is equal to the
<span>XMLHttpRequest origin</span> of the
<code>XMLHttpRequest</code> object.</p>

-->

<hr><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string
obtained by applying the following algorithm to the given
<a href=#origin>origin</a>:</p>

Expand Down
57 changes: 36 additions & 21 deletions source
Expand Up @@ -8255,19 +8255,24 @@ interface <dfn>HTMLDocument</dfn> {
attribute represents the cookies of the resource from which the
<code>Document</code> was created.</p>

<p>Some <code>Document</code> objects are <dfn title="cookie-free
Document object">cookie-free <code>Document</code>
objects</dfn>. Any <code>Document</code> object created by the <code
title="">createDocument()</code> or <code
title="dom-DOMHTMLImplementation-createHTMLDocument">createHTMLDocument()</code>
factory methods is a <span>cookie-free <code>Document</code>
object</span>. Any <code>Document</code> whose <span title="the
document's address">address</span> does not use a server-based
naming authority is a <span>cookie-free <code>Document</code>
object</span>. Other specifications can also define
<code>Document</code> objects as being <span title="cookie-free
Document object">cookie-free <code>Document</code>
objects</span>.</p>
<p>A <code>Document</code> object that falls into one of the
following conditions is a <dfn>cookie-free <code>Document</code>
object</dfn>:</p>

<ul>

<li>A <code>Document</code> that has no <span>browsing
context</span>.</li>

<li>A <code>Document</code> whose <span title="the document's
address">address</span> does not use a server-based naming
authority.</li>

</ul>

<!--Other specifications can also define <code>Document</code>
objects as being <span title="cookie-free Document
object">cookie-free <code>Document</code> objects</span>.-->

<p id="sandboxCookies">On getting, if the document is a
<span>cookie-free <code>Document</code> object</span>, then the user
Expand Down Expand Up @@ -66071,6 +66076,7 @@ x === this; // true</pre>

</dd>


<dt>For scripts</dt>

<dd>
Expand Down Expand Up @@ -66160,6 +66166,7 @@ x === this; // true</pre>

</dd>


<dt>For <code>Document</code> objects and images</dt>

<dd>
Expand All @@ -66178,14 +66185,6 @@ x === this; // true</pre>
assigned when the <code>Document</code> is created.</dd>


<dt>If a <code>Document</code> or image was returned by the
<code>XMLHttpRequest</code> API</dt>

<dd>The <span>origin</span> is equal to the <span>XMLHttpRequest
origin</span> of the <code>XMLHttpRequest</code> object. <a
href="#refsXHR">[XHR]</a></dd>


<dt>If a <code>Document</code> or image was generated from a
<span title="javascript protocol"><code>javascript:</code>
URL</span></dt>
Expand Down Expand Up @@ -66264,6 +66263,7 @@ x === this; // true</pre>

</dd>


<dt>For <code>audio</code> and <code>video</code> elements</dt>

<dd>
Expand All @@ -66283,6 +66283,21 @@ x === this; // true</pre>

</dl>

<p>Other specifications can override the above definitions by
themselves specifying the origin of a particular URL, script,
<code>Document</code>, or image.</p>

<!-- e.g.:

<p>The <span>origin</span> of a <code>Document</code> object
returned by the <code>XMLHttpRequest</code> API is equal to the
<span>XMLHttpRequest origin</span> of the
<code>XMLHttpRequest</code> object.</p>

-->

<hr>

<p>The <dfn>Unicode serialization of an origin</dfn> is the string
obtained by applying the following algorithm to the given
<span>origin</span>:</p>
Expand Down

0 comments on commit 62da2b2

Please sign in to comment.