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/cgi: Remote Port Param incorrectly discarded #8351
Labels
Milestone
Comments
Reading though other's people issues, I realized that I should have sent the patch to codereview. That is now done. https://golang.org/cl/112900044/ |
Last comment on this, I just went though the CGI RFC (rfc3875) and REMOTE_PORT is not specified in the spec. That said, I can't find a single server that does not set REMOTE_PORT by default. Apache 2.2, Apache 2.4, nginx, and lighttpd all set REMOTE_PORT. I originally dug deeper to see if we could remove the logic of setting the port to zero if REMOTE_PORT was unset, but because the spec does not mandate it, we must do the check. Lastly, while it is generally useless to criticize a finalized RFC, I find it very odd that the CGI spec specifies both REMOTE_ADDR and REMOTE_HOST. The latter of which wants a DNS lookup. On top of that I can't find a server that does pass the REMOTE_HOST param, despite it being something that "SHOULD" be set according to the RFC. As such I can't find a single widely used webserver that follows the spec religiously. |
Any chance of this making it in 1.5? |
@georgyo, the tree just opened. See https://groups.google.com/forum/#!topic/golang-dev/otCULnOjs7I and re-send this patch using the new Git-based process. Thanks! |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Attachments:
The text was updated successfully, but these errors were encountered: