- From: Caitlin Potter <web-platform-tests-notifications@w3.org>
- Date: Mon, 12 May 2014 08:15:54 GMT
- To: public-web-platform-tests-notifications@w3.org
http://tools.ietf.org/html/draft-ietf-httpbis-p1-messaging-26#section-3.3.2 > A sender MUST NOT send a Content-Length header field in any message that contains a Transfer-Encoding header field. > > A user agent SHOULD send a Content-Length in a request message when no Transfer-Encoding is sent and the request method defines a meaning for an enclosed payload body. For example, a Content-Length header field is normally sent in a POST request even when the value is 0 (indicating an empty payload body). **A user agent SHOULD NOT send a Content-Length header field when the request message does not contain a payload body and the method semantics do not anticipate such a body.** So it could be argued that a HEAD request ought not to contain a Content-Length, however most user agents opt to include it anyways, for other reasons. I've already submitted a patch against Chromium to not send a Content-Length for HEAD, and I don't think it would break anything, but there's still a clearly stated reason why it's done, and it's not an improper or illegal action for the UA to take, based on the IETF papers I've read regarding it. View on GitHub: https://github.com/w3c/web-platform-tests/issues/980#issuecomment-42806107
Received on Monday, 12 May 2014 08:16:05 UTC