Closed BoarK closed 10 years ago
@BoarK I think skipping \r\n in a header "line" violates the spec. Isn't this more a websocket.io issue?
@BoarK What's your opinion? Can I close this?
@lipp,
I replaced the line above in http_headers() with your original version and tested it against a Socket.IO server v0.9.14. I'm still getting an error:
Websocket Handshake failed: Invalid Sec-Websocket-Accept (expected 78qpwK6SG6/mGI3bvuKg8lU5lTg= got nil)
It is still not reading the websocket-accept line correctly. It might be a socket.io issue since it is based on websocket.io. I'm wondering why Socket.io would go the non-standard route.
Nathan.
Is this still active? Anyone has similar problems?
Hi @lipp
I am getting the Handshake failed Error. currently, lua-websockets is configured in openwrt OS and trying to connect Server done using Ratchet-Websockets.
Below error is received.
Websocket Handshake failed: Invalid Sec-Websocket-Accept (expected N9CxZL/lcu6fXwp/V9XHv9kIX6w= got nil)
Pritam
I'm connecting to a simple echo server using websocket.io on localhost. The Sec-WebSocket-Accept line sent from this websocket.io server does not end with a \r\n so the key check fails.
Change made to handshake.http_headers
--for line in request:gmatch('[^\r\n]*\r\n') do for line in request:gmatch("[^\r\n]+") do
Tested on both echo.websocket.org and localhost.