The websocket_example.c fails on esp32 when we try to connect to a secure WSS socket.
I have enabled the default certificate bundle in sdkconfig, and set transport to SSL in the config, but still no luck.
How to get the websocket client to use the certificate bundle?
The debug trace is below:
I (2090) esp_netif_handlers: example_connect: sta ip: 192.168.0.16, mask: 255.255.255.0, gw: 192.168.0.1
I (2090) example_connect: Got IPv4 event: Interface "example_connect: sta" address: 192.168.0.16
I (2590) example_connect: Got IPv6 event: Interface "example_connect: sta" address: fe80:0000:0000:0000:e2e2:e6ff:fee4:b4bc, type: ESP_IP6_ADDR_IS_LINK_LOCAL
I (2590) example_connect: Connected to example_connect: sta
I (2600) example_connect: - IPv4 address: 192.168.0.16
I (2600) example_connect: - IPv6 address: fe80:0000:0000:0000:e2e2:e6ff:fee4:b4bc, type: ESP_IP6_ADDR_IS_LINK_LOCAL
I (2620) WEBSOCKET: Connecting to wss://demo.piesocket.com/v3/channel_1?api_key=oCdCMcMPQpbvNjUIzqtvF1d2X2okWpDQj4AwARJuAgtjhzKxVEjQU6IdCjwm¬ify_self...
E (2730) esp-tls-mbedtls: No server verification option set in esp_tls_cfg_t structure. Check esp_tls API reference
E (2730) esp-tls-mbedtls: Failed to set client configurations
E (2740) esp-tls: create_ssl_handle failed
E (2740) esp-tls: Failed to open new connection
E (2750) TRANS_SSL: Failed to open a new connection
E (2760) TRANSPORT_WS: Error connecting to host demo.piesocket.com:443
E (2760) WEBSOCKET_CLIENT: Error transport connect
I (2770) WEBSOCKET_CLIENT: Reconnect after 10000 ms
I (2770) WEBSOCKET: WEBSOCKET_EVENT_DISCONNECTED
websocket_example.c WSS
Jump to
- English Forum
- Explore
- News
- General Discussion
- FAQ
- Documentation
- Documentation
- Sample Code
- Discussion Forum
- Hardware
- ESP-IDF
- ESP-BOX
- ESP-ADF
- ESP-MDF
- ESP-WHO
- ESP-SkaiNet
- ESP32 Arduino
- IDEs for ESP-IDF
- ESP-AT
- ESP IoT Solution
- ESP RainMaker
- Rust
- ESP8266
- Report Bugs
- Showcase
- Chinese Forum 中文社区
- 活动区
- 乐鑫活动专区
- 讨论区
- 全国大学生物联网设计竞赛乐鑫答疑专区
- ESP-IDF 中文讨论版
- 《ESP32-C3 物联网工程开发实战》书籍讨论版
- 中文文档讨论版
- ESP-AT 中文讨论版
- ESP-BOX 中文讨论版
- ESP IoT Solution 中文讨论版
- ESP-ADF 中文讨论版
- ESP Mesh 中文讨论版
- ESP Cloud 中文讨论版
- ESP-WHO 中文讨论版
- ESP-SkaiNet 中文讨论版
- ESP 生产支持讨论版
- 硬件问题讨论
- 项目展示
Who is online
Users browsing this forum: Baoshi, Bing [Bot] and 90 guests
- All times are UTC
- Top
- Delete cookies
About Us
Espressif Systems is a fabless semiconductor company providing cutting-edge low power WiFi SoCs and wireless solutions for wireless communications and Internet of Things applications. ESP8266EX and ESP32 are some of our products.