Skip to content

Commit

Permalink
Do not allow http-equiv values curated via wiki
Browse files Browse the repository at this point in the history
Unlike the somewhat-successful wiki registry for names, the wiki
registry for http-equiv values only contained a single entry,
"PICS-Label", which points to a spec that has since been obsoleted, and
to our knowledge never had an effect on at least browser user agents.

This removes the section allowing such wiki-curated pragma directives.
Moving forward, any header-like http-equiv pragmas that affect the
processing model for HTML documents must go through the normal process
for changing the HTML Standard.

Closes https://www.w3.org/Bugs/Public/show_bug.cgi?id=18025.

As an editorial matter, this also defines keywords for each http-equiv
attribute state, and links them appropriately.
  • Loading branch information
domenic committed Dec 13, 2017
1 parent 923af73 commit 72d084b
Showing 1 changed file with 21 additions and 83 deletions.
104 changes: 21 additions & 83 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -14152,7 +14152,6 @@ interface <dfn>HTMLMetaElement</dfn> : <span>HTMLElement</span> {
<span w-nodev>Some of the keywords are non-conforming, as noted in the last
column.</span></p>

<!-- things that are neither conforming nor do anything are commented out -->
<table id="table-http-equiv">
<thead>
<tr>
Expand All @@ -14162,45 +14161,37 @@ interface <dfn>HTMLMetaElement</dfn> : <span>HTMLElement</span> {
<tbody>
<tr w-nodev>
<td><span data-x="attr-meta-http-equiv-content-language">Content Language</span>
<td><code data-x="">content-language</code>
<td><dfn><code data-x="attr-meta-http-equiv-keyword-content-language">content-language</code></dfn>
<td>Non-conforming
<tr>
<td><span data-x="attr-meta-http-equiv-content-type">Encoding declaration</span>
<td><code data-x="">content-type</code>
<td><dfn><code data-x="attr-meta-http-equiv-keyword-content-type">content-type</code></dfn>
<td>
<!--
<tr w-nodev>
<td><span data-x="attr-meta-http-equiv-content-script-type">Content-Script-Type</span>
<td><code data-x="">Content-Script-Type</code>
<td>Non-conforming
<tr w-nodev>
<td><span data-x="attr-meta-http-equiv-content-style-type">Content-Style-Type</span>
<td><code data-x="">Content-Style-Type</code>
<td>Non-conforming
-->
<tr>
<td><span data-x="attr-meta-http-equiv-default-style">Default style</span>
<td><code data-x="">default-style</code>
<td><dfn><code data-x="attr-meta-http-equiv-keyword-default-style">default-style</code></dfn>
<td>
<tr>
<td><span data-x="attr-meta-http-equiv-refresh">Refresh</span>
<td><code data-x="">refresh</code>
<td><dfn><code data-x="attr-meta-http-equiv-keyword-refresh">refresh</code></dfn>
<td>
<tr w-nodev>
<td><span data-x="attr-meta-http-equiv-set-cookie">Cookie setter</span>
<td><code data-x="">set-cookie</code>
<td><dfn><code data-x="attr-meta-http-equiv-keyword-set-cookie">set-cookie</code></dfn>
<td>Non-conforming
<tr>
<td><span data-x="attr-meta-http-equiv-x-ua-compatible">X-UA-Compatible</span>
<td><code data-x="">x-ua-compatible</code>
<td><dfn><code data-x="attr-meta-http-equiv-keyword-x-ua-compatible">x-ua-compatible</code></dfn>
<td>
<tr>
<td><span data-x="attr-meta-http-equiv-content-security-policy">Content security policy</span>
<td><code data-x="">Content-Security-Policy</code>
<td><dfn><code data-x="attr-meta-http-equiv-keyword-Content-Security-Policy">Content-Security-Policy</code></dfn>
<td>
</table>

<!--
Content-Script-Type and Content-Style-Type don't do anything (and are non-conforming).

DATA: According to Henri's validator stats, here are common
non-conforming values used by people who validate (sample of 400
pages):
Expand Down Expand Up @@ -14252,7 +14243,7 @@ people expect to have work and what is necessary.
<dl>

<dt w-nodev><dfn data-x="attr-meta-http-equiv-content-language">Content language state</dfn>
(<code data-x="">http-equiv="content-language"</code>)
(<code data-x="">http-equiv="<code data-x="attr-meta-http-equiv-keyword-content-language">content-language</code>"</code>)

<dd w-nodev>

Expand Down Expand Up @@ -14306,7 +14297,7 @@ people expect to have work and what is necessary.

</dd>

<dt><dfn data-x="attr-meta-http-equiv-content-type">Encoding declaration state</dfn> (<code data-x="">http-equiv="content-type"</code>)
<dt><dfn data-x="attr-meta-http-equiv-content-type">Encoding declaration state</dfn> (<code data-x="">http-equiv="<code data-x="attr-meta-http-equiv-keyword-content-type">content-type</code>"</code>)

<dd>

Expand Down Expand Up @@ -14335,7 +14326,7 @@ people expect to have work and what is necessary.

</dd>

<dt><dfn data-x="attr-meta-http-equiv-default-style">Default style state</dfn> (<code data-x="">http-equiv="default-style"</code>)
<dt><dfn data-x="attr-meta-http-equiv-default-style">Default style state</dfn> (<code data-x="">http-equiv="<code data-x="attr-meta-http-equiv-keyword-default-style">default-style</code>"</code>)

<dd>

Expand All @@ -14359,7 +14350,7 @@ people expect to have work and what is necessary.

</dd>

<dt><dfn data-x="attr-meta-http-equiv-refresh">Refresh state</dfn> (<code data-x="">http-equiv="refresh"</code>)
<dt><dfn data-x="attr-meta-http-equiv-refresh">Refresh state</dfn> (<code data-x="">http-equiv="<code data-x="attr-meta-http-equiv-keyword-refresh">refresh</code>"</code>)

<dd>

Expand Down Expand Up @@ -14586,7 +14577,7 @@ people expect to have work and what is necessary.

</dd>

<dt w-nodev><dfn data-x="attr-meta-http-equiv-set-cookie">Cookie setter</dfn> (<code data-x="">http-equiv="set-cookie"</code>)
<dt w-nodev><dfn data-x="attr-meta-http-equiv-set-cookie">Cookie setter</dfn> (<code data-x="">http-equiv="<code data-x="attr-meta-http-equiv-keyword-set-cookie">set-cookie</code>"</code>)

<dd w-nodev>

Expand All @@ -14610,7 +14601,7 @@ people expect to have work and what is necessary.
</dd>


<dt><dfn data-x="attr-meta-http-equiv-x-ua-compatible">X-UA-Compatible state</dfn> (<code data-x="">http-equiv="x-ua-compatible"</code>)
<dt><dfn data-x="attr-meta-http-equiv-x-ua-compatible">X-UA-Compatible state</dfn> (<code data-x="">http-equiv="<code data-x="attr-meta-http-equiv-keyword-x-ua-compatible">x-ua-compatible</code>"</code>)

<dd>

Expand All @@ -14627,7 +14618,7 @@ people expect to have work and what is necessary.
</dd>


<dt><dfn data-x="attr-meta-http-equiv-content-security-policy" data-export="" data-dfn-type="dfn">Content security policy state</dfn> (<code data-x="">http-equiv="content-security-policy"</code>)
<dt><dfn data-x="attr-meta-http-equiv-content-security-policy" data-export="" data-dfn-type="dfn">Content security policy state</dfn> (<code data-x="">http-equiv="<code data-x="attr-meta-http-equiv-keyword-Content-Security-Policy">Content-Security-Policy</code>"</code>)

<dd>

Expand Down Expand Up @@ -14687,60 +14678,6 @@ people expect to have work and what is necessary.
document at a time.</p>


<h5>Other pragma directives</h5>

<p><dfn data-x="concept-http-equiv-extensions">Extensions to the predefined set of pragma
directives</dfn> may, under certain conditions, be registered in the <a
href="https://wiki.whatwg.org/wiki/PragmaExtensions">WHATWG Wiki PragmaExtensions page</a>. <ref spec=WHATWGWIKI></p>

<p>Such extensions must use a name that is identical to an HTTP header registered in the Permanent
Message Header Field Registry, and must have behavior identical to that described for the HTTP
header. <ref spec=IANAPERMHEADERS></p>

<p>Pragma directives corresponding to headers describing metadata, or not requiring specific user
agent processing, must not be registered; instead, use <span
data-x="concept-meta-extensions">metadata names</span>. Pragma directives corresponding to headers
that affect the HTTP processing model (e.g. caching) must not be registered, as they would result
in HTTP-level behavior being different for user agents that implement HTML than for user agents
that do not.</p>

<p>Anyone is free to edit the WHATWG Wiki PragmaExtensions page at any time to add a pragma
directive satisfying these conditions. Such registrations must specify the following
information:</p>

<dl>

<dt>Keyword</dt>

<dd><p>The actual name being defined. The name must match a previously-registered HTTP name with
the same requirements.</p></dd>


<dt>Brief description</dt>

<dd><p>A short non-normative description of the purpose of the pragma directive.</p></dd>


<dt>Specification</dt>

<dd>A link to the specification defining the corresponding HTTP header.</dd>

</dl>

<div w-nodev>

<p>Conformance checkers must use the information given on the WHATWG Wiki PragmaExtensions page to
establish if a value is allowed or not: values defined in this specification or listed on the
aforementioned page must be accepted, whereas values not listed in either this specification or on
the aforementioned page must be rejected as invalid. Conformance checkers may cache this
information (e.g. for performance reasons or to avoid the use of unreliable network
connectivity).</p>

</div>




<h5 id="charset">Specifying the document's character encoding</h5>

<!-- READ ME WHEN EDITING: if we ever move this to the "writing HTML" section, then we have to
Expand Down Expand Up @@ -117834,7 +117771,11 @@ interface <dfn>External</dfn> {
<th> <code data-x="">http-equiv</code>
<td> <code data-x="attr-meta-http-equiv">meta</code>
<td> Pragma directive
<td> <a href="#attribute-text">Text</a>*
<td> "<code data-x="attr-meta-http-equiv-keyword-content-type">content-type</code>";
"<code data-x="attr-meta-http-equiv-keyword-default-style">default-style</code>";
"<code data-x="attr-meta-http-equiv-keyword-refresh">refresh</code>";
"<code data-x="attr-meta-http-equiv-keyword-x-ua-compatible">x-ua-compatible</code>";
"<code data-x="attr-meta-http-equiv-keyword-Content-Security-Policy">Content-Security-Policy</code>"
<tr>
<th> <code data-x="">id</code>
<td> <span data-x="attr-id">HTML elements</span>
Expand Down Expand Up @@ -120039,9 +119980,6 @@ INSERT INTERFACES HERE
<dd><cite><a href="https://tools.ietf.org/html/rfc7234">Hypertext Transfer Protocol (HTTP/1.1): Caching</a></cite>, R. Fielding, M. Nottingham, J. Reschke. IETF.</dd>
<dd><cite><a href="https://tools.ietf.org/html/rfc7235">Hypertext Transfer Protocol (HTTP/1.1): Authentication</a></cite>, R. Fielding, J. Reschke. IETF.</dd>

<dt id="refsIANAPERMHEADERS">[IANAPERMHEADERS]</dt>
<dd><cite><a href="https://www.iana.org/assignments/message-headers/message-headers.xhtml#perm-headers">Permanent Message Header Field Names</a></cite>. IANA.</dd>

<dt id="refsINDEXEDDB">[INDEXEDDB]</dt>
<dd><cite><a href="https://w3c.github.io/IndexedDB/">Indexed Database API</a></cite>, A. Alabbas, J. Bell. W3C.</dd>

Expand Down

0 comments on commit 72d084b

Please sign in to comment.