source: draft-ietf-httpbis/20/p7-auth.xml @ 1807

Last change on this file since 1807 was 1807, checked in by julian.reschke@…, 11 years ago

Prepare release of -20 drafts

  • Property svn:eol-style set to native
  • Property svn:mime-type set to text/xml
File size: 52.0 KB
Line 
1<?xml version="1.0" encoding="utf-8"?>
2<?xml-stylesheet type='text/xsl' href='../myxml2rfc.xslt'?>
3<!DOCTYPE rfc [
4  <!ENTITY MAY "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>MAY</bcp14>">
5  <!ENTITY MUST "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>MUST</bcp14>">
6  <!ENTITY MUST-NOT "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>MUST NOT</bcp14>">
7  <!ENTITY OPTIONAL "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>OPTIONAL</bcp14>">
8  <!ENTITY RECOMMENDED "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>RECOMMENDED</bcp14>">
9  <!ENTITY REQUIRED "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>REQUIRED</bcp14>">
10  <!ENTITY SHALL "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHALL</bcp14>">
11  <!ENTITY SHALL-NOT "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHALL NOT</bcp14>">
12  <!ENTITY SHOULD "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHOULD</bcp14>">
13  <!ENTITY SHOULD-NOT "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHOULD NOT</bcp14>">
14  <!ENTITY ID-VERSION "20">
15  <!ENTITY ID-MONTH "July">
16  <!ENTITY ID-YEAR "2012">
17  <!ENTITY mdash "&#8212;">
18  <!ENTITY Note "<x:h xmlns:x='http://purl.org/net/xml2rfc/ext'>Note:</x:h>">
19  <!ENTITY architecture                 "<xref target='Part1' x:rel='#architecture' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
20  <!ENTITY notation                     "<xref target='Part1' x:rel='#notation' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
21  <!ENTITY abnf-extension               "<xref target='Part1' x:rel='#abnf.extension' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
22  <!ENTITY acks                         "<xref target='Part1' x:rel='#acks' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
23  <!ENTITY whitespace                   "<xref target='Part1' x:rel='#whitespace' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
24  <!ENTITY field-components             "<xref target='Part1' x:rel='#field.components' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
25  <!ENTITY effective-request-uri        "<xref target='Part1' x:rel='#effective.request.uri' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
26  <!ENTITY msg-orient-and-buffering     "<xref target='Part1' x:rel='#intermediaries' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
27  <!ENTITY end-to-end.and-hop-by-hop    "<xref target='Part1' x:rel='#end-to-end.and.hop-by-hop.header-fields' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
28  <!ENTITY status.403                   "<xref target='Part2' x:rel='#status.403' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
29  <!ENTITY shared-and-non-shared-caches "<xref target='Part6' x:rel='#shared.and.non-shared.caches' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
30]>
31<?rfc toc="yes" ?>
32<?rfc symrefs="yes" ?>
33<?rfc sortrefs="yes" ?>
34<?rfc compact="yes"?>
35<?rfc subcompact="no" ?>
36<?rfc linkmailto="no" ?>
37<?rfc editing="no" ?>
38<?rfc comments="yes"?>
39<?rfc inline="yes"?>
40<?rfc rfcedstyle="yes"?>
41<?rfc-ext allow-markup-in-artwork="yes" ?>
42<?rfc-ext include-references-in-index="yes" ?>
43<rfc obsoletes="2616" updates="2617" category="std" x:maturity-level="proposed"
44     ipr="pre5378Trust200902" docName="draft-ietf-httpbis-p7-auth-&ID-VERSION;"
45     xmlns:x='http://purl.org/net/xml2rfc/ext'>
46<x:link rel="prev" basename="p6-cache"/>
47<x:feedback template="mailto:ietf-http-wg@w3.org?subject={docname},%20%22{section}%22&amp;body=&lt;{ref}&gt;:"/>
48<front>
49
50  <title abbrev="HTTP/1.1, Part 7">HTTP/1.1, part 7: Authentication</title>
51
52  <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
53    <organization abbrev="Adobe">Adobe Systems Incorporated</organization>
54    <address>
55      <postal>
56        <street>345 Park Ave</street>
57        <city>San Jose</city>
58        <region>CA</region>
59        <code>95110</code>
60        <country>USA</country>
61      </postal>
62      <email>fielding@gbiv.com</email>
63      <uri>http://roy.gbiv.com/</uri>
64    </address>
65  </author>
66
67  <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
68    <organization abbrev="W3C">World Wide Web Consortium</organization>
69    <address>
70      <postal>
71        <street>W3C / ERCIM</street>
72        <street>2004, rte des Lucioles</street>
73        <city>Sophia-Antipolis</city>
74        <region>AM</region>
75        <code>06902</code>
76        <country>France</country>
77      </postal>
78      <email>ylafon@w3.org</email>
79      <uri>http://www.raubacapeu.net/people/yves/</uri>
80    </address>
81  </author>
82
83  <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
84    <organization abbrev="greenbytes">greenbytes GmbH</organization>
85    <address>
86      <postal>
87        <street>Hafenweg 16</street>
88        <city>Muenster</city><region>NW</region><code>48155</code>
89        <country>Germany</country>
90      </postal>
91      <email>julian.reschke@greenbytes.de</email>
92      <uri>http://greenbytes.de/tech/webdav/</uri>
93    </address>
94  </author>
95
96  <date month="&ID-MONTH;" year="&ID-YEAR;" day="16"/>
97  <workgroup>HTTPbis Working Group</workgroup>
98
99<abstract>
100<t>
101   The Hypertext Transfer Protocol (HTTP) is an application-level protocol for
102   distributed, collaborative, hypermedia information systems. HTTP has been in
103   use by the World Wide Web global information initiative since 1990. This
104   document is Part 7 of the seven-part specification that defines the protocol
105   referred to as "HTTP/1.1" and, taken together, obsoletes RFC 2616.
106</t>
107<t>
108   Part 7 defines the HTTP Authentication framework.
109</t>
110</abstract>
111
112<note title="Editorial Note (To be removed by RFC Editor)">
113  <t>
114    Discussion of this draft takes place on the HTTPBIS working group
115    mailing list (ietf-http-wg@w3.org), which is archived at
116    <eref target="http://lists.w3.org/Archives/Public/ietf-http-wg/"/>.
117  </t>
118  <t>
119    The current issues list is at
120    <eref target="http://tools.ietf.org/wg/httpbis/trac/report/3"/> and related
121    documents (including fancy diffs) can be found at
122    <eref target="http://tools.ietf.org/wg/httpbis/"/>.
123  </t>
124  <t>
125    The changes in this draft are summarized in <xref target="changes.since.19"/>.
126  </t>
127</note>
128</front>
129<middle>
130<section title="Introduction" anchor="introduction">
131<t>
132   This document defines HTTP/1.1 access control and authentication. It
133   includes the relevant parts of <xref target="RFC2616" x:fmt="none">RFC 2616</xref>
134   with only minor changes (<xref target="RFC2616"/>), plus the general framework for HTTP authentication,
135   as previously defined in "HTTP Authentication: Basic and Digest Access
136   Authentication" (<xref target="RFC2617"/>).
137</t>
138<t>
139   HTTP provides several &OPTIONAL; challenge-response authentication
140   mechanisms which can be used by a server to challenge a client request and
141   by a client to provide authentication information. The "basic" and "digest"
142   authentication schemes continue to be specified in
143   <xref target="RFC2617" x:fmt="none">RFC 2617</xref>.
144</t>
145
146<section title="Conformance and Error Handling" anchor="intro.conformance.and.error.handling">
147<t>
148   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
149   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
150   document are to be interpreted as described in <xref target="RFC2119"/>.
151</t>
152<t>
153   This specification targets conformance criteria according to the role of
154   a participant in HTTP communication.  Hence, HTTP requirements are placed
155   on senders, recipients, clients, servers, user agents, intermediaries,
156   origin servers, proxies, gateways, or caches, depending on what behavior
157   is being constrained by the requirement. See &architecture; for definitions
158   of these terms.
159</t>
160<t>
161   The verb "generate" is used instead of "send" where a requirement
162   differentiates between creating a protocol element and merely forwarding a
163   received element downstream.
164</t>
165<t>
166   An implementation is considered conformant if it complies with all of the
167   requirements associated with the roles it partakes in HTTP. Note that
168   SHOULD-level requirements are relevant here, unless one of the documented
169   exceptions is applicable.
170</t>
171<t>
172   This document also uses ABNF to define valid protocol elements
173   (<xref target="notation"/>).
174   In addition to the prose requirements placed upon them, senders &MUST-NOT;
175   generate protocol elements that do not match the grammar defined by the
176   ABNF rules for those protocol elements that are applicable to the sender's
177   role. If a received protocol element is processed, the recipient &MUST; be
178   able to parse any value that would match the ABNF rules for that protocol
179   element, excluding only those rules not applicable to the recipient's role.
180</t>
181<t>
182   Unless noted otherwise, a recipient &MAY; attempt to recover a usable
183   protocol element from an invalid construct.  HTTP does not define
184   specific error handling mechanisms except when they have a direct impact
185   on security, since different applications of the protocol require
186   different error handling strategies.  For example, a Web browser might
187   wish to transparently recover from a response where the
188   <x:ref>Location</x:ref> header field doesn't parse according to the ABNF,
189   whereas a systems control client might consider any form of error recovery
190   to be dangerous.
191</t>
192</section>
193
194<section title="Syntax Notation" anchor="notation">
195<t>
196   This specification uses the Augmented Backus-Naur Form (ABNF) notation
197   of <xref target="RFC5234"/> with the list rule extension defined in
198   &notation;. <xref target="imported.abnf"/> describes rules imported from
199   other documents. <xref target="collected.abnf"/> shows the collected ABNF
200   with the list rule expanded.
201</t>
202</section>
203</section>
204
205<section title="Access Authentication Framework" anchor="access.authentication.framework">
206
207<section title="Challenge and Response" anchor="challenge.and.response">
208  <x:anchor-alias value="auth-scheme"/>
209  <x:anchor-alias value="auth-param"/>
210  <x:anchor-alias value="b64token"/>
211  <x:anchor-alias value="challenge"/>
212  <x:anchor-alias value="credentials"/>
213<t>
214   HTTP provides a simple challenge-response authentication mechanism
215   that can be used by a server to challenge a client request and by a
216   client to provide authentication information. It uses an extensible,
217   case-insensitive token to identify the authentication scheme, followed
218   by additional information necessary for achieving authentication via that
219   scheme. The latter can either be a comma-separated list of parameters or a
220   single sequence of characters capable of holding base64-encoded
221   information.
222</t>
223<t>
224   Parameters are name-value pairs where the name is matched case-insensitively,
225   and each parameter name &MUST; only occur once per challenge.
226</t>
227<figure><artwork type="abnf2616"><iref item="auth-scheme" primary="true"/><iref item="auth-param" primary="true"/><iref primary="true" item="Grammar" subitem="auth-scheme"/><iref primary="true" item="Grammar" subitem="auth-param"/><iref item="b64token" primary="true"/><iref primary="true" item="Grammar" subitem="b64token"/>
228  auth-scheme    = <x:ref>token</x:ref>
229 
230  auth-param     = <x:ref>token</x:ref> <x:ref>BWS</x:ref> "=" <x:ref>BWS</x:ref> ( <x:ref>token</x:ref> / <x:ref>quoted-string</x:ref> )
231
232  b64token       = 1*( <x:ref>ALPHA</x:ref> / <x:ref>DIGIT</x:ref> /
233                       "-" / "." / "_" / "~" / "+" / "/" ) *"="
234</artwork></figure>
235<t>
236   The "b64token" syntax allows the 66 unreserved URI characters (<xref target="RFC3986"/>),
237   plus a few others, so that it can hold a base64, base64url (URL and filename
238   safe alphabet), base32, or base16 (hex) encoding, with or without padding, but
239   excluding whitespace (<xref target="RFC4648"/>).
240</t>
241<t>
242   The <x:ref>401 (Unauthorized)</x:ref> response message is used by an origin server
243   to challenge the authorization of a user agent. This response &MUST;
244   include a <x:ref>WWW-Authenticate</x:ref> header field containing at least one
245   challenge applicable to the requested resource.
246</t>
247<t>  
248   The <x:ref>407 (Proxy Authentication Required)</x:ref> response message is
249   used by a proxy to challenge the authorization of a client and &MUST;
250   include a <x:ref>Proxy-Authenticate</x:ref> header field containing at least
251   one challenge applicable to the proxy for the requested resource.
252</t>
253<figure><artwork type="abnf2616"><iref item="challenge" primary="true"/><iref primary="true" item="Grammar" subitem="challenge"/>
254  <x:ref>challenge</x:ref>   = <x:ref>auth-scheme</x:ref> [ 1*<x:ref>SP</x:ref> ( <x:ref>b64token</x:ref> / #<x:ref>auth-param</x:ref> ) ]
255</artwork></figure>
256<x:note>
257  <t>
258     &Note; User agents will need to take special care in parsing the
259     <x:ref>WWW-Authenticate</x:ref> and <x:ref>Proxy-Authenticate</x:ref>
260     header field values because they can contain more than one challenge, or
261     if more than one of each is provided, since the contents of a challenge
262     can itself contain a comma-separated list of authentication parameters.
263  </t>
264</x:note>
265<x:note>
266  <t>
267     &Note; Many clients fail to parse challenges containing unknown
268     schemes. A workaround for this problem is to list well-supported schemes
269     (such as "basic") first.<!-- see http://greenbytes.de/tech/tc/httpauth/#multibasicunknown2 -->
270  </t>
271</x:note>
272<t>
273   A user agent that wishes to authenticate itself with an origin server
274   &mdash; usually, but not necessarily, after receiving a <x:ref>401 (Unauthorized)</x:ref>
275   &mdash; can do so by including an <x:ref>Authorization</x:ref> header field with the
276   request.
277</t>
278<t>  
279   A client that wishes to authenticate itself with a proxy &mdash; usually,
280   but not necessarily, after receiving a <x:ref>407 (Proxy Authentication Required)</x:ref>
281   &mdash; can do so by including a <x:ref>Proxy-Authorization</x:ref> header field with the
282   request.
283</t>
284<t>
285   Both the <x:ref>Authorization</x:ref> field value and the <x:ref>Proxy-Authorization</x:ref> field value
286   contain the client's credentials for the realm of the resource being
287   requested, based upon a challenge received from the server (possibly at
288   some point in the past). When creating their values, the user agent ought to
289   do so by selecting the challenge with what it considers to be the most
290   secure auth-scheme that it understands, obtaining credentials from the user
291   as appropriate.
292</t>
293<figure><artwork type="abnf2616"><iref item="credentials" primary="true"/><iref primary="true" item="Grammar" subitem="credentials"/>
294  <x:ref>credentials</x:ref> = <x:ref>auth-scheme</x:ref> [ 1*<x:ref>SP</x:ref> ( <x:ref>b64token</x:ref> / #<x:ref>auth-param</x:ref> ) ]
295</artwork></figure>
296<t>
297   Upon a request for a protected resource that omits credentials, contains
298   invalid credentials (e.g., a bad password) or partial credentials (e.g.,
299   when the authentication scheme requires more than one round trip), an origin
300   server &SHOULD; return a <x:ref>401 (Unauthorized)</x:ref> response. Such
301   responses &MUST; include a <x:ref>WWW-Authenticate</x:ref> header field
302   containing at least one (possibly new) challenge applicable to the
303   requested resource.
304</t>
305<t>
306   Likewise, upon a request that requires authentication by proxies that omit
307   credentials or contain invalid or partial credentials, a proxy &SHOULD;
308   return a <x:ref>407 (Proxy Authentication Required)</x:ref> response. Such responses
309   &MUST; include a <x:ref>Proxy-Authenticate</x:ref> header field containing a (possibly
310   new) challenge applicable to the proxy.
311</t>
312<t>
313   A server receiving credentials that are valid, but not adequate to gain
314   access, ought to respond with the <x:ref>403 (Forbidden)</x:ref> status code (&status.403;).
315</t>
316<t>
317   The HTTP protocol does not restrict applications to this simple
318   challenge-response mechanism for access authentication. Additional
319   mechanisms &MAY; be used, such as encryption at the transport level or
320   via message encapsulation, and with additional header fields
321   specifying authentication information. However, such additional
322   mechanisms are not defined by this specification.
323</t>
324<t>
325   Proxies &MUST; forward the <x:ref>WWW-Authenticate</x:ref> and
326   <x:ref>Authorization</x:ref> header fields unmodified and follow the rules
327   found in <xref target="header.authorization"/>.
328</t>
329</section>
330
331<section title="Protection Space (Realm)" anchor="protection.space">
332  <iref item="Protection Space"/>
333  <iref item="Realm"/>
334  <iref item="Canonical Root URI"/>
335<t>
336   The authentication parameter realm is reserved for use by authentication
337   schemes that wish to indicate the scope of protection.
338</t>
339<t>
340   A <x:dfn>protection space</x:dfn> is defined by the canonical root URI (the
341   scheme and authority components of the effective request URI; see
342   <xref target="Part1" x:fmt="of" x:rel="#effective.request.uri"/>) of the
343   server being accessed, in combination with the realm value if present.
344   These realms allow the protected resources on a server to be
345   partitioned into a set of protection spaces, each with its own
346   authentication scheme and/or authorization database. The realm value
347   is a string, generally assigned by the origin server, which can have
348   additional semantics specific to the authentication scheme. Note that
349   there can be multiple challenges with the same auth-scheme but
350   different realms.
351</t>
352<t>
353   The protection space determines the domain over which credentials can
354   be automatically applied. If a prior request has been authorized, the
355   same credentials &MAY; be reused for all other requests within that
356   protection space for a period of time determined by the
357   authentication scheme, parameters, and/or user preference. Unless
358   otherwise defined by the authentication scheme, a single protection
359   space cannot extend outside the scope of its server.
360</t>
361<t>
362   For historical reasons, senders &MUST; only use the quoted-string syntax.
363   Recipients might have to support both token and quoted-string syntax for
364   maximum interoperability with existing clients that have been accepting both
365   notations for a long time.
366</t>
367</section>
368
369<section title="Authentication Scheme Registry" anchor="authentication.scheme.registry">
370<t>
371  The HTTP Authentication Scheme Registry defines the name space for the
372  authentication schemes in challenges and credentials.
373</t>
374<t>
375  Registrations &MUST; include the following fields:
376  <list style="symbols">
377    <t>Authentication Scheme Name</t>
378    <t>Pointer to specification text</t>
379    <t>Notes (optional)</t>
380  </list>
381</t>
382<t>
383  Values to be added to this name space require IETF Review
384  (see <xref target="RFC5226" x:fmt="," x:sec="4.1"/>).
385</t>
386<t>
387  The registry itself is maintained at <eref target="http://www.iana.org/assignments/http-authschemes"/>.
388</t>
389
390<section title="Considerations for New Authentication Schemes" anchor="considerations.for.new.authentication.schemes">
391<t>
392  There are certain aspects of the HTTP Authentication Framework that put
393  constraints on how new authentication schemes can work:
394</t>
395<t>
396  <list style="symbols">
397    <x:lt>
398    <t>
399      HTTP authentication is presumed to be stateless: all of the information
400      necessary to authenticate a request &MUST; be provided in the request,
401      rather than be dependent on the server remembering prior requests.
402      Authentication based on, or bound to, the underlying connection is
403      outside the scope of this specification and inherently flawed unless
404      steps are taken to ensure that the connection cannot be used by any
405      party other than the authenticated user
406      (see &msg-orient-and-buffering;).
407    </t>
408    </x:lt>
409    <x:lt>
410    <t>
411      The authentication parameter "realm" is reserved for defining Protection
412      Spaces as defined in <xref target="protection.space"/>. New schemes
413      &MUST-NOT; use it in a way incompatible with that definition.
414    </t>
415    </x:lt>
416    <x:lt>
417    <t>
418      The "b64token" notation was introduced for compatibility with existing
419      authentication schemes and can only be used once per challenge/credentials.
420      New schemes thus ought to use the "auth-param" syntax instead, because
421      otherwise future extensions will be impossible.
422    </t>
423    </x:lt>
424    <x:lt>
425    <t>
426      The parsing of challenges and credentials is defined by this specification,
427      and cannot be modified by new authentication schemes. When the auth-param
428      syntax is used, all parameters ought to support both token and
429      quoted-string syntax, and syntactical constraints ought to be defined on
430      the field value after parsing (i.e., quoted-string processing). This is
431      necessary so that recipients can use a generic parser that applies to
432      all authentication schemes.
433    </t>
434    <t>
435      &Note; The fact that the value syntax for the "realm" parameter
436      is restricted to quoted-string was a bad design choice not to be repeated
437      for new parameters.
438    </t>
439    </x:lt>
440    <x:lt>
441    <t>
442      Definitions of new schemes ought to define the treatment of unknown
443      extension parameters. In general, a "must-ignore" rule is preferable
444      over "must-understand", because otherwise it will be hard to introduce
445      new parameters in the presence of legacy recipients. Furthermore,
446      it's good to describe the policy for defining new parameters (such
447      as "update the specification", or "use this registry").
448    </t>
449    </x:lt>
450    <x:lt>
451    <t>
452      Authentication schemes need to document whether they are usable in
453      origin-server authentication (i.e., using <x:ref>WWW-Authenticate</x:ref>),
454      and/or proxy authentication (i.e., using <x:ref>Proxy-Authenticate</x:ref>).
455    </t>
456    </x:lt>
457    <x:lt>
458    <t>
459      The credentials carried in an <x:ref>Authorization</x:ref> header field are specific to
460      the User Agent, and therefore have the same effect on HTTP caches as the
461      "private" Cache-Control response directive, within the scope of the
462      request they appear in.
463    </t>
464    <t>
465      Therefore, new authentication schemes which choose not to carry
466      credentials in the <x:ref>Authorization</x:ref> header field (e.g., using a newly defined
467      header field) will need to explicitly disallow caching, by mandating the use of
468      either Cache-Control request directives (e.g., "no-store") or response
469      directives (e.g., "private").
470    </t>
471    </x:lt>
472  </list>
473</t>
474</section>
475
476</section>
477
478</section>
479
480<section title="Status Code Definitions" anchor="status.code.definitions">
481<section title="401 Unauthorized" anchor="status.401">
482  <iref primary="true" item="401 Unauthorized (status code)" x:for-anchor=""/>
483  <iref primary="true" item="Status Codes" subitem="401 Unauthorized" x:for-anchor=""/>
484  <x:anchor-alias value="401 (Unauthorized)"/>
485<t>
486   The request requires user authentication. The response &MUST; include a
487   <x:ref>WWW-Authenticate</x:ref> header field (<xref target="header.www-authenticate"/>)
488   containing a challenge applicable to the target resource. The client &MAY;
489   repeat the request with a suitable <x:ref>Authorization</x:ref> header field
490   (<xref target="header.authorization"/>). If the request already included
491   Authorization credentials, then the 401 response indicates that authorization
492   has been refused for those credentials. If the 401 response contains the
493   same challenge as the prior response, and the user agent has already attempted
494   authentication at least once, then the user &SHOULD; be presented the
495   representation that was given in the response, since that representation might
496   include relevant diagnostic information.
497</t>
498</section>
499<section title="407 Proxy Authentication Required" anchor="status.407">
500  <iref primary="true" item="407 Proxy Authentication Required (status code)" x:for-anchor=""/>
501  <iref primary="true" item="Status Codes" subitem="407 Proxy Authentication Required" x:for-anchor=""/>
502  <x:anchor-alias value="407 (Proxy Authentication Required)"/>
503<t>
504   This code is similar to <x:ref>401 (Unauthorized)</x:ref>, but indicates that the
505   client ought to first authenticate itself with the proxy. The proxy &MUST;
506   return a <x:ref>Proxy-Authenticate</x:ref> header field (<xref target="header.proxy-authenticate"/>) containing a
507   challenge applicable to the proxy for the target resource. The
508   client &MAY; repeat the request with a suitable <x:ref>Proxy-Authorization</x:ref>
509   header field (<xref target="header.proxy-authorization"/>).
510</t>
511</section>
512</section>
513
514<section title="Header Field Definitions" anchor="header.field.definitions">
515<t>
516   This section defines the syntax and semantics of HTTP/1.1 header fields
517   related to authentication.
518</t>
519
520<section title="Authorization" anchor="header.authorization">
521  <iref primary="true" item="Authorization header field" x:for-anchor=""/>
522  <iref primary="true" item="Header Fields" subitem="Authorization" x:for-anchor=""/>
523  <x:anchor-alias value="Authorization"/>
524<t>
525   The "Authorization" header field allows a user agent to authenticate
526   itself with a server &mdash; usually, but not necessarily, after receiving a <x:ref>401
527   (Unauthorized)</x:ref> response. Its value consists of credentials containing
528   information of the user agent for the realm of the resource being
529   requested.
530</t>
531<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Authorization"/>
532  <x:ref>Authorization</x:ref> = <x:ref>credentials</x:ref>
533</artwork></figure>
534<t>
535   If a request is
536   authenticated and a realm specified, the same credentials &SHOULD;
537   be valid for all other requests within this realm (assuming that
538   the authentication scheme itself does not require otherwise, such
539   as credentials that vary according to a challenge value or using
540   synchronized clocks).
541</t>
542<t>
543      When a shared cache (see &shared-and-non-shared-caches;) receives a request
544      containing an Authorization field, it &MUST-NOT; return the
545      corresponding response as a reply to any other request, unless one
546      of the following specific exceptions holds:
547</t>
548<t>
549  <list style="numbers">
550      <t>If the response includes the "s-maxage" cache-control
551         directive, the cache &MAY; use that response in replying to a
552         subsequent request. But (if the specified maximum age has
553         passed) a proxy cache &MUST; first revalidate it with the origin
554         server, using the header fields from the new request to allow
555         the origin server to authenticate the new request. (This is the
556         defined behavior for s-maxage.) If the response includes "s-maxage=0",
557         the proxy &MUST; always revalidate it before re-using
558         it.</t>
559
560      <t>If the response includes the "must-revalidate" cache-control
561         directive, the cache &MAY; use that response in replying to a
562         subsequent request. But if the response is stale, all caches
563         &MUST; first revalidate it with the origin server, using the
564         header fields from the new request to allow the origin server
565         to authenticate the new request.</t>
566
567      <t>If the response includes the "public" cache-control directive,
568         it &MAY; be returned in reply to any subsequent request.</t>
569  </list>
570</t>
571</section>
572
573<section title="Proxy-Authenticate" anchor="header.proxy-authenticate">
574  <iref primary="true" item="Proxy-Authenticate header field" x:for-anchor=""/>
575  <iref primary="true" item="Header Fields" subitem="Proxy-Authenticate" x:for-anchor=""/>
576  <x:anchor-alias value="Proxy-Authenticate"/>
577<t>
578   The "Proxy-Authenticate" header field consists of at least one
579   challenge that indicates the authentication scheme(s) and parameters
580   applicable to the proxy for this effective request URI (&effective-request-uri;).
581   It &MUST; be included as part of a <x:ref>407 (Proxy Authentication Required)</x:ref> response.
582</t>
583<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Proxy-Authenticate"/>
584  <x:ref>Proxy-Authenticate</x:ref> = 1#<x:ref>challenge</x:ref>
585</artwork></figure>
586<t>
587   Unlike <x:ref>WWW-Authenticate</x:ref>, the Proxy-Authenticate header field
588   applies only to the current connection, and intermediaries &SHOULD-NOT;
589   forward it to downstream clients. However, an intermediate proxy might need
590   to obtain its own credentials by requesting them from the downstream client,
591   which in some circumstances will appear as if the proxy is forwarding the
592   Proxy-Authenticate header field.
593</t>
594<t>
595   Note that the parsing considerations for <x:ref>WWW-Authenticate</x:ref>
596   apply to this header field as well; see <xref target="header.www-authenticate"/>
597   for details.
598</t>
599</section>
600
601<section title="Proxy-Authorization" anchor="header.proxy-authorization">
602  <iref primary="true" item="Proxy-Authorization header field" x:for-anchor=""/>
603  <iref primary="true" item="Header Fields" subitem="Proxy-Authorization" x:for-anchor=""/>
604  <x:anchor-alias value="Proxy-Authorization"/>
605<t>
606   The "Proxy-Authorization" header field allows the client to
607   identify itself (or its user) to a proxy which requires
608   authentication. Its value consists of
609   credentials containing the authentication information of the user
610   agent for the proxy and/or realm of the resource being requested.
611</t>
612<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Proxy-Authorization"/>
613  <x:ref>Proxy-Authorization</x:ref> = <x:ref>credentials</x:ref>
614</artwork></figure>
615<t>
616   Unlike <x:ref>Authorization</x:ref>, the Proxy-Authorization header field applies only to
617   the next outbound proxy that demanded authentication using the <x:ref>Proxy-Authenticate</x:ref>
618   field. When multiple proxies are used in a chain, the
619   Proxy-Authorization header field is consumed by the first outbound
620   proxy that was expecting to receive credentials. A proxy &MAY; relay
621   the credentials from the client request to the next proxy if that is
622   the mechanism by which the proxies cooperatively authenticate a given
623   request.
624</t>
625</section>
626
627<section title="WWW-Authenticate" anchor="header.www-authenticate">
628  <iref primary="true" item="WWW-Authenticate header field" x:for-anchor=""/>
629  <iref primary="true" item="Header Fields" subitem="WWW-Authenticate" x:for-anchor=""/>
630  <x:anchor-alias value="WWW-Authenticate"/>
631<t>
632   The "WWW-Authenticate" header field consists of at least one
633   challenge that indicates the authentication scheme(s) and parameters
634   applicable to the effective request URI (&effective-request-uri;).
635</t>
636<t>  
637   It &MUST; be included in <x:ref>401 (Unauthorized)</x:ref> response messages and &MAY; be
638   included in other response messages to indicate that supplying credentials
639   (or different credentials) might affect the response.
640</t>
641<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="WWW-Authenticate"/>
642  <x:ref>WWW-Authenticate</x:ref> = 1#<x:ref>challenge</x:ref>
643</artwork></figure>
644<t>
645   User agents are advised to take special care in parsing the WWW-Authenticate
646   field value as it might contain more than one challenge,
647   or if more than one WWW-Authenticate header field is provided, the
648   contents of a challenge itself can contain a comma-separated list of
649   authentication parameters.
650</t>
651<figure>
652  <preamble>For instance:</preamble>
653  <artwork type="example">
654  WWW-Authenticate: Newauth realm="apps", type=1,
655                    title="Login to \"apps\"", Basic realm="simple"
656</artwork>
657  <postamble>
658  This header field contains two challenges; one for the "Newauth" scheme
659  with a realm value of "apps", and two additional parameters "type" and
660  "title", and another one for the "Basic" scheme with a realm value of
661  "simple".
662</postamble></figure>
663<x:note>
664  <t>
665    &Note; The challenge grammar production uses the list syntax as
666    well. Therefore, a sequence of comma, whitespace, and comma can be
667    considered both as applying to the preceding challenge, or to be an
668    empty entry in the list of challenges. In practice, this ambiguity
669    does not affect the semantics of the header field value and thus is
670    harmless.
671  </t>
672</x:note>
673</section>
674
675</section>
676
677<section title="IANA Considerations" anchor="IANA.considerations">
678
679<section title="Authentication Scheme Registry" anchor="authentication.scheme.registration">
680<t>
681  The registration procedure for HTTP Authentication Schemes is defined by
682  <xref target="authentication.scheme.registry"/> of this document.
683</t>
684<t>
685   The HTTP Method Authentication Scheme shall be created at <eref target="http://www.iana.org/assignments/http-authschemes"/>.
686</t>
687</section>
688
689<section title="Status Code Registration" anchor="status.code.registration">
690<t>
691   The HTTP Status Code Registry located at <eref target="http://www.iana.org/assignments/http-status-codes"/>
692   shall be updated with the registrations below:
693</t>
694<?BEGININC p7-auth.iana-status-codes ?>
695<!--AUTOGENERATED FROM extract-status-code-defs.xslt, do not edit manually-->
696<texttable align="left" suppress-title="true" anchor="iana.status.code.registration.table">
697   <ttcol>Value</ttcol>
698   <ttcol>Description</ttcol>
699   <ttcol>Reference</ttcol>
700   <c>401</c>
701   <c>Unauthorized</c>
702   <c>
703      <xref target="status.401"/>
704   </c>
705   <c>407</c>
706   <c>Proxy Authentication Required</c>
707   <c>
708      <xref target="status.407"/>
709   </c>
710</texttable>
711<!--(END)-->
712<?ENDINC p7-auth.iana-status-codes ?>
713</section>
714
715<section title="Header Field Registration" anchor="header.field.registration">
716<t>
717   The Message Header Field Registry located at <eref target="http://www.iana.org/assignments/message-headers/message-header-index.html"/> shall be updated
718   with the permanent registrations below (see <xref target="RFC3864"/>):
719</t>
720<?BEGININC p7-auth.iana-headers ?>
721<!--AUTOGENERATED FROM extract-header-defs.xslt, do not edit manually-->
722<texttable align="left" suppress-title="true" anchor="iana.header.registration.table">
723   <ttcol>Header Field Name</ttcol>
724   <ttcol>Protocol</ttcol>
725   <ttcol>Status</ttcol>
726   <ttcol>Reference</ttcol>
727
728   <c>Authorization</c>
729   <c>http</c>
730   <c>standard</c>
731   <c>
732      <xref target="header.authorization"/>
733   </c>
734   <c>Proxy-Authenticate</c>
735   <c>http</c>
736   <c>standard</c>
737   <c>
738      <xref target="header.proxy-authenticate"/>
739   </c>
740   <c>Proxy-Authorization</c>
741   <c>http</c>
742   <c>standard</c>
743   <c>
744      <xref target="header.proxy-authorization"/>
745   </c>
746   <c>WWW-Authenticate</c>
747   <c>http</c>
748   <c>standard</c>
749   <c>
750      <xref target="header.www-authenticate"/>
751   </c>
752</texttable>
753<!--(END)-->
754<?ENDINC p7-auth.iana-headers ?>
755<t>
756   The change controller is: "IETF (iesg@ietf.org) - Internet Engineering Task Force".
757</t>
758</section>
759</section>
760
761<section title="Security Considerations" anchor="security.considerations">
762<t>
763   This section is meant to inform application developers, information
764   providers, and users of the security limitations in HTTP/1.1 as
765   described by this document. The discussion does not include
766   definitive solutions to the problems revealed, though it does make
767   some suggestions for reducing security risks.
768</t>
769
770<section title="Authentication Credentials and Idle Clients" anchor="auth.credentials.and.idle.clients">
771<t>
772   Existing HTTP clients and user agents typically retain authentication
773   information indefinitely. HTTP/1.1 does not provide a method for a
774   server to direct clients to discard these cached credentials. This is
775   a significant defect that requires further extensions to HTTP.
776   Circumstances under which credential caching can interfere with the
777   application's security model include but are not limited to:
778  <list style="symbols">
779     <t>Clients which have been idle for an extended period following
780        which the server might wish to cause the client to reprompt the
781        user for credentials.</t>
782
783     <t>Applications which include a session termination indication
784        (such as a "logout" or "commit" button on a page) after which
785        the server side of the application "knows" that there is no
786        further reason for the client to retain the credentials.</t>
787  </list>
788</t>
789<t>
790   This is currently under separate study. There are a number of work-arounds
791   to parts of this problem, and we encourage the use of
792   password protection in screen savers, idle time-outs, and other
793   methods which mitigate the security problems inherent in this
794   problem. In particular, user agents which cache credentials are
795   encouraged to provide a readily accessible mechanism for discarding
796   cached credentials under user control.
797</t>
798</section>
799
800<section title="Protection Spaces" anchor="protection.spaces">
801<t>
802  Authentication schemes that solely rely on the "realm" mechanism for
803  establishing a protection space will expose credentials to all resources on a
804  server. Clients that have successfully made authenticated requests with a
805  resource can use the same authentication credentials for other resources on
806  the same server. This makes it possible for a different resource to harvest
807  authentication credentials for other resources.
808</t>
809<t>
810  This is of particular concern when a server hosts resources for multiple
811  parties under the same canonical root URI (<xref target="protection.space"/>).
812  Possible mitigation strategies include restricting direct access to
813  authentication credentials (i.e., not making the content of the
814  <x:ref>Authorization</x:ref> request header field available), and separating protection
815  spaces by using a different host name for each party.
816</t>
817</section>
818</section>
819
820<section title="Acknowledgments" anchor="acks">
821<t>
822  This specification takes over the definition of the HTTP Authentication
823  Framework, previously defined in <xref target="RFC2617" x:fmt="none">RFC 2617</xref>.
824  We thank John Franks, Phillip M. Hallam-Baker, Jeffery L. Hostetler, Scott D. Lawrence,
825  Paul J. Leach, Ari Luotonen, and Lawrence C. Stewart for their work
826  on that specification. See <xref target="RFC2617" x:fmt="of" x:sec="6"/>
827  for further acknowledgements. 
828</t>
829<t>
830  See &acks; for the Acknowledgments related to this document revision.
831</t>
832</section>
833</middle>
834
835<back>
836
837<references title="Normative References">
838
839<reference anchor="Part1">
840  <front>
841    <title>HTTP/1.1, part 1: Message Routing and Syntax"</title>
842    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
843      <organization abbrev="Adobe">Adobe Systems Incorporated</organization>
844      <address><email>fielding@gbiv.com</email></address>
845    </author>
846    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
847      <organization abbrev="W3C">World Wide Web Consortium</organization>
848      <address><email>ylafon@w3.org</email></address>
849    </author>
850    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
851      <organization abbrev="greenbytes">greenbytes GmbH</organization>
852      <address><email>julian.reschke@greenbytes.de</email></address>
853    </author>
854    <date month="&ID-MONTH;" year="&ID-YEAR;"/>
855  </front>
856  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p1-messaging-&ID-VERSION;"/>
857  <x:source href="p1-messaging.xml" basename="p1-messaging"/>
858</reference>
859
860<reference anchor="Part2">
861  <front>
862    <title>HTTP/1.1, part 2: Semantics and Payloads</title>
863    <author fullname="Roy T. Fielding" initials="R." role="editor" surname="Fielding">
864      <organization abbrev="Adobe">Adobe Systems Incorporated</organization>
865      <address><email>fielding@gbiv.com</email></address>
866    </author>
867    <author fullname="Yves Lafon" initials="Y." role="editor" surname="Lafon">
868      <organization abbrev="W3C">World Wide Web Consortium</organization>
869      <address><email>ylafon@w3.org</email></address>
870    </author>
871    <author fullname="Julian F. Reschke" initials="J. F." role="editor" surname="Reschke">
872      <organization abbrev="greenbytes">greenbytes GmbH</organization>
873      <address><email>julian.reschke@greenbytes.de</email></address>
874    </author>
875    <date month="&ID-MONTH;" year="&ID-YEAR;" />
876  </front>
877  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p2-semantics-&ID-VERSION;" />
878  <x:source basename="p2-semantics" href="p2-semantics.xml">
879    <x:defines>403 (Forbidden)</x:defines>
880    <x:defines>Location</x:defines>
881  </x:source>
882</reference>
883
884<reference anchor="Part6">
885  <front>
886    <title>HTTP/1.1, part 6: Caching</title>
887    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
888      <organization abbrev="Adobe">Adobe Systems Incorporated</organization>
889      <address><email>fielding@gbiv.com</email></address>
890    </author>
891    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
892      <organization abbrev="W3C">World Wide Web Consortium</organization>
893      <address><email>ylafon@w3.org</email></address>
894    </author>
895    <author initials="M." surname="Nottingham" fullname="Mark Nottingham" role="editor">
896      <organization>Rackspace</organization>
897      <address><email>mnot@mnot.net</email></address>
898    </author>
899    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
900      <organization abbrev="greenbytes">greenbytes GmbH</organization>
901      <address><email>julian.reschke@greenbytes.de</email></address>
902    </author>
903    <date month="&ID-MONTH;" year="&ID-YEAR;"/>
904  </front>
905  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p6-cache-&ID-VERSION;"/>
906  <x:source href="p6-cache.xml" basename="p6-cache"/>
907</reference>
908
909<reference anchor="RFC2119">
910  <front>
911    <title>Key words for use in RFCs to Indicate Requirement Levels</title>
912    <author initials="S." surname="Bradner" fullname="Scott Bradner">
913      <organization>Harvard University</organization>
914      <address><email>sob@harvard.edu</email></address>
915    </author>
916    <date month="March" year="1997"/>
917  </front>
918  <seriesInfo name="BCP" value="14"/>
919  <seriesInfo name="RFC" value="2119"/>
920</reference>
921
922<reference anchor="RFC5234">
923  <front>
924    <title abbrev="ABNF for Syntax Specifications">Augmented BNF for Syntax Specifications: ABNF</title>
925    <author initials="D." surname="Crocker" fullname="Dave Crocker" role="editor">
926      <organization>Brandenburg InternetWorking</organization>
927      <address>
928        <email>dcrocker@bbiw.net</email>
929      </address> 
930    </author>
931    <author initials="P." surname="Overell" fullname="Paul Overell">
932      <organization>THUS plc.</organization>
933      <address>
934        <email>paul.overell@thus.net</email>
935      </address>
936    </author>
937    <date month="January" year="2008"/>
938  </front>
939  <seriesInfo name="STD" value="68"/>
940  <seriesInfo name="RFC" value="5234"/>
941</reference>
942
943</references>
944
945<references title="Informative References">
946
947<reference anchor="RFC2616">
948  <front>
949    <title>Hypertext Transfer Protocol -- HTTP/1.1</title>
950    <author initials="R." surname="Fielding" fullname="R. Fielding">
951      <organization>University of California, Irvine</organization>
952      <address><email>fielding@ics.uci.edu</email></address>
953    </author>
954    <author initials="J." surname="Gettys" fullname="J. Gettys">
955      <organization>W3C</organization>
956      <address><email>jg@w3.org</email></address>
957    </author>
958    <author initials="J." surname="Mogul" fullname="J. Mogul">
959      <organization>Compaq Computer Corporation</organization>
960      <address><email>mogul@wrl.dec.com</email></address>
961    </author>
962    <author initials="H." surname="Frystyk" fullname="H. Frystyk">
963      <organization>MIT Laboratory for Computer Science</organization>
964      <address><email>frystyk@w3.org</email></address>
965    </author>
966    <author initials="L." surname="Masinter" fullname="L. Masinter">
967      <organization>Xerox Corporation</organization>
968      <address><email>masinter@parc.xerox.com</email></address>
969    </author>
970    <author initials="P." surname="Leach" fullname="P. Leach">
971      <organization>Microsoft Corporation</organization>
972      <address><email>paulle@microsoft.com</email></address>
973    </author>
974    <author initials="T." surname="Berners-Lee" fullname="T. Berners-Lee">
975      <organization>W3C</organization>
976      <address><email>timbl@w3.org</email></address>
977    </author>
978    <date month="June" year="1999"/>
979  </front>
980  <seriesInfo name="RFC" value="2616"/>
981</reference>
982
983<reference anchor="RFC2617">
984  <front>
985    <title abbrev="HTTP Authentication">HTTP Authentication: Basic and Digest Access Authentication</title>
986    <author initials="J." surname="Franks" fullname="John Franks">
987      <organization>Northwestern University, Department of Mathematics</organization>
988      <address><email>john@math.nwu.edu</email></address>
989    </author>
990    <author initials="P.M." surname="Hallam-Baker" fullname="Phillip M. Hallam-Baker">
991      <organization>Verisign Inc.</organization>
992      <address><email>pbaker@verisign.com</email></address>
993    </author>
994    <author initials="J.L." surname="Hostetler" fullname="Jeffery L. Hostetler">
995      <organization>AbiSource, Inc.</organization>
996      <address><email>jeff@AbiSource.com</email></address>
997    </author>
998    <author initials="S.D." surname="Lawrence" fullname="Scott D. Lawrence">
999      <organization>Agranat Systems, Inc.</organization>
1000      <address><email>lawrence@agranat.com</email></address>
1001    </author>
1002    <author initials="P.J." surname="Leach" fullname="Paul J. Leach">
1003      <organization>Microsoft Corporation</organization>
1004      <address><email>paulle@microsoft.com</email></address>
1005    </author>
1006    <author initials="A." surname="Luotonen" fullname="Ari Luotonen">
1007      <organization>Netscape Communications Corporation</organization>
1008    </author>
1009    <author initials="L." surname="Stewart" fullname="Lawrence C. Stewart">
1010      <organization>Open Market, Inc.</organization>
1011      <address><email>stewart@OpenMarket.com</email></address>
1012    </author>
1013    <date month="June" year="1999"/>
1014  </front>
1015  <seriesInfo name="RFC" value="2617"/>
1016</reference>
1017
1018<reference anchor='RFC3864'>
1019  <front>
1020    <title>Registration Procedures for Message Header Fields</title>
1021    <author initials='G.' surname='Klyne' fullname='G. Klyne'>
1022      <organization>Nine by Nine</organization>
1023      <address><email>GK-IETF@ninebynine.org</email></address>
1024    </author>
1025    <author initials='M.' surname='Nottingham' fullname='M. Nottingham'>
1026      <organization>BEA Systems</organization>
1027      <address><email>mnot@pobox.com</email></address>
1028    </author>
1029    <author initials='J.' surname='Mogul' fullname='J. Mogul'>
1030      <organization>HP Labs</organization>
1031      <address><email>JeffMogul@acm.org</email></address>
1032    </author>
1033    <date year='2004' month='September' />
1034  </front>
1035  <seriesInfo name='BCP' value='90' />
1036  <seriesInfo name='RFC' value='3864' />
1037</reference>
1038
1039<reference anchor="RFC3986">
1040 <front>
1041  <title abbrev='URI Generic Syntax'>Uniform Resource Identifier (URI): Generic Syntax</title>
1042  <author initials='T.' surname='Berners-Lee' fullname='Tim Berners-Lee'>
1043    <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
1044    <address>
1045       <email>timbl@w3.org</email>
1046       <uri>http://www.w3.org/People/Berners-Lee/</uri>
1047    </address>
1048  </author>
1049  <author initials='R.' surname='Fielding' fullname='Roy T. Fielding'>
1050    <organization abbrev="Day Software">Day Software</organization>
1051    <address>
1052      <email>fielding@gbiv.com</email>
1053      <uri>http://roy.gbiv.com/</uri>
1054    </address>
1055  </author>
1056  <author initials='L.' surname='Masinter' fullname='Larry Masinter'>
1057    <organization abbrev="Adobe Systems">Adobe Systems Incorporated</organization>
1058    <address>
1059      <email>LMM@acm.org</email>
1060      <uri>http://larry.masinter.net/</uri>
1061    </address>
1062  </author>
1063  <date month='January' year='2005'></date>
1064 </front>
1065 <seriesInfo name="STD" value="66"/>
1066 <seriesInfo name="RFC" value="3986"/>
1067</reference>
1068
1069<reference anchor="RFC4648">
1070  <front>
1071    <title>The Base16, Base32, and Base64 Data Encodings</title>
1072    <author fullname="S. Josefsson" initials="S." surname="Josefsson"/>
1073    <date year="2006" month="October"/>
1074  </front>
1075  <seriesInfo value="4648" name="RFC"/>
1076</reference>
1077
1078<reference anchor='RFC5226'>
1079  <front>
1080    <title>Guidelines for Writing an IANA Considerations Section in RFCs</title>
1081    <author initials='T.' surname='Narten' fullname='T. Narten'>
1082      <organization>IBM</organization>
1083      <address><email>narten@us.ibm.com</email></address>
1084    </author>
1085    <author initials='H.' surname='Alvestrand' fullname='H. Alvestrand'>
1086      <organization>Google</organization>
1087      <address><email>Harald@Alvestrand.no</email></address>
1088    </author>
1089    <date year='2008' month='May' />
1090  </front>
1091  <seriesInfo name='BCP' value='26' />
1092  <seriesInfo name='RFC' value='5226' />
1093</reference>
1094
1095</references>
1096
1097<section title="Changes from RFCs 2616 and 2617" anchor="changes.from.rfc.2616">
1098<t>
1099  The "realm" parameter isn't required anymore in general; consequently, the
1100  ABNF allows challenges without any auth parameters.
1101  (<xref target="access.authentication.framework"/>)
1102</t>
1103<t>
1104  The "b64token" alternative to auth-param lists has been added for consistency
1105  with legacy authentication schemes such as "Basic".
1106  (<xref target="access.authentication.framework"/>)
1107</t>
1108<t>
1109  Introduce Authentication Scheme Registry.
1110  (<xref target="authentication.scheme.registry"/>)
1111</t>
1112<t>
1113  Change ABNF productions for header fields to only define the field value.
1114  (<xref target="header.field.definitions"/>)
1115</t>
1116</section>
1117 
1118<section title="Imported ABNF" anchor="imported.abnf">
1119  <x:anchor-alias value="ALPHA"/>
1120  <x:anchor-alias value="CR"/>
1121  <x:anchor-alias value="DIGIT"/>
1122  <x:anchor-alias value="LF"/>
1123  <x:anchor-alias value="OCTET"/>
1124  <x:anchor-alias value="VCHAR"/>
1125  <x:anchor-alias value="SP"/>
1126  <x:anchor-alias value="quoted-string"/>
1127  <x:anchor-alias value="token"/>
1128  <x:anchor-alias value="BWS"/>
1129  <x:anchor-alias value="OWS"/>
1130<t>
1131  The following core rules are included by
1132  reference, as defined in <xref target="RFC5234" x:fmt="of" x:sec="B.1"/>:
1133  ALPHA (letters), CR (carriage return), CRLF (CR LF), CTL (controls),
1134  DIGIT (decimal 0-9), DQUOTE (double quote),
1135  HEXDIG (hexadecimal 0-9/A-F/a-f), LF (line feed),
1136  OCTET (any 8-bit sequence of data), SP (space), and
1137  VCHAR (any visible US-ASCII character).
1138</t>
1139<t>
1140   The rules below are defined in <xref target="Part1"/>:
1141</t>
1142<figure><artwork type="abnf2616">
1143  <x:ref>BWS</x:ref>           = &lt;BWS, defined in &whitespace;&gt;
1144  <x:ref>OWS</x:ref>           = &lt;OWS, defined in &whitespace;&gt;
1145  <x:ref>quoted-string</x:ref> = &lt;quoted-string, defined in &field-components;&gt;
1146  <x:ref>token</x:ref>         = &lt;token, defined in &field-components;&gt;
1147</artwork></figure>
1148</section>
1149
1150<?BEGININC p7-auth.abnf-appendix ?>
1151<section xmlns:x="http://purl.org/net/xml2rfc/ext" title="Collected ABNF" anchor="collected.abnf">
1152<figure>
1153<artwork type="abnf" name="p7-auth.parsed-abnf">
1154<x:ref>Authorization</x:ref> = credentials
1155
1156<x:ref>BWS</x:ref> = &lt;BWS, defined in [Part1], Section 3.2.1&gt;
1157
1158<x:ref>OWS</x:ref> = &lt;OWS, defined in [Part1], Section 3.2.1&gt;
1159
1160<x:ref>Proxy-Authenticate</x:ref> = *( "," OWS ) challenge *( OWS "," [ OWS
1161 challenge ] )
1162<x:ref>Proxy-Authorization</x:ref> = credentials
1163
1164<x:ref>WWW-Authenticate</x:ref> = *( "," OWS ) challenge *( OWS "," [ OWS challenge
1165 ] )
1166
1167<x:ref>auth-param</x:ref> = token BWS "=" BWS ( token / quoted-string )
1168<x:ref>auth-scheme</x:ref> = token
1169
1170<x:ref>b64token</x:ref> = 1*( ALPHA / DIGIT / "-" / "." / "_" / "~" / "+" / "/" )
1171 *"="
1172
1173<x:ref>challenge</x:ref> = auth-scheme [ 1*SP ( b64token / [ ( "," / auth-param ) *(
1174 OWS "," [ OWS auth-param ] ) ] ) ]
1175<x:ref>credentials</x:ref> = auth-scheme [ 1*SP ( b64token / [ ( "," / auth-param )
1176 *( OWS "," [ OWS auth-param ] ) ] ) ]
1177
1178<x:ref>quoted-string</x:ref> = &lt;quoted-string, defined in [Part1], Section 3.2.4&gt;
1179
1180<x:ref>token</x:ref> = &lt;token, defined in [Part1], Section 3.2.4&gt;
1181</artwork>
1182</figure>
1183</section>
1184<?ENDINC p7-auth.abnf-appendix ?>
1185
1186<section title="Change Log (to be removed by RFC Editor before publication)"  anchor="change.log">
1187<t>
1188  Changes up to the first Working Group Last Call draft are summarized
1189  in <eref target="http://trac.tools.ietf.org/html/draft-ietf-httpbis-p7-auth-19#appendix-C"/>.
1190</t>
1191
1192<section title="Since draft-ietf-httpbis-p7-auth-19" anchor="changes.since.19">
1193<t>
1194  Closed issues:
1195  <list style="symbols">
1196    <t>
1197      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/348"/>:
1198      "Realms and scope"
1199    </t>
1200    <t>
1201      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/349"/>:
1202      "Strength"
1203    </t>
1204    <t>
1205      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/357"/>:
1206      "Authentication exchanges"
1207    </t>
1208    <t>
1209      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/361"/>:
1210      "ABNF requirements for recipients"
1211    </t>
1212    <t>
1213      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/368"/>:
1214      "note introduction of new IANA registries as normative changes"
1215    </t>
1216  </list>
1217</t>
1218</section>
1219
1220</section>
1221
1222</back>
1223</rfc>
Note: See TracBrowser for help on using the repository browser.