Page 1 of 1

WebSocket client failing to connect to websocket server

Posted: Tue Dec 13, 2022 5:32 pm
by daniel.kjellstrom
Hi,

I have websocket client connecting to my websocket server in the cloud to send some data but I cannot get it to connect. I have tried with a Python script and some Chrome websocket plugins and they all work, I can connect, send and receive data. When I try to connect I receive the following two error messages:

Code: Select all

E (18:19:24.472) TRANSPORT_WS: Sec-WebSocket-Accept not found
E (18:19:24.472) WEBSOCKET_CLIENT: Error transport connect
My implementation is fully based on the websocket client example (I basically copy-pasted it). The ESP-IDF version I'm running is v4.3.1.

Anyone who has had the same problem or knows how to solve it?

Thanks!
Daniel

Re: WebSocket client failing to connect to websocket server

Posted: Wed Dec 14, 2022 8:06 am
by ESP_YJM
Could you please capture the packet on your websocket server. It seems the server not response Sec-WebSocket-Accept in header. You can also capture the packet with your python websocket client. I can compare with them.