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

Client not seeing the "Sec-WebSocket-Accept" header #23

Open
raduvarga opened this issue Jun 3, 2015 · 0 comments
Open

Client not seeing the "Sec-WebSocket-Accept" header #23

raduvarga opened this issue Jun 3, 2015 · 0 comments

Comments

@raduvarga
Copy link

My server was sending the header as "Sec-Websocket-Accept" and not "Sec-WebSocket-Accept" (notice the capital "s"). The solution is change this line in "WebSocketClient":

if (header.getName().equals("Sec-WebSocket-Accept")) {

to this

if (header.getName().toLowerCase().equals("sec-websocket-accept")) {

According to the HTTP header standards: "Each header field consists of a name followed by a colon (":") and the field value. Field names are case-insensitive."

@raduvarga raduvarga changed the title Client not seeing the "Sec-WeBsocket-Accept" header Client not seeing the "Sec-WebSocket-Accept" header Jun 3, 2015
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

1 participant