draft-ietf-httpbis-proxy-status-00.txt   draft-ietf-httpbis-proxy-status-01.txt 
HTTP M. Nottingham HTTP M. Nottingham
Internet-Draft Fastly Internet-Draft Fastly
Intended status: Standards Track P. Sikora Intended status: Standards Track P. Sikora
Expires: November 3, 2019 Google Expires: September 2, 2020 Google
May 2, 2019 March 1, 2020
The Proxy-Status HTTP Header Field The Proxy-Status HTTP Response Header Field
draft-ietf-httpbis-proxy-status-00 draft-ietf-httpbis-proxy-status-01
Abstract Abstract
This document defines the Proxy-Status HTTP header field to convey This document defines the Proxy-Status HTTP header field to convey
the details of errors generated by HTTP intermediaries. the details of intermediary handling of responses, including
generated errors.
Note to Readers Note to Readers
_RFC EDITOR: please remove this section before publication_ _RFC EDITOR: please remove this section before publication_
Discussion of this draft takes place on the HTTP working group Discussion of this draft takes place on the HTTP working group
mailing list (ietf-http-wg@w3.org), which is archived at mailing list (ietf-http-wg@w3.org), which is archived at
https://lists.w3.org/Archives/Public/ietf-http-wg/ [1]. https://lists.w3.org/Archives/Public/ietf-http-wg/ [1].
Working Group information can be found at https://httpwg.org/ [2]; Working Group information can be found at https://httpwg.org/ [2];
skipping to change at page 1, line 44 skipping to change at page 1, line 45
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at https://datatracker.ietf.org/drafts/current/. Drafts is at https://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
This Internet-Draft will expire on November 3, 2019. This Internet-Draft will expire on September 2, 2020.
Copyright Notice Copyright Notice
Copyright (c) 2019 IETF Trust and the persons identified as the Copyright (c) 2020 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(https://trustee.ietf.org/license-info) in effect on the date of (https://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License. described in the Simplified BSD License.
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3
1.1. Notational Conventions . . . . . . . . . . . . . . . . . 3 1.1. Notational Conventions . . . . . . . . . . . . . . . . . 4
2. The Proxy-Status HTTP Header Field . . . . . . . . . . . . . 4 2. The Proxy-Status HTTP Header Field . . . . . . . . . . . . . 4
2.1. Generic Proxy Status Parameters . . . . . . . . . . . . . 5 2.1. Proxy-Status Parameters . . . . . . . . . . . . . . . . . 5
3. Proxy Status Types . . . . . . . . . . . . . . . . . . . . . 6 2.1.1. origin . . . . . . . . . . . . . . . . . . . . . . . 5
3.1. DNS Timeout . . . . . . . . . . . . . . . . . . . . . . . 6 2.1.2. fwd-protocol . . . . . . . . . . . . . . . . . . . . 6
3.2. DNS Error . . . . . . . . . . . . . . . . . . . . . . . . 6 2.1.3. error . . . . . . . . . . . . . . . . . . . . . . . . 6
3.3. Destination Not Found . . . . . . . . . . . . . . . . . . 6 2.1.4. details . . . . . . . . . . . . . . . . . . . . . . . 7
3.4. Destination Unavailable . . . . . . . . . . . . . . . . . 7 2.2. Proxy Error Types . . . . . . . . . . . . . . . . . . . . 7
3.5. Destination IP Prohibited . . . . . . . . . . . . . . . . 7 2.2.1. DNS Timeout . . . . . . . . . . . . . . . . . . . . . 7
3.6. Destination IP Unroutable . . . . . . . . . . . . . . . . 7 2.2.2. DNS Error . . . . . . . . . . . . . . . . . . . . . . 7
3.7. Connection Refused . . . . . . . . . . . . . . . . . . . 7 2.2.3. Destination Not Found . . . . . . . . . . . . . . . . 7
3.8. Connection Terminated . . . . . . . . . . . . . . . . . . 8 2.2.4. Destination Unavailable . . . . . . . . . . . . . . . 8
3.9. Connection Timeout . . . . . . . . . . . . . . . . . . . 8 2.2.5. Destination IP Prohibited . . . . . . . . . . . . . . 8
3.10. Connection Read Timeout . . . . . . . . . . . . . . . . . 8 2.2.6. Destination IP Unroutable . . . . . . . . . . . . . . 8
3.11. Connection Write Timeout . . . . . . . . . . . . . . . . 8 2.2.7. Connection Refused . . . . . . . . . . . . . . . . . 8
3.12. Connection Limit Reached . . . . . . . . . . . . . . . . 9 2.2.8. Connection Terminated . . . . . . . . . . . . . . . . 9
3.13. HTTP Response Status . . . . . . . . . . . . . . . . . . 9 2.2.9. Connection Timeout . . . . . . . . . . . . . . . . . 9
3.14. HTTP Incomplete Response . . . . . . . . . . . . . . . . 9 2.2.10. Connection Read Timeout . . . . . . . . . . . . . . . 9
3.15. HTTP Protocol Error . . . . . . . . . . . . . . . . . . . 9 2.2.11. Connection Write Timeout . . . . . . . . . . . . . . 9
3.16. HTTP Response Header Block Too Large . . . . . . . . . . 10 2.2.12. Connection Limit Reached . . . . . . . . . . . . . . 10
3.17. HTTP Response Header Too Large . . . . . . . . . . . . . 10 2.2.13. HTTP Incomplete Response . . . . . . . . . . . . . . 10
3.18. HTTP Response Body Too Large . . . . . . . . . . . . . . 10 2.2.14. HTTP Protocol Error . . . . . . . . . . . . . . . . . 10
3.19. HTTP Response Transfer-Coding Error . . . . . . . . . . . 11 2.2.15. HTTP Response Header Block Too Large . . . . . . . . 10
3.20. HTTP Response Content-Coding Error . . . . . . . . . . . 11 2.2.16. HTTP Response Header Too Large . . . . . . . . . . . 11
3.21. HTTP Response Timeout . . . . . . . . . . . . . . . . . . 11 2.2.17. HTTP Response Body Too Large . . . . . . . . . . . . 11
3.22. TLS Handshake Error . . . . . . . . . . . . . . . . . . . 12 2.2.18. HTTP Response Transfer-Coding Error . . . . . . . . . 11
3.23. TLS Untrusted Peer Certificate . . . . . . . . . . . . . 12 2.2.19. HTTP Response Content-Coding Error . . . . . . . . . 12
3.24. TLS Expired Peer Certificate . . . . . . . . . . . . . . 12 2.2.20. HTTP Response Timeout . . . . . . . . . . . . . . . . 12
3.25. TLS Unexpected Peer Certificate . . . . . . . . . . . . . 12 2.2.21. TLS Handshake Error . . . . . . . . . . . . . . . . . 12
3.26. TLS Unexpected Peer Identity . . . . . . . . . . . . . . 13 2.2.22. TLS Untrusted Peer Certificate . . . . . . . . . . . 12
3.27. TLS Missing Proxy Certificate . . . . . . . . . . . . . . 13 2.2.23. TLS Expired Peer Certificate . . . . . . . . . . . . 13
3.28. TLS Rejected Proxy Certificate . . . . . . . . . . . . . 13 2.2.24. TLS Unexpected Peer Certificate . . . . . . . . . . . 13
3.29. TLS Error . . . . . . . . . . . . . . . . . . . . . . . . 13 2.2.25. TLS Missing Proxy Certificate . . . . . . . . . . . . 13
3.30. HTTP Request Error . . . . . . . . . . . . . . . . . . . 14 2.2.26. TLS Rejected Proxy Certificate . . . . . . . . . . . 14
3.31. HTTP Request Denied . . . . . . . . . . . . . . . . . . . 14 2.2.27. TLS Error . . . . . . . . . . . . . . . . . . . . . . 14
3.32. HTTP Upgrade Failed . . . . . . . . . . . . . . . . . . . 14 2.2.28. HTTP Request Error . . . . . . . . . . . . . . . . . 14
3.33. Proxy Internal Error . . . . . . . . . . . . . . . . . . 14 2.2.29. HTTP Request Denied . . . . . . . . . . . . . . . . . 15
3.34. Proxy Loop Detected . . . . . . . . . . . . . . . . . . . 15 2.2.30. HTTP Upgrade Failed . . . . . . . . . . . . . . . . . 15
4. Defining New Proxy Status Types . . . . . . . . . . . . . . . 15 2.2.31. Proxy Internal Response . . . . . . . . . . . . . . . 15
5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 16 2.2.32. Proxy Internal Error . . . . . . . . . . . . . . . . 15
6. Security Considerations . . . . . . . . . . . . . . . . . . . 16 2.2.33. Proxy Loop Detected . . . . . . . . . . . . . . . . . 16
7. References . . . . . . . . . . . . . . . . . . . . . . . . . 16 2.3. Defining New Proxy Error Types . . . . . . . . . . . . . 16
7.1. Normative References . . . . . . . . . . . . . . . . . . 16 3. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 17
7.2. Informative References . . . . . . . . . . . . . . . . . 17 4. Security Considerations . . . . . . . . . . . . . . . . . . . 17
7.3. URIs . . . . . . . . . . . . . . . . . . . . . . . . . . 17 5. References . . . . . . . . . . . . . . . . . . . . . . . . . 17
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 17 5.1. Normative References . . . . . . . . . . . . . . . . . . 17
5.2. Informative References . . . . . . . . . . . . . . . . . 18
5.3. URIs . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 18
1. Introduction 1. Introduction
HTTP intermediaries - including both forward proxies and gateways HTTP intermediaries - including both forward proxies and gateways
(also known as "reverse proxies") - have become an increasingly (also known as "reverse proxies") - have become an increasingly
significant part of HTTP deployments. In particular, reverse proxies significant part of HTTP deployments. In particular, reverse proxies
and Content Delivery Networks (CDNs) form part of the critical and Content Delivery Networks (CDNs) form part of the critical
infrastructure of many Web sites. infrastructure of many Web sites.
Typically, HTTP intermediaries forward requests towards the origin Typically, HTTP intermediaries forward requests towards the origin
server and then forward their responses back to clients. However, if server and then forward their responses back to clients. However, if
an error occurs, the response is generated by the intermediary an error occurs, the response is generated by the intermediary
itself. itself.
HTTP accommodates these types of errors with a few status codes; for HTTP accommodates these types of errors with a few status codes; for
example, 502 Bad Gateway and 504 Gateway Timeout. However, example, 502 Bad Gateway and 504 Gateway Timeout. However,
experience has shown that more information is necessary to aid experience has shown that more information is necessary to aid
debugging and communicate what's happened to the client. debugging and communicate what's happened to the client.
To address this, Section 2 defines a new HTTP response header field Additionally, intermediaries sometimes want to convey additional
to convey such information, using the Proxy Status Types defined in information about their handling of a response, even if they did not
Section 3. Section 4 explains how to define new Proxy Status Types. generate it.
To enable these uses, Section 2 defines a new HTTP response header
field to allow intermediaries to convey details of their handling of
a response, and Section 2.2 defines a set of Proxy Error Types for
use when a proxy generates the response. Section 2.3 explains how to
define new Proxy Error Types.
1.1. Notational Conventions 1.1. Notational Conventions
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
"OPTIONAL" in this document are to be interpreted as described in BCP "OPTIONAL" in this document are to be interpreted as described in BCP
14 [RFC2119] [RFC8174] when, and only when, they appear in all 14 [RFC2119] [RFC8174] when, and only when, they appear in all
capitals, as shown here. capitals, as shown here.
This specification uses Structured Headers This specification uses Structured Headers
skipping to change at page 4, line 18 skipping to change at page 4, line 26
structured types defined therein. structured types defined therein.
Note that in this specification, "proxy" is used to indicate both Note that in this specification, "proxy" is used to indicate both
forward and reverse proxies, otherwise known as gateways. "Next hop" forward and reverse proxies, otherwise known as gateways. "Next hop"
indicates the connection in the direction leading to the origin indicates the connection in the direction leading to the origin
server for the request. server for the request.
2. The Proxy-Status HTTP Header Field 2. The Proxy-Status HTTP Header Field
The Proxy-Status HTTP response header field allows an intermediary to The Proxy-Status HTTP response header field allows an intermediary to
indicate the nature and details of an error condition it encounters convey additional information about its handling of a response and
when servicing a request. its associated request.
It is a Structured Headers [I-D.ietf-httpbis-header-structure] It is a Structured Headers [I-D.ietf-httpbis-header-structure] List
Parameterised List, where each item in the list indicates an error of parameterised Tokens:
condition. Typically, it will have only one param-item (the error
condition that triggered generation of the response it occurs
within), but more than one value is not prohibited.
Each param-item's primary-id is a Proxy Status Type, a registered Cache-Status = sh-list
value that indicates the nature of the error.
Each param-item can have zero to many parameters. Section 2.1 lists Each member of the list represents an intermediary that has handled
parameters that can be used with all Proxy Status Types; individual the response. The first member of the list represents the
types can define additional parameters to use with them. All intermediary closest to the origin server, and the last member of the
parameters are optional; see Section 6 for their potential security list represents the intermediary closest to the user agent.
impact.
For example: For example:
HTTP/1.1 504 Gateway Timeout Proxy-Status: FooProxy, ExampleCDN
Proxy-Status: connection_timeout; proxy=SomeCDN; origin=abc; tries=3
indicates the specific nature of the timeout as a connect timeout to indicates that this response was handled first by FooAccelerator and
the origin with the identifier "abc", and that is was generated by then ExampleCDN.
the intermediary that identifies itself as "FooCDN." Furthermore,
three connection attempts were made.
Or: Parameters on each member convey additional information about that
intermediary's handling of the response; see Section 2.1 for defined
parameters.
HTTP/1.1 429 Too Many Requests Intermediaries determine when it is appropriate to add the Proxy-
Proxy-Status: http_request_error; proxy=SomeReverseProxy Status header field to a response. Some might decide to add it to
all responses, whereas others might only do so when specifically
configured to, or when the request contains a header that activates a
debugging mode.
indicates that this 429 Too Many Requests response was generated by When adding a value to the Proxy-Status header field, intermediaries
the intermediary, not the origin. SHOULD preserve the existing contents of the header, to allow
debugging of the entire chain of intermediaries handling the request.
Each Proxy Status Type has a Recommended HTTP Status Code. When The list members identify the intermediary that inserted the value,
generating a HTTP response containing Proxy-Status, its HTTP status and MUST have a type of either sh-string or sh-token. Depending on
code SHOULD be set to the Recommended HTTP Status Code. However, the deployment, this might be a product or service name (e.g.,
there may be circumstances (e.g., for backwards compatibility with ExampleProxy or "Example CDN"), a hostname ("proxy-3.example.com"),
previous behaviours) when another status code might be used. and IP address, or a generated string.
Section 3 lists the Proxy Status Types defined in this document; new Each member of the list can also have a number of parameters that
ones can be defined using the procedure outlined in Section 4. describe that intermediary's handling of the request. While all of
these parameters are OPTIONAL, intermediaries are encouraged to
provide as much information as possible.
Proxy-Status MAY be sent in HTTP trailers, but - as with all trailers Proxy-Status MAY be sent in HTTP trailers, but - as with all trailers
- it might be silently discarded along the path to the user agent, - it might be silently discarded along the path to the user agent, so
this SHOULD NOT be done unless it is not possible to send it in this SHOULD NOT be done unless it is not possible to send it in
headers. For example, if an intermediary is streaming a response and headers. For example, if an intermediary is streaming a response and
the upstream connection suddenly terminates, Proxy-Status can be the upstream connection suddenly terminates, Proxy-Status can be
appended to the trailers of the outgoing message (since the headers appended to the trailers of the outgoing message (since the headers
have already been sent). have already been sent).
Note that there are various security considerations for Note that there are various security considerations for
intermediaries using the Proxy-Status header field; see Section 6. intermediaries using the Proxy-Status header field; see Section 4.
Origin servers MUST NOT generate the Proxy-Status header field. Origin servers MUST NOT generate the Proxy-Status header field.
2.1. Generic Proxy Status Parameters 2.1. Proxy-Status Parameters
This section lists parameters that are potentially applicable to most This section lists parameters that can be used on the members of
Proxy Status Types. Proxy-Status.
o proxy - a sh-token identifying the HTTP intermediary generating 2.1.1. origin
this response.
o origin - a sh-token identifying the origin server whose behaviour The "origin" parameter's value is a sh-string or sh-token that
triggered this response. identifies the origin server selected (and used, if contacted) for
this response. Its contents might be a hostname, IP address, or
alias.
o protocol - a sh-token indicating the ALPN protocol identifier This is most useful for gateways (also known as "reverse proxies"),
[RFC7301] used to connect to the next hop. This is only since they are often configured to use an origin server other than
applicable when that connection was actually established. that which appears in the URL, and sometimes they use several origins
to serve a given site.
o tries - a sh-integer indicating the number of times that the error For example:
has occurred before this response.
o details - a sh-string containing additional information not Proxy-Status: cdn.example.org; origin=backend.example.org
captured anywhere else. This can include implementation-specific
or deployment-specific information.
3. Proxy Status Types 2.1.2. fwd-protocol
This section lists the Proxy Status Types defined by this document. The "fwd-protocol" parameter's value is a sh-token indicating the
See Section 4 for information about defining new Proxy Status Types. ALPN protocol identifier [RFC7301] used by the intermediary to
connect to the next hop. This is only applicable when that
connection was actually established.
3.1. DNS Timeout For example:
Proxy-Status: "proxy.example.org"; fwd-protocol=h2
2.1.3. error
The "error" parameter's value is a sh-token that is a Proxy Error
Type. When present, it indicates that the response was generated by
the proxy, not the origin server or any other upstream server.
Section 2.2 lists the Proxy Error Types defined in this document; new
ones can be defined using the procedure outlined in Section 2.3.
For example:
HTTP/1.1 504 Gateway Timeout
Proxy-Status: SomeCDN; error=connection_timeout
indicates that this 504 response was generated by SomeCDN, due to a
connection timeout when going forward.
Or:
HTTP/1.1 429 Too Many Requests
Proxy-Status: SomeReverseProxy; error=http_request_error
indicates that this 429 Too Many Requests response was generated by
the intermediary, not the origin.
Each Proxy Error Type has a Recommended HTTP Status Code. When
generating a HTTP response containing "error", its HTTP status code
SHOULD be set to the Recommended HTTP Status Code. However, there
may be circumstances (e.g., for backwards compatibility with previous
behaviours) when another status code might be used.
2.1.4. details
The "details" parameter's value is a sh-string containing additional
information not captured anywhere else. This can include
implementation-specific or deployment-specific information.
For example:
Proxy-Status: ExampleProxy; error="http_protocol_error";
details="Malformed response header - space before colon"
2.2. Proxy Error Types
This section lists the Proxy Error Types defined by this document.
See Section 2.3 for information about defining new Proxy Error Types.
2.2.1. DNS Timeout
o Name: dns_timeout o Name: dns_timeout
o Description: The intermediary encountered a timeout when trying to o Description: The intermediary encountered a timeout when trying to
find an IP address for the destination hostname. find an IP address for the next hop hostname.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 504 o Recommended HTTP status code: 504
3.2. DNS Error 2.2.2. DNS Error
o Name: dns_error o Name: dns_error
o Description: The intermediary encountered a DNS error when trying o Description: The intermediary encountered a DNS error when trying
to find an IP address for the destination hostname. to find an IP address for the next hop hostname.
o Extra Parameters: o Extra Parameters:
* rcode: A sh-string conveying the DNS RCODE that indicates the * rcode: A sh-string conveying the DNS RCODE that indicates the
error type. See [RFC8499], Section 3. error type. See [RFC8499], Section 3.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.3. Destination Not Found 2.2.3. Destination Not Found
o Name: destination_not_found o Name: destination_not_found
o Description: The intermediary cannot determine the appropriate o Description: The intermediary cannot determine the appropriate
destination to use for this request; for example, it may not be next hop to use for this request; for example, it may not be
configured. Note that this error is specific to gateways, which configured. Note that this error is specific to gateways, which
typically require specific configuration to identify the "backend" typically require specific configuration to identify the "backend"
server; forward proxies use in-band information to identify the server; forward proxies use in-band information to identify the
origin server. origin server.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 500 o Recommended HTTP status code: 500
3.4. Destination Unavailable 2.2.4. Destination Unavailable
o Name: destination_unavailable o Name: destination_unavailable
o Description: The intermediary considers the next hop to be o Description: The intermediary considers the next hop to be
unavailable; e.g., recent attempts to communicate with it may have unavailable; e.g., recent attempts to communicate with it may have
failed, or a health check may indicate that it is down. failed, or a health check may indicate that it is down.
o Extra Parameters: o Extra Parameters: None.
o Recommended HTTP status code: 503 o Recommended HTTP status code: 503
3.5. Destination IP Prohibited 2.2.5. Destination IP Prohibited
o Name: destination_ip_prohibited o Name: destination_ip_prohibited
o Description: The intermediary is configured to prohibit o Description: The intermediary is configured to prohibit
connections to the destination IP address. connections to the next hop IP address.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.6. Destination IP Unroutable 2.2.6. Destination IP Unroutable
o Name: destination_ip_unroutable o Name: destination_ip_unroutable
o Description: The intermediary cannot find a route to the o Description: The intermediary cannot find a route to the next hop
destination IP address. IP address.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.7. Connection Refused 2.2.7. Connection Refused
o Name: connection_refused o Name: connection_refused
o Description: The intermediary's connection to the next hop was o Description: The intermediary's connection to the next hop was
refused. refused.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.8. Connection Terminated 2.2.8. Connection Terminated
o Name: connection_terminated o Name: connection_terminated
o Description: The intermediary's connection to the next hop was o Description: The intermediary's connection to the next hop was
closed before any part of the response was received. If some part closed before any part of the response was received. If some part
was received, see http_response_incomplete. was received, see http_response_incomplete.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.9. Connection Timeout 2.2.9. Connection Timeout
o Name: connection_timeout o Name: connection_timeout
o Description: The intermediary's attempt to open a connection to o Description: The intermediary's attempt to open a connection to
the next hop timed out. the next hop timed out.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 504 o Recommended HTTP status code: 504
3.10. Connection Read Timeout 2.2.10. Connection Read Timeout
o Name: connection_read_timeout o Name: connection_read_timeout
o Description: The intermediary was expecting data on a connection o Description: The intermediary was expecting data on a connection
(e.g., part of a response), but did not receive any new data in a (e.g., part of a response), but did not receive any new data in a
configured time limit. configured time limit.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 504 o Recommended HTTP status code: 504
3.11. Connection Write Timeout 2.2.11. Connection Write Timeout
o Name: connection_write_timeout o Name: connection_write_timeout
o Description: The intermediary was attempting to write data to a o Description: The intermediary was attempting to write data to a
connection, but was not able to (e.g., because its buffers were connection, but was not able to (e.g., because its buffers were
full). full).
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 504 o Recommended HTTP status code: 504
3.12. Connection Limit Reached 2.2.12. Connection Limit Reached
o Name: connnection_limit_reached o Name: connnection_limit_reached
o Description: The intermediary is configured to limit the number of o Description: The intermediary is configured to limit the number of
connections it has to the next hop, and that limit has been connections it has to the next hop, and that limit has been
passed. passed.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: o Recommended HTTP status code: 503
3.13. HTTP Response Status
o Name: http_response_status
o Description: The intermediary has received a 4xx or 5xx status
code from the next hop and forwarded it to the client.
o Extra Parameters: None.
o Recommended HTTP status code:
3.14. HTTP Incomplete Response 2.2.13. HTTP Incomplete Response
o Name: http_response_incomplete o Name: http_response_incomplete
o Description: The intermediary received an incomplete response to o Description: The intermediary received an incomplete response to
the request from the next hop. the request from the next hop.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.15. HTTP Protocol Error 2.2.14. HTTP Protocol Error
o Name: http_protocol_error o Name: http_protocol_error
o Description: The intermediary encountered a HTTP protocol error o Description: The intermediary encountered a HTTP protocol error
when communicating with the next hop. This error should only be when communicating with the next hop. This error should only be
used when a more specific one is not defined. used when a more specific one is not defined.
o Extra Parameters: o Extra Parameters: None.
* details: a sh-string containing details about the error
condition. For example, this might be the HTTP/2 error code or
free-form text describing the condition.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.16. HTTP Response Header Block Too Large 2.2.15. HTTP Response Header Block Too Large
o Name: http_response_header_block_size o Name: http_response_header_block_size
o Description: The intermediary received a response to the request o Description: The intermediary received a response to the request
whose header block was considered too large. whose header block was considered too large.
o Extra Parameters: o Extra Parameters:
* header_block_size: a sh-integer indicating how large the * header_block_size: a sh-integer indicating how large the
headers received were. Note that they might not be complete; headers received were. Note that they might not be complete;
i.e., the intermediary may have discarded or refused additional i.e., the intermediary may have discarded or refused additional
data. data.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.17. HTTP Response Header Too Large 2.2.16. HTTP Response Header Too Large
o Name: http_response_header_size o Name: http_response_header_size
o Description: The intermediary received a response to the request o Description: The intermediary received a response to the request
containing an individual header line that was considered too containing an individual header line that was considered too
large. large.
o Extra Parameters: o Extra Parameters:
* header_name: a sh-string indicating the name of the header that * header_name: a sh-string indicating the name of the header that
triggered the error. triggered the error.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.18. HTTP Response Body Too Large 2.2.17. HTTP Response Body Too Large
o Name: http_response_body_size o Name: http_response_body_size
o Description: The intermediary received a response to the request o Description: The intermediary received a response to the request
whose body was considered too large. whose body was considered too large.
o Extra Parameters: o Extra Parameters:
* body_size: a sh-integer indicating how large the body received * body_size: a sh-integer indicating how large the body received
was. Note that it may not have been complete; i.e., the was. Note that it may not have been complete; i.e., the
intermediary may have discarded or refused additional data. intermediary may have discarded or refused additional data.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.19. HTTP Response Transfer-Coding Error 2.2.18. HTTP Response Transfer-Coding Error
o Name: http_response_transfer_coding o Name: http_response_transfer_coding
o Description: The intermediary encountered an error decoding the o Description: The intermediary encountered an error decoding the
transfer-coding of the response. transfer-coding of the response.
o Extra Parameters: o Extra Parameters:
* coding: a sh-token containing the specific coding that caused * coding: a sh-token containing the specific coding that caused
the error. the error.
* details: a sh-string containing details about the error
condition.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.20. HTTP Response Content-Coding Error 2.2.19. HTTP Response Content-Coding Error
o Name: http_response_content_coding o Name: http_response_content_coding
o Description: The intermediary encountered an error decoding the o Description: The intermediary encountered an error decoding the
content-coding of the response. content-coding of the response.
o Extra Parameters: o Extra Parameters:
* coding: a sh-token containing the specific coding that caused * coding: a sh-token containing the specific coding that caused
the error. the error.
* details: a sh-string containing details about the error
condition.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.21. HTTP Response Timeout 2.2.20. HTTP Response Timeout
o Name: http_response_timeout o Name: http_response_timeout
o Description: The intermediary reached a configured time limit o Description: The intermediary reached a configured time limit
waiting for the complete response. waiting for the complete response.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 504 o Recommended HTTP status code: 504
3.22. TLS Handshake Error 2.2.21. TLS Handshake Error
o Name: tls_handshake_error o Name: tls_handshake_error
o Description: The intermediary encountered an error during TLS o Description: The intermediary encountered an error during TLS
handshake with the next hop. handshake with the next hop.
o Extra Parameters: o Extra Parameters:
* alert_message: a sh-token containing the applicable description * alert_message: a sh-token containing the applicable description
string from the TLS Alerts registry. string from the TLS Alerts registry.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.23. TLS Untrusted Peer Certificate 2.2.22. TLS Untrusted Peer Certificate
o Name: tls_untrusted_peer_certificate o Name: tls_untrusted_peer_certificate
o Description: The intermediary received untrusted peer certificate o Description: The intermediary received an untrusted peer
during TLS handshake with the next hop. certificate during TLS handshake with the next hop.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.24. TLS Expired Peer Certificate 2.2.23. TLS Expired Peer Certificate
o Name: tls_expired_peer_certificate o Name: tls_expired_peer_certificate
o Description: The intermediary received expired peer certificate o Description: The intermediary received an expired peer certificate
during TLS handshake with the next hop. during TLS handshake with the next hop.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.25. TLS Unexpected Peer Certificate 2.2.24. TLS Unexpected Peer Certificate
o Name: tls_unexpected_peer_certificate o Name: tls_unexpected_peer_certificate
o Description: The intermediary received unexpected peer certificate o Description: The intermediary received an unexpected peer
(e.g., SPKI doesn't match) during TLS handshake with the next hop. certificate (e.g., SPKI doesn't match) during the TLS handshake
with the next hop.
o Extra Parameters: o Extra Parameters:
* details: a sh-string containing the checksum or SPKI of the * identity: a sh-string containing a comma-separated list of
certificate received from the next hop. Subject Alternative Names from the certificate received from
the next hop.
o Recommended HTTP status code: 502
3.26. TLS Unexpected Peer Identity
o Name: tls_unexpected_peer_identity
o Description: The intermediary received peer certificate with
unexpected identity (e.g., Subject Alternative Name doesn't match)
during TLS handshake with the next hop.
o Extra Parameters: * sha256: a sh-string containing the hex-encoded SHA-256 of the
certificate received from the next hop.
* details: a sh-string containing the identity of the next hop. * spki: a sh-string containing the base64-encoded SHA-256 of the
Subject Public Key Info (SPKI) from the certificate received
from the next hop.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.27. TLS Missing Proxy Certificate 2.2.25. TLS Missing Proxy Certificate
o Name: tls_missing_proxy_certificate o Name: tls_missing_proxy_certificate
o Description: The next hop requested client certificate from the o Description: The next hop requested a client certificate from the
intermediary during TLS handshake, but it wasn't configured with intermediary during TLS handshake, but it wasn't configured with
one. one.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 500 o Recommended HTTP status code: 500
3.28. TLS Rejected Proxy Certificate 2.2.26. TLS Rejected Proxy Certificate
o Name: tls_rejected_proxy_certificate o Name: tls_rejected_proxy_certificate
o Description: The next hop rejected client certificate provided by o Description: The next hop rejected the client certificate provided
the intermediary during TLS handshake. by the intermediary during TLS handshake.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 500 o Recommended HTTP status code: 500
3.29. TLS Error 2.2.27. TLS Error
o Name: tls_error o Name: tls_error
o Description: The intermediary encountered a TLS error when o Description: The intermediary encountered a TLS error when
communicating with the next hop. communicating with the next hop.
o Extra Parameters: o Extra Parameters:
* alert_message: a sh-token containing the applicable description * alert_message: a sh-token containing the applicable description
string from the TLS Alerts registry. string from the TLS Alerts registry.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.30. HTTP Request Error 2.2.28. HTTP Request Error
o Name: http_request_error o Name: http_request_error
o Description: The intermediary is generating a client (4xx) o Description: The intermediary is generating a client (4xx)
response on the origin's behalf. Applicable status codes include response on the origin's behalf. Applicable status codes include
(but are not limited to) 400, 403, 405, 406, 408, 411, 413, 414, (but are not limited to) 400, 403, 405, 406, 408, 411, 413, 414,
415, 416, 417, 429. This proxy status type helps distinguish 415, 416, 417, 429.
between responses generated by intermediaries from those generated
by the origin.
o Extra Parameters: None. o Extra Parameters:
* status_code: a sh-integer containing the generated status code.
* status_phrase: a sh-string containing the generated status
phrase.
o Recommended HTTP status code: The applicable 4xx status code o Recommended HTTP status code: The applicable 4xx status code
3.31. HTTP Request Denied This type helps distinguish between responses generated by
intermediaries from those generated by the origin.
2.2.29. HTTP Request Denied
o Name: http_request_denied o Name: http_request_denied
o Description: The intermediary rejected HTTP request based on its o Description: The intermediary rejected the HTTP request based on
configuration and/or policy settings. The request wasn't its configuration and/or policy settings. The request wasn't
forwarded to the next hop. forwarded to the next hop.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 400 o Recommended HTTP status code: 400
3.32. HTTP Upgrade Failed 2.2.30. HTTP Upgrade Failed
o Name: http_upgrade_failed o Name: http_upgrade_failed
o Description: The HTTP Upgrade between the intermediary and the o Description: The HTTP Upgrade between the intermediary and the
next hop failed. next hop failed.
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
3.33. Proxy Internal Error 2.2.31. Proxy Internal Response
o Name: proxy_internal_response
o Description: The intermediary generated the response locally,
without attempting to connect to the next hop (e.g. in response to
a request to a debug endpoint terminated at the intermediary).
o Extra Parameters: None.
o Recommended HTTP status code:
2.2.32. Proxy Internal Error
o Name: proxy_internal_error o Name: proxy_internal_error
o Description: The intermediary encountered an internal error o Description: The intermediary encountered an internal error
unrelated to the origin. unrelated to the origin.
o Extra Parameters: o Extra Parameters:
* details: a sh-string containing details about the error * error: a sh-string containing details about the error
condition. condition.
o Recommended HTTP status code: 500 o Recommended HTTP status code: 500
3.34. Proxy Loop Detected 2.2.33. Proxy Loop Detected
o Name: proxy_loop_detected o Name: proxy_loop_detected
o Description: The intermediary tried to forward the request to o Description: The intermediary tried to forward the request to
itself, or a loop has been detected using different means (e.g. itself, or a loop has been detected using different means (e.g.
[I-D.ietf-httpbis-cdn-loop]). [RFC8586]).
o Extra Parameters: None. o Extra Parameters: None.
o Recommended HTTP status code: 502 o Recommended HTTP status code: 502
4. Defining New Proxy Status Types 2.3. Defining New Proxy Error Types
New Proxy Status Types can be defined by registering them in the HTTP New Proxy Error Types can be defined by registering them in the HTTP
Proxy Status Types registry. Proxy Error Types registry.
Registration requests are reviewed and approved by a Designated Registration requests are reviewed and approved by a Designated
Expert, as per [RFC8126], Section 4.5. A specification document is Expert, as per [RFC8126], Section 4.5. A specification document is
appreciated, but not required. appreciated, but not required.
The Expert(s) should consider the following factors when evaluating The Expert(s) should consider the following factors when evaluating
requests: requests:
o Community feedback o Community feedback
o If the value is sufficiently well-defined o If the value is sufficiently well-defined
o If the value is generic; vendor-specific, application-specific and o If the value is generic; vendor-specific, application-specific and
deployment-specific values are discouraged deployment-specific values are discouraged
Registration requests should use the following template: Registration requests should use the following template:
o Name: [a name for the Proxy Status Type that is allowable as a sh- o Name: [a name for the Proxy Error Type that is matches sh-token]
param-list key]
o Description: [a description of the conditions that generate the o Description: [a description of the conditions that generate the
Proxy Status Types] Proxy Error Type]
o Extra Parameters: [zero or more optional parameters, typed using o Extra Parameters: [zero or more optional parameters, along with
one of the types available in sh-item] their allowable type(s)]
o Recommended HTTP status code: [the appropriate HTTP status code o Recommended HTTP status code: [the appropriate HTTP status code
for this entry] for this entry]
See the registry at https://iana.org/assignments/http-proxy-statuses See the registry at https://iana.org/assignments/http-proxy-statuses
[4] for details on where to send registration requests. [4] for details on where to send registration requests.
5. IANA Considerations 3. IANA Considerations
Upon publication, please create the HTTP Proxy Status Types registry Upon publication, please create the HTTP Proxy Error Types registry
at https://iana.org/assignments/http-proxy-statuses [5] and populate at https://iana.org/assignments/http-proxy-statuses [5] and populate
it with the types defined in Section 3; see Section 4 for its it with the types defined in Section 2.2; see Section 2.3 for its
associated procedures. associated procedures.
6. Security Considerations 4. Security Considerations
One of the primary security concerns when using Proxy-Status is One of the primary security concerns when using Proxy-Status is
leaking information that might aid an attacker. leaking information that might aid an attacker. For example,
information about the intermediary's configuration and back-end
topology can be exposed.
As a result, care needs to be taken when deciding to generate a As a result, care needs to be taken when deciding to generate a
Proxy-Status header. Note that intermediaries are not required to Proxy-Status header. Note that intermediaries are not required to
generate a Proxy-Status header field in any response, and can generate a Proxy-Status header field in any response, and can
conditionally generate them based upon request attributes (e.g., conditionally generate them based upon request attributes (e.g.,
authentication tokens, IP address). authentication tokens, IP address).
Likewise, generation of all parameters is optional. Likewise, generation of all parameters is optional.
Special care needs to be taken in generating proxy and origin 5. References
parameters, as they can expose information about the intermediary's
configuration and back-end topology.
7. References
7.1. Normative References 5.1. Normative References
[I-D.ietf-httpbis-header-structure] [I-D.ietf-httpbis-header-structure]
Nottingham, M. and P. Kamp, "Structured Headers for HTTP", Nottingham, M. and P. Kamp, "Structured Headers for HTTP",
draft-ietf-httpbis-header-structure-09 (work in progress), draft-ietf-httpbis-header-structure-13 (work in progress),
December 2018. August 2019.
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, Requirement Levels", BCP 14, RFC 2119,
DOI 10.17487/RFC2119, March 1997, DOI 10.17487/RFC2119, March 1997,
<https://www.rfc-editor.org/info/rfc2119>. <https://www.rfc-editor.org/info/rfc2119>.
[RFC7301] Friedl, S., Popov, A., Langley, A., and E. Stephan, [RFC7301] Friedl, S., Popov, A., Langley, A., and E. Stephan,
"Transport Layer Security (TLS) Application-Layer Protocol "Transport Layer Security (TLS) Application-Layer Protocol
Negotiation Extension", RFC 7301, DOI 10.17487/RFC7301, Negotiation Extension", RFC 7301, DOI 10.17487/RFC7301,
July 2014, <https://www.rfc-editor.org/info/rfc7301>. July 2014, <https://www.rfc-editor.org/info/rfc7301>.
skipping to change at page 17, line 23 skipping to change at page 18, line 13
<https://www.rfc-editor.org/info/rfc8126>. <https://www.rfc-editor.org/info/rfc8126>.
[RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
May 2017, <https://www.rfc-editor.org/info/rfc8174>. May 2017, <https://www.rfc-editor.org/info/rfc8174>.
[RFC8499] Hoffman, P., Sullivan, A., and K. Fujiwara, "DNS [RFC8499] Hoffman, P., Sullivan, A., and K. Fujiwara, "DNS
Terminology", BCP 219, RFC 8499, DOI 10.17487/RFC8499, Terminology", BCP 219, RFC 8499, DOI 10.17487/RFC8499,
January 2019, <https://www.rfc-editor.org/info/rfc8499>. January 2019, <https://www.rfc-editor.org/info/rfc8499>.
7.2. Informative References 5.2. Informative References
[I-D.ietf-httpbis-cdn-loop] [RFC8586] Ludin, S., Nottingham, M., and N. Sullivan, "Loop
Ludin, S., Nottingham, M., and N. Sullivan, "CDN Loop Detection in Content Delivery Networks (CDNs)", RFC 8586,
Detection", draft-ietf-httpbis-cdn-loop-02 (work in DOI 10.17487/RFC8586, April 2019,
progress), February 2019. <https://www.rfc-editor.org/info/rfc8586>.
7.3. URIs 5.3. URIs
[1] https://lists.w3.org/Archives/Public/ietf-http-wg/ [1] https://lists.w3.org/Archives/Public/ietf-http-wg/
[2] https://httpwg.org/ [2] https://httpwg.org/
[3] https://github.com/httpwg/http-extensions/labels/proxy-status [3] https://github.com/httpwg/http-extensions/labels/proxy-status
[4] https://iana.org/assignments/http-proxy-statuses [4] https://iana.org/assignments/http-proxy-statuses
[5] https://iana.org/assignments/http-proxy-statuses [5] https://iana.org/assignments/http-proxy-statuses
 End of changes. 102 change blocks. 
226 lines changed or deleted 278 lines changed or added

This html diff was produced by rfcdiff 1.47. The latest version is available from http://tools.ietf.org/tools/rfcdiff/