- From: Julian Reschke <julian.reschke@gmx.de>
- Date: Thu, 9 Aug 2018 07:16:34 +0200
- To: HTTP Working Group <ietf-http-wg@w3.org>
- Cc: Alexey Melnikov <alexey.melnikov@isode.com>, Patrick McManus <mcmanus@ducksong.com>
<https://tools.ietf.org/html/draft-ietf-httpbis-h2-websockets-07#section-4>: > o A new pseudo-header field :protocol MAY be included on request > HEADERS indicating the desired protocol to be spoken on the tunnel > created by CONNECT. The pseudo-header field is single valued and > contains a value from the HTTP Upgrade Token Registry located at > https://www.iana.org/assignments/http-upgrade-tokens/http-upgrade- > tokens.xhtml And in <https://www.iana.org/assignments/http-upgrade-tokens/http-upgrade-tokens.xhtml>: > WebSocket The Web Socket Protocol [RFC6455] But, later on in <https://tools.ietf.org/html/draft-ietf-httpbis-h2-websockets-07#section-5> and subsequent examples: > The :protocol pseudo-header field MUST be included in the CONNECT > request and it MUST have a value of "websocket" to initiate a > WebSocket connection on an HTTP/2 stream. Other HTTP request and > response header fields, such as those for manipulating cookies, may > be included in the HEADERS with the CONNECT method as usual. This > request replaces the GET-based request in [RFC6455] and is used to > process the WebSockets opening handshake. Note that the registered upgrade token is "WebSocket", but the spec requires the use of "websocket". See also <https://github.com/httpwg/http-core/issues/8>. Recommendation, in order of preference: 1) Fix the spec to use "WebSocket" consistently. 2) Register "websocket" as alias. It would probably be good to also clarify that value matching for ":protocol" is consistent with "Upgrade" in HTTP/1.1, meaning case-sensitive. Best regards, Julian
Received on Thursday, 9 August 2018 05:17:09 UTC