following the procedure to establish a TSL communication found in the UserManual 5A-ESP8266_SDK_SSL v1.4 (the most recent I could get) a CA certificate in DER format is flashed to the ESP8266-01 at the location 7C (7C000). The certificate is of a self-signed type.
Unfortunately, running the code flags an error
ca.cer 391
distinguished names: [broker], [broker]
distinguished names: [anon-org], [anon-org]
distinguished names: [machine], [machine]
a self-signed certificate that is not in the CA store
before 1490486400, tv_sec 1491244537, after 1963526400
distinguished names: [broker], [broker]
distinguished names: [anon-org], [anon-org]
distinguished names: [machine], [machine]
client handshake failed
Error: cert is self-signed
PORT CLOSED
So, I am not clear with the meaning of the messages. Are they telling that the certificate is not found in the flash (though the first lign detects the certificate ca.cer 391). Or it is that the ESP8266 handshaking routine cannot deal with the self-signed certificates.
I tried to look-up in the code but only traced the call to the espconn_secure_connect but cannot go beyond the declaration in the header file.
Appreciate any clarification.
Regards