- From: Andy Green <andy@warmcat.com>
- Date: Fri, 10 Aug 2018 13:55:31 +0800
- To: Julian Reschke <julian.reschke@gmx.de>, Amos Jeffries <squid3@treenet.co.nz>, ietf-http-wg@w3.org
On 08/10/2018 01:45 PM, Julian Reschke wrote: > On 2018-08-10 07:23, Andy Green wrote: >> >> >> On 08/10/2018 01:09 PM, Julian Reschke wrote: >>> On 2018-08-10 05:48, Amos Jeffries wrote: >>>> On 10/08/18 11:25, Mike Bishop wrote: >>>>> Ick. This looks like a 6455 erratum – the registration is “WebSocket” >>>>> but all the (non-normative) examples are “websocket”. >>>>> Case-insensitive >>>>> matching is explicitly permitted, and RFC2616/2817 don’t clearly say >>>>> that Upgrade tokens are or aren’t case-sensitive that I can find. >>>>> (Nor >>>>> do I see it in 7230…?) >>>>> >>>> >>>> I was of the understanding that Upgrade labels are governed by the >>>> relevant protocols equivalent of RFC 7230 section 2.6 rules. So for >>>> example HTTP labels *are* case sensitive, but WebSockets is free to >>>> define sensitivity for its own label. >>>> ... >>> >>> Is it? What if the code that handles the Upgrade token is >>> protocol-agnostic? The problem here is that the IANA registry is >>> first-come-first-serve, and also doesn't have a "case-insensitive" flag. >>> >>> IMHO it would be better to just fix the protocol (ws over h2) - it's >>> not even published yet after all. >> >> The problem only exists between RFC6455 talking about case-insensitive >> receive and the registry having one case variation registered - not >> the one all the implementations I know of are using to send, >> "websockets". There're no actual problem in the field... they all send >> "websockets" but would accept case variation on what they receive. >> Also registering "websockets" will formalize the reality everyone is >> sending "websockets". >> >> The H2 thing doesn't use the same mechanism, and the CONNECT it does >> use already specifies a single literal >> >> ``` >> 5. >> >> The pseudo-header :protocol 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. >> ``` >> >> https://tools.ietf.org/id/draft-ietf-httpbis-h2-websockets-03.html >> >> I couldn't see anywhere that the :protocol names are "registered", but >> that's OK isn't it? > > The spec says that the value for ":protocol" is an Upgrade token from > the IANA registry, hence this mail thread :-) Looks like that was added after the v3 google sent me to ``` 4 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 ``` https://tools.ietf.org/html/draft-ietf-httpbis-h2-websockets-07 >> When you say, "fix the protocol (ws over h2)" what do you envisage >> getting "fixed" in that? > > That would mean changing "websockets" to "WebSockets". Or just register "websockets" in the "HTTP Upgrade token registry" and job done without changing anything else? -Andy >> ... > > Best regards, Julian > >
Received on Friday, 10 August 2018 05:56:26 UTC