]> Cypherpunks repositories - gostls13.git/commit
net/http: support multiple identical Content-Length headers
authorEmmanuel Odeke <emm.odeke@gmail.com>
Sun, 16 Oct 2016 12:00:27 +0000 (05:00 -0700)
committerBrad Fitzpatrick <bradfitz@golang.org>
Mon, 17 Oct 2016 09:02:42 +0000 (09:02 +0000)
commitfe4307f0607dff7742d047b04df06e721aea7906
tree6fb38164226cc9836e318411b6c01aa726cc78e1
parent516001f50ff3de9f7de2a0525bb771b509504e93
net/http: support multiple identical Content-Length headers

Referencing RFC 7230 Section 3.3.2, this CL
deduplicates multiple identical Content-Length headers
of a message or rejects the message as invalid if the
Content-Length values differ.

Fixes #16490

Change-Id: Ia6b0f58ec7d35710b11a36113d2bd9128f693f64
Reviewed-on: https://go-review.googlesource.com/31252
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/net/http/request_test.go
src/net/http/response_test.go
src/net/http/transfer.go