Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Missing request header" exception #12

Open
vkurland opened this issue Jan 5, 2018 · 2 comments
Open

"Missing request header" exception #12

vkurland opened this issue Jan 5, 2018 · 2 comments

Comments

@vkurland
Copy link

vkurland commented Jan 5, 2018

This happens when the client connects via broken proxy (which can not be fixed). I am ok if this is just a warning but I would like to make sure this does not cause any resource leakage. It would be nice if this did not cause such a verbose printout as it clogs the logs and there is nothing we can do about it on our end.

2018-01-04 22:09:55,124 WARN  qtp2069855160-309        [ty.servlet.ServletHandler]: /socket.io/
java.lang.IllegalStateException: Missing request header 'Sec-WebSocket-Key'
        at org.eclipse.jetty.websocket.server.HandshakeRFC6455.doHandshakeResponse(HandshakeRFC6455.java:44)
        at org.eclipse.jetty.websocket.server.WebSocketServerFactory.upgrade(WebSocketServerFactory.java:574)
        at org.eclipse.jetty.websocket.server.WebSocketServerFactory.acceptWebSocket(WebSocketServerFactory.java:186)
        at com.codeminders.socketio.server.transport.jetty.JettyWebSocketTransport.handle(JettyWebSocketTransport.java:103)
        at com.codeminders.socketio.server.SocketIOServlet.serve(SocketIOServlet.java:148)
        at com.codeminders.socketio.server.SocketIOServlet.doGet(SocketIOServlet.java:101)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:687)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
        at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1669)
        at org.eclipse.jetty.servlets.CrossOriginFilter.handle(CrossOriginFilter.java:256)

alexsaveliev added a commit that referenced this issue Jan 5, 2018
alexsaveliev added a commit that referenced this issue Jan 5, 2018
@alexsaveliev
Copy link

@vkurland could you please check now? I'm sending back bad request if there is no Sec-WebSocket-Key header

@vkurland
Copy link
Author

vkurland commented Jan 5, 2018

I cant reproduce this today but will keep an eye out for it. I think your solution is reasonable, let's keep it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants