WebSocket client failing to connect to websocket server

daniel.kjellstrom
Posts: 9
Joined: Thu Nov 22, 2018 5:08 pm

WebSocket client failing to connect to websocket server

Postby daniel.kjellstrom » Tue Dec 13, 2022 5:32 pm

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

ESP_YJM
Posts: 300
Joined: Fri Feb 26, 2021 10:30 am

Re: WebSocket client failing to connect to websocket server

Postby ESP_YJM » Wed Dec 14, 2022 8:06 am

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.

Who is online

Users browsing this forum: No registered users and 68 guests