Unable to Log into Golioth service

I’m seemingly having a repeated issue where the ESP is unable to log into the Golioth service. It’s giving me the following response:

I (1118377) golioth_coap_client_libcoap: Start CoAP session with host: coaps://coap.golioth.io
I (1118377) golioth_coap_client_libcoap: Session PSK-ID: {redacted, correct PSK ID}
I (1118387) libcoap: Setting PSK key

I (1118397) golioth_coap_client_libcoap: Entering CoAP I/O loop
E (1128417) golioth_coap_client_libcoap: Timeout: never got a response from the server
E (1128417) golioth_coap_client_libcoap: DTLS handshake failed. Maybe your PSK-ID or PSK is incorrect?
I (1128427) golioth_coap_client_libcoap: Ending session
E (1128427) golioth_coap_client_libcoap: Received nack reason: COAP_NACK_TLS_FAILED

I’ve verified that the device connects to the Wifi. I’ve also seen this behavior before, and mentioned it on the discord. That time, the workaround was to include the ID and Key in the sdkconfig.defaults. Tried that, but no change. (Also it was stated that the issue from 2022 was patched)

I’m in the process of setting up a new project using the ESP-IDF example project format. I’m working on including the golioth-firmware-sdk as a submodule, rather than trying to work within the golioth-firmware-sdk repo and directory structure. I’ve gotten everything working except this. This is using ESP-IDF v5.2.

This feels like it’s a setting not being set in the sdkconfig, but I’m not sure where to even begin.

I’ll be trying a fresh MCU tomorrow, to see if there’s any remnant cause.

1 Like

@sethkazarians thank you for the detailed report! We had a brief incident this evening which may have had an impact in your observed behavior. The issue has been corrected, but please let me know if you continue to experience errors!

Yes, it seems to be back online and working as expected.

1 Like