HTTP Working Group T. Pauly
Internet-Draft Apple, Inc.
Intended status: Standards Track May 1, 2023
Expires: November 2, 2023
HTTP Proxy-Status Parameter for Next-Hop Aliases
draft-ietf-httpbis-alias-proxy-status-02
Abstract
This document defines an HTTP Proxy-Status Parameter that contains a
list of aliases and canonical names received over DNS when
establishing a connection to the next hop.
About This Document
This note is to be removed before publishing as an RFC.
Status information for this document may be found at
.
Discussion of this document takes place on the HTTP Working Group
mailing list (), which is archived at
. Working Group
information can be found at .
Source for this draft and an issue tracker can be found at
.
Status of This Memo
This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet-
Drafts is at https://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress."
This Internet-Draft will expire on November 2, 2023.
Pauly Expires November 2, 2023 [Page 1]
Internet-Draft DNS Aliases Proxy-Status May 2023
Copyright Notice
Copyright (c) 2023 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
(https://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.
Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1. Requirements . . . . . . . . . . . . . . . . . . . . . . 3
2. next-hop-aliases Parameter . . . . . . . . . . . . . . . . . 3
3. Implementation Considerations . . . . . . . . . . . . . . . . 4
4. Security Considerations . . . . . . . . . . . . . . . . . . . 4
5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 5
6. References . . . . . . . . . . . . . . . . . . . . . . . . . 5
6.1. Normative References . . . . . . . . . . . . . . . . . . 5
6.2. Informative References . . . . . . . . . . . . . . . . . 6
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 6
1. Introduction
The Proxy-Status HTTP response field [PROXY-STATUS] allows proxies to
convey information about how a proxied request was handled in HTTP
responses sent to clients. It defines a set of parameters that
provide information, such as the name of the next hop.
[PROXY-STATUS] defines a "next-hop" parameter, which can contain a
hostname, IP address, or alias of the next hop. This parameter can
contain only one such item, so it cannot be used to communicate a
chain of aliases encountered during DNS resolution when connecting to
the next hop.
Knowing the full chain of names that were used during DNS resolution
via CNAME records [DNS] is particularly useful for clients of forward
proxies, in which the client is requesting to connect to a specific
target hostname using the CONNECT method [HTTP] or UDP proxying
[CONNECT-UDP]. CNAME records can be used to "cloak" hosts that
perform tracking or malicious activity behind more innocuous
hostnames, and clients such as web browsers use the chain of DNS
Pauly Expires November 2, 2023 [Page 2]
Internet-Draft DNS Aliases Proxy-Status May 2023
names to influence behavior like cookie usage policies [COOKIES] or
blocking of malicious hosts.
This document allows clients to receive the CNAME chain of DNS names
for the next hop by including the list of names in a new "next-hop-
aliases" Proxy-Status parameter.
1.1. Requirements
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
"OPTIONAL" in this document are to be interpreted as described in
BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all
capitals, as shown here.
2. next-hop-aliases Parameter
The "next-hop-aliases" parameter's value is a String
[STRUCTURED-FIELDS] that contains one or more DNS names in a comma-
separated list. The items in the list include all alias names an
canonical names received in CNAME records [DNS] during the course of
resolving the next hop's hostname using DNS, not including the
original requested hostname itself. The names SHOULD appear in the
order in which they were received in DNS. If there are multiple
CNAME records in the chain, the first name in the "next-hop-aliases"
list would be the value in the CNAME record for the original
hostname, and the final name in the "next-hop-aliases" list would be
the name that ultimately resolved to one or more addresses.
The list of DNS names in "next-hop-aliases" use a comma (",") as a
separator between names. DNS names normally just contain
alphanumeric characters and hyphens ("-"), although they are allowed
to contain any character [RFC1035], Section 3.1, including a comma.
To prevent commas or other special characters in names leading to
incorrect parsing, any characters that appear in names in this list
that do not belong to the set of URI Unreserved Characters [RFC3986],
Section 2.3 MUST be percent-encoded as defined in [RFC3986],
Section 2.1.
For example, consider a proxy "proxy.example.net" that receives the
following records when performing DNS resolution for the next hop
"host.example.com":
host.example.com. CNAME tracker.example.com.
tracker.example.com. CNAME service1.example-cdn.com.
service1.example-cdn.com. AAAA 2001:db8::1
The proxy could include the following proxy status in its response:
Pauly Expires November 2, 2023 [Page 3]
Internet-Draft DNS Aliases Proxy-Status May 2023
Proxy-Status: proxy.example.net; next-hop=2001:db8::1;
next-hop-aliases="tracker.example.com,service1.example-cdn.com"
This indicates that proxy.example.net, which used the IP address
"2001:db8::1" as the next hop for this request, encountered the names
"tracker.example.com" and "service1.example-cdn.com" in the DNS
resolution chain. Note that while this example includes both the
"next-hop" and "next-hop-aliases" parameters, "next-hop-aliases" can
be included without including "next-hop".
The "next-hop-aliases" parameter only applies when DNS was used to
resolve the next hop's name, and does not apply in all situations.
Clients can use the information in this parameter to determine how to
use the connection established through the proxy, but need to
gracefully handle situations in which this parameter is not present.
The proxy MAY send the empty string ("") as the value of "next-hop-
aliases" to indicate that no CNAME records were encountered when
resolving the next hop's name.
3. Implementation Considerations
In order to include the "next-hop-aliases" parameter, a proxy needs
to have access to the chain of alias names and canonical names
received in CNAME records.
Implementations ought to note that the full chain of names might not
available in common DNS resolution APIs, such as "getaddrinfo".
"getaddrinfo" does have an option for "AI_CANONNAME", but this will
only return the last name in the chain (the canonical name), not the
alias names.
An implementation MAY include incomplete information in the "next-
hop-aliases" parameter to accommodate cases where it is unable to
include the full chain, such as only including the canonical name if
the implementation can only use "getaddrinfo" as described above.
4. Security Considerations
The "next-hop-aliases" parameter does not include any DNSSEC
information or imply that DNSSEC was used. The information included
in the parameter can only be trusted to be valid insofar as the
client trusts its proxy to provide accurate information. This
information is intended to be used as a hint, and SHOULD NOT be used
for making security decisions about the identity of a resource
accessed through the proxy.
Pauly Expires November 2, 2023 [Page 4]
Internet-Draft DNS Aliases Proxy-Status May 2023
5. IANA Considerations
This document registers the "next-hop-aliases" parameter in the "HTTP
Proxy-Status Parameters" registry <>.
Name: next-hop-aliases
Description: A string containing one or more DNS aliases or
canonical names used to establish a proxied connection to the next
hop.
Reference: This document
6. References
6.1. Normative References
[CONNECT-UDP]
Schinazi, D., "Proxying UDP in HTTP", RFC 9298,
DOI 10.17487/RFC9298, August 2022,
.
[DNS] Mockapetris, P., "Domain names - concepts and facilities",
STD 13, RFC 1034, DOI 10.17487/RFC1034, November 1987,
.
[HTTP] Fielding, R., Ed., Nottingham, M., Ed., and J. Reschke,
Ed., "HTTP Semantics", STD 97, RFC 9110,
DOI 10.17487/RFC9110, June 2022,
.
[PROXY-STATUS]
Nottingham, M. and P. Sikora, "The Proxy-Status HTTP
Response Header Field", RFC 9209, DOI 10.17487/RFC9209,
June 2022, .
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119,
DOI 10.17487/RFC2119, March 1997,
.
[RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform
Resource Identifier (URI): Generic Syntax", STD 66,
RFC 3986, DOI 10.17487/RFC3986, January 2005,
.
Pauly Expires November 2, 2023 [Page 5]
Internet-Draft DNS Aliases Proxy-Status May 2023
[RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
May 2017, .
[STRUCTURED-FIELDS]
Nottingham, M. and P-H. Kamp, "Structured Field Values for
HTTP", RFC 8941, DOI 10.17487/RFC8941, February 2021,
.
6.2. Informative References
[COOKIES] Barth, A., "HTTP State Management Mechanism", RFC 6265,
DOI 10.17487/RFC6265, April 2011,
.
[RFC1035] Mockapetris, P., "Domain names - implementation and
specification", STD 13, RFC 1035, DOI 10.17487/RFC1035,
November 1987, .
Author's Address
Tommy Pauly
Apple, Inc.
Email: tpauly@apple.com
Pauly Expires November 2, 2023 [Page 6]