I’m trying to establish a connection to an MQTT broker hosted on AWS IoT Core from an HL7800 (v4.6.9) with an Orange SIM card. This requires an SSL connection, so I need to specify certificates. I’m able to connect to this MQTT broker via Python script.
The code previously connected to another MQTT broker which only had username/password authentication. After setting up TCP over SSL, I try to start a connection and get TCP Notification 13 = SSL connection error.
I’m using these commands to set up the SSL connection:
AT+KSSLCRYPTO=0,8,1,8192,4,4,3,0 (note: profile_idx: 0, mkey_algo: ECDHE, auth_algo: RSA, enc_algo: AES-128-GCM, mac_algo: SHA-256, tls_ver: 1.2, auth: mutual, root_cert_idx: 0)
AT+KCERTSTORE=0, (int)sizeof(ROOT_CERT), 0 (root certificate)
AT+KCERTSTORE=1, (int)sizeof(LOCAL_CERT), 0 (local certificate)
AT+KPRIVSTORE=0, (int)sizeof(LOCAL_PRIVATE_KEY) (private key)
Connection to MQTT:
After the last command I get:
Can you see any place where I’m doing something obviously wrong, or anything that I may be ignoring?
Notice that this is not the full list of commands I’m using, but only those that I believe could be the problematic ones. Happy to provide more details if neeed!