I wonder if the 7.7.9 case of Autobahn test suite is a valid one?
Here’s the test itself:
Send close with valid close code 1011
Clean close with normal or echoed code
The point is that as per RFC6455 status code 1011 is supposed to be sent by server and not by client:
1011 indicates that a server is terminating the connection because
it encountered an unexpected condition that prevented it from
fulfilling the request.
While RFC doesn’t prohibit client from sending this error code the description clearly states that “the server is terminating the connection”, not the client (which is the test suite in this case).
Even though all the mature server implementations pass this test I wonder whether it is valid at all? What was the rationale for this test?
With best regards, Ihor