]> Cypherpunks repositories - gostls13.git/commit
net/http: make Client copy headers on redirect
authorBrad Fitzpatrick <bradfitz@golang.org>
Fri, 9 Sep 2016 18:06:56 +0000 (18:06 +0000)
committerBrad Fitzpatrick <bradfitz@golang.org>
Fri, 9 Sep 2016 22:55:40 +0000 (22:55 +0000)
commit6e87082d41f0267b39e6a1854d655b1d1c2f7541
tree5d750c045d5d67a5dfeaeef36dd86983e3c64650
parent1161a19c1ef536f8db2ca7eddf0e424e138e37db
net/http: make Client copy headers on redirect

Copy all of the original request's headers on redirect, unless they're
sensitive. Only send sensitive ones to the same origin, or subdomains
thereof.

Fixes #4800

Change-Id: Ie9fa75265c9d5e4c1012c028d31fd1fd74465712
Reviewed-on: https://go-review.googlesource.com/28930
Reviewed-by: Joe Tsai <thebrokentoaster@gmail.com>
Reviewed-by: Francesc Campoy Flores <campoy@golang.org>
Reviewed-by: Ross Light <light@google.com>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/net/http/client.go
src/net/http/client_test.go
src/net/http/export_test.go