Hi guys,
I have a web application based on web socket, for old iOS 5.1 devices it only
supports hixie75, they do not submit version or draft info in the header.
However, the WebSocketServerFactory needs this kind of information to
handshake, see the code below from WebSocketServerFactory:
int version = request.getHeaderInt("Sec-WebSocket-Version");
if (version < 0)
{
// Old pre-RFC version specifications (header not present in
RFC-6455)
version = request.getHeaderInt("Sec-WebSocket-Draft");
}
WebSocketHandshake handshaker = handshakes.get(version);
if (handshaker == null)
{
LOG.warn("Unsupported Websocket version: " + version);
// Per RFC 6455 - 4.4 - Supporting Multiple Versions of WebSocket
Protocol
// Using the examples as outlined
response.setHeader("Sec-WebSocket-Version",supportedVersions);
response.sendError(HttpStatus.BAD_REQUEST_400,"Unsupported
websocket version specification");
return false;
}
My question is, is it possible to configure a fallback default
Sec-WebSocket-Version? In my case, I want it to be 17 as a default value.
--
Daniel Wu
Sent with Sparrow (http://www.sparrowmailapp.com/?sig)
_______________________________________________
jetty-users mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/jetty-users