Subject: Re: [hybi] was_clean and _Fail the WebSocket connection_

From: Takeshi Yoshino <[email-masked]>
Date: Tue, 7 Jan 2014 17:27:46 +0900

Thanks, Joakim for comments with the concrete cases listed.

As Jetty is doing, it's fine not to send any close frame for these cases as
the peer is broken.

The point we'd like to clarify is whether to dispatch an error event or
not. IIRC, there is no reason to require closing only for this case. So, I
think it's just a bug in the spec that clients are required not to fail but
close on receiving a masked frame from the server.

----

"Closed _cleanly_" is defined in [1]. Completion of closing handshake is
not explicitly defined in any normative section, but it should mean that
the endpoint has received a valid close frame and has sent a close frame.
[2] says that unexpected TCP closure also requires run of fail algorithm.
So, "unclean => (failed || buffer full on send())" stands, I think.

[1] http://tools.ietf.org/html/rfc6455#section-7.1.4
[2] http://tools.ietf.org/html/rfc6455#section-7.2.1