source: draft-ietf-httpbis/22/draft-ietf-httpbis-p7-auth-22.xml @ 2561

Last change on this file since 2561 was 2190, checked in by julian.reschke@…, 7 years ago

prepare -22 for release

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