New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
net/http: Expect 100 continue header shouldn't be deleted unnecessarily in server.go #13893
Comments
CL https://golang.org/cl/18471 mentions this issue. |
I don't remember why that's there, and I can't think of a good reason either. Can you do some archaeology and summarized the history for me? Go 1? Go 1.1, 1.2, etc? |
Sure let me do that. |
The code base been there un-touched since 2011.
|
.. Rest is history... :-) |
Thanks. Indeed, there doesn't seem like any particular reason it was deleted. I think there was just some general design confusion back then about which fields we kept in Header and which we promoted to be more first-class. But we shouldn't hide this information. |
Is this possible to get this fix in go1.5.3? or go1.6 ? - should i be sending a fix to those branches as well? |
It will be in 1.6 but not 1.5.x. |
Okay cool |
Issue in net/http/server.go for Expect "100-continue" support.
Incoming client headers.
While calculating signature of incoming headers from the client, there was as signature mismatch on the server side because server cannot generate the same canonical request which was sent over the wire.
The reason is because while all the headers are present
Expect
header is removed pro-actively https://github.com/golang/go/blob/master/src/net/http/server.go#L1455.I don't see any reason to delete this header entry (I may be wrong please correct me here), since it is a value which might be useful for the top level caller to inspect and verify.
Following line fixes this problem.
The text was updated successfully, but these errors were encountered: