Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Internet Engineering Task Force (IETF) B. Dover
- Request for Comments: 8969
- Category: Standards Track April 2020
- ISSN: 2071-1769
- An HTTP Status Code to Indicate Request Noncomformity While Still
- Making Best-Effort Response
- Abstract
- This document specifies a Hypertext Transfer Protocol (HTTP) status
- code for use when resource was accessed in a nonconforming manner
- but the request will be handled anyway.
- Status of This Memo
- This is an Internet Standards Track document.
- This document is a product of the Internet Engineering Task Force
- (IETF). It represents the consensus of the IETF community. It has
- received public review and has been approved for publication by the
- Internet Engineering Steering Group (IESG). Further information on
- Internet Standards is available in Section 2 of RFC 5741.
- Information about the current status of this document, any errata,
- and how to provide feedback on it may be obtained at
- http://www.rfc-editor.org/info/rfc8969.
- Copyright Notice
- Copyright (c) 2020 IETF Trust and the persons identified as the
- document authors. All rights reserved.
- This document is subject to BCP 78 and the IETF Trust's Legal
- Provisions Relating to IETF Documents
- (http://trustee.ietf.org/license-info) in effect on the date of
- publication of this document. Please review these documents
- carefully, as they describe your rights and restrictions with respect
- to this document. Code Components extracted from this document must
- include Simplified BSD License text as described in Section 4.e of
- the Trust Legal Provisions and are provided without warranty as
- described in the Simplified BSD License.
- Dover Standards Track [Page 1]
- RFC 8969 HTTP-status-397 April 2020
- Table of Contents
- 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2
- 2. Requirements . . . . . . . . . . . . . . . . . . . . . . . . 2
- 3. 397 Tolerating . . . . . . . . . . . . . . . . . . . . . . . 2
- 4. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 3
- 5. References . . . . . . . . . . . . . . . . . . . . . . . . . 4
- Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . 5
- Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 5
- 1. Introduction
- This document specifies a Hypertext Transfer Protocol (HTTP) status
- code for use when a server operator has received a request that
- violates standards for making such a request, but which the server
- will respond to under best-faith interpretation of client intent.
- This status code can be used to alert clients of their standards
- breakage and the potential that future requests of this type might
- not be handled as desired by this or other internet servers in the
- future.
- [RFC761] Section 2.10 discusses the Robustness Principle under which
- one should be liberal in what one accepts; in keeping with that
- principle, servers should make a best effort to handle non-conforming
- requests; this status code additionally provides a way to communicate
- to the client that it is doing so, and how to avoid potential breakage
- in the future.
- 2. Requirements
- The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
- "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
- document are to be interpreted as described in [RFC2119].
- 3. 397 Tolerating
- This status code indicates that the server has found a standards
- violation in the client request, but will respond in good faith
- anyway to the most likely intended conforming request.
- Responses using this status code SHOULD include an explanation, in
- the header, of the details of the standards breakage; what the
- client sent, versus what the client should have sent. For example:
- Dover Standards Track [Page 2]
- RFC 8969 HTTP-status-397 April 2020
- HTTP/1.1 397 Tolerating
- Link: <https://www.example.org/news>;
- Content-Type: text/html
- Request-Nonconformity: This request used the HTTP header "Referrer",
- which is most likely intended to be the standard HTTP header
- "Referer"; request will be handled on this assumption, and the
- client is advised to update code to "Referer" for future requests.
- Request-Nonconformant-Part: Referrer: http://search.example.com
- Request-Interpreted-As: Referer: http://search.example.com
- Tolerated-Until: Fri, 30 Apr 2020 06:05:18 GMT
- The use of the 397 status code does not imply an obligation to
- tolerate the nonconformity in the future. Servers MAY specify the
- tolerance's ending time with the Tolerated-Until response header.
- Clients SHOULD monitor their server logs for computer-initiated API
- requests in order to detect 397 responses and appropriately update
- their software in order to conform with relevant RFCs.
- A 397 response MUST be followed by another HTTP response, similar
- to other 300-series HTTP status codes, where such response makes
- the best guess at what the client intended; in the example above, that
- would be the response the client would have received from "Referer".
- 4. IANA Considerations
- The HTTP Status Codes Registry has been updated with the following
- entry:
- o Code: 397
- o Description: Tolerating
- o Specification: RFC 8969
- The Standard Header Registry has been updated with the following
- entries:
- 4.1. Request-Nonconformity
- o Header Name: Request-Nonconformity
- o Description: Human-readable explanation about what is wrong
- with the request.
- o Reference: RFC 8969
- Dover Standards Track [Page 3]
- RFC 8969 HTTP-status-397 April 2020
- 4.2. Request-Nonconformant-Part
- o Header Name: Request-Nonconformant-Part
- o Description: Repeats back the part of the request that is non-
- conforming.
- o Reference: RFC 8969
- 4.3. Request-Interpreted-As
- o Header Name: Request-Interpreted-As
- o Description: The corrected version of the non-conformant part
- that the server will interpret the request as.
- o Reference: RFC 8969
- 4.4. Tolerated-Until
- o Header Name: Tolerated-Until
- o Description: The date and time, formatted per [RFC7231], after
- which the server will stop thusly correcting this request error.
- o Reference: RFC 8969
- 6. References
- 6.1. Normative References
- [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
- Requirement Levels", BCP 14, RFC 2119,
- DOI 10.17487/RFC2119, March 1997,
- <http://www.rfc-editor.org/info/rfc2119>.
- [RFC7231] Fielding, R., Ed., and J. Reschke, Ed., "Hypertext
- Transfer Protocol (HTTP/1.1): Semantics and Content",
- RFC 7231, DOI 10.17487/RFC7231, June 2014,
- <https://www.rfc-editor.org/info/rfc7231>.
- 6.2. Informative References
- [RFC761] Postel, J., "DoD standard Transmission Control Protocol",
- RFC 761, DOI 10.17487/RFC0761, January 1980,
- <https://www.rfc-editor.org/info/rfc761>.
- Dover Standards Track [Page 4]
- RFC 8969 HTTP-status-397 April 2020
- [RFC1122] Braden, R., Ed., "Requirements for Internet Hosts -
- Communication Layers", STD 3, RFC 1122, DOI 10.17487/
- RFC1122, October 1989,
- <https://www.rfc-editor.org/info/rfc1122>.
- Acknowledgements
- Thanks to the field of numerology for providing 97 as the number
- for tolerance.
- Author's Address
- Ben Dover
- Email: benjamin.jeremiah.dover@gmail.com
- Dover Standards Track [Page 5]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement