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