Description
Hi,
We are experiencing an issue while trying to connect to AWSIOT shadow where the return code is always "-28" (MQTT_REQUEST_TIMEOUT_ERROR)
The below are some key observations:
-
After re-creating the certificates (certificate.pem.crt & private.pem.key) the connection was successful.
-
The older certificates were not corrupted. There was no parse error for the certificates.
The below errors were never seen:
/** Returned when the device certificate is invalid /
NETWORK_X509_DEVICE_CRT_PARSE_ERROR = -20,
/* Returned when the private key failed to parse */
NETWORK_PK_PRIVATE_KEY_PARSE_ERROR = -21, -
The internet connectivity was fine.
-
It was never able to connect to the shadow with the certificates. And as soon as the certificates are re-generated/downloaded, it was able to connect.
Version: https://github.com/aws/aws-iot-device-sdk-embedded-C/releases/tag/v2.1.1
Kindly help to understand what is the issue with the certificates.
As the MQTT_REQUEST_TIMEOUT_ERROR may temporarily come due to actual connection timeout, we are not considering this return code (-28) as a trigger to reset the certificate and private key.
Kindly suggest how we can differentiate this behaviour with genuine timeouts so that we can effectively handle this issue.