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: work around spurious 100 CONTINUE #2184
Labels
Comments
Owner changed to @bradfitz. Status changed to Accepted. |
Is there a live server on the Internet I can verify that this happens with? (before I waste time writing a unit test to behave like that) Are you 100% sure curl isn't sending the "Expect: 100-continue" header? Curl may just not show it with its -v verbose flag. Owner changed to ---. Status changed to WaitingForReply. |
I'm trying to collect more information about the curl and IIS versions (it's hard because they updated the system after this behavior was observed in order to fix it). While I'm not 100% certain that curl didn't send the Expect: header, we saw behavior consistent with an unaccounted-for reply in two other applications. The same curl version and command also worked fine after an upgrade of IIS (as well as the two clients). The symptom in Go when connecting to a server like this is that many back-to-back requests may receive the response from a previous request, and the HTTP package will eventually start saying that it received unsolicited responses. I will respond when I hear back about the version info, and then see if I can't find a website on the internet using that version. |
I can confirm that this happens on (at least) IIS/5.1, even if the response that follows is e.g. 405 Method Not Allowed. It also seems that, although not many servers do this, sending a 100 Continue without an Expect appears to be valid according to RFC 2616. CL here: http://golang.org/cl/5629061 This solves the issue when POSTing or PUTing to IIS/5.1, and the unit test replicates its behavior. |
That CL might fix this issue, but any CL should probably also fix issue #3665, or at least not be incompatible with its eventual fix. |
Example provided by Andy Balholm: # telnet webservices.lscsoft.com 80 Trying 198.31.208.201... Connected to webservices.lscsoft.com. Escape character is '^]'. POST /productmanifest/productmanifest.asmx HTTP/1.1 Accept: text/xml SOAPAction: "intuit.protax.lacerteservices/GetUpdateManifest" Content-Type: text/xml User-Agent: Borland SOAP 1.1 Host: webservices.lscsoft.com Content-Length: 653 Proxy-Connection: Keep-Alive Pragma: no-cache HTTP/1.1 100 Continue Date: Thu, 28 Feb 2013 17:55:41 GMT X-Powered-By: ASP.NET |
Fixed by revision 466040fd273e. Finishing proper support for clients requesting "Expect: 100-continue" is issue #3665. Labels changed: removed priority-later. Owner changed to @bradfitz. Status changed to Fixed. |
This issue was updated by revision b80ce20. Update issue #3665 R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/8208043 |
This issue was closed.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The text was updated successfully, but these errors were encountered: