cancel
Showing results for 
Search instead for 
Did you mean: 

mbedtls: The certificate is not correctly signed by the trusted CA

Duy Tran
Associate II

Hello ST Community,

I am porting the ssl_client example from the STM32F769-DISCO (I don't have the F769-DISCO) to the NUCLEO-F767ZI. The software flow is the same, only the configurations are different. The software can do the connection, handshake, request... However when the X.509 certificate is verified, it always return error MBEDTLS_X509_BADCERT_NOT_TRUSTED - "The certificate is not correctly signed by the trusted CA".

I get the X.509 certificate by running the following command on Ubuntu: echo -n | openssl s_client -connect httpbin.org:443 2>/dev/null </dev/null | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > ~/httpbin.cert

I think I don't either do the configuration correctly or getting the X.509 correctly. Can you give me any advices or any idea to fix it?

Thanks and best regards,

Duy Tran

0 REPLIES 0