Commit 0ba0ea17 authored by Brad Fitzpatrick's avatar Brad Fitzpatrick

net/http: document that Request.Host includes HTTP/2 :authority

Fixes #34640

Change-Id: I4a6c9414fe369cd5e9915472331c4bd8a21d8b0e
Reviewed-on: https://go-review.googlesource.com/c/go/+/198457Reviewed-by: default avatarFilippo Valsorda <filippo@golang.org>
parent ac2ceba0
......@@ -217,9 +217,11 @@ type Request struct {
// Transport.DisableKeepAlives were set.
Close bool
// For server requests, Host specifies the host on which the URL
// is sought. Per RFC 7230, section 5.4, this is either the value
// of the "Host" header or the host name given in the URL itself.
// For server requests, Host specifies the host on which the
// URL is sought. For HTTP/1 (per RFC 7230, section 5.4), this
// is either the value of the "Host" header or the host name
// given in the URL itself. For HTTP/2, it is the value of the
// ":authority" pseudo-header field.
// It may be of the form "host:port". For international domain
// names, Host may be in Punycode or Unicode form. Use
// golang.org/x/net/idna to convert it to either format if
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment