You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bradfitz
changed the title
NewSingleHostReverseProxy--Header Key Formatting Issue
net/http/httputil: ReverseProxyHeader doesn't preserve header key case
Dec 5, 2016
I thought about this more and still think the change would be way too invasive to be worth supporting broken application. Considering that http2 doesn't preserve the case of headers either, and http2 is becoming increasingly prevalent, people will need to fix their buggy assumptions sooner or later anyway.
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version
)?1.7
What operating system and processor architecture are you using (
go env
)?Windows 7 & Intel Core I5(x64)
What did you do?
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
What did you expect to see?
HostName -->HostName in httprequest header while using the ReverseProxy functions
/proxy := httputil.NewSingleHostReverseProxy(remote)
proxy.ServeHTTP(w, r)/
What did you see instead?
HostName -->Hostname in httprequest header while using the ReverseProxy functions
https://en.wikipedia.org/wiki/List_of_HTTP_header_fields
The text was updated successfully, but these errors were encountered: