mirror of https://github.com/status-im/consul.git
NET-4897 - update comment to include the current issue url from the go team. (#18263)
This commit is contained in:
parent
9a82df27ba
commit
319a2239d3
|
@ -1005,8 +1005,10 @@ func (r *request) toHTTP() (*http.Request, error) {
|
|||
// this is required since go started validating req.host in 1.20.6 and 1.19.11.
|
||||
// prior to that they would strip out the slashes for you. They removed that
|
||||
// behavior and added more strict validation as part of a CVE.
|
||||
// https://github.com/golang/go/issues/60374
|
||||
// the hope is that
|
||||
// This issue is being tracked by the Go team:
|
||||
// https://github.com/golang/go/issues/61431
|
||||
// If there is a resolution in this issue, we will remove this code.
|
||||
// In the time being, this is the accepted workaround.
|
||||
if strings.HasPrefix(r.url.Host, "/") {
|
||||
r.url.Host = "localhost"
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue