I am developing IOT device on STM32F427 MCU with web server on-board using HTTPS. It is working fine. In a separate thread (FreeRTOS) I want to create HTTPS client to automatically upload data to remote server with events information.
Is it possible to unite HTTPS server and HTTPS client together? What are the things to take care about?
Thank you for your question!
A TLS peer can either be a server or a client, but not both.
You can see in the API
mbedtls_ssl_config_defaults() that it receives as a parameter
endpoint whether it is a client or a server.
To establish both a client and a server, you will need two instances of
You should probably take into consideration also, depending on your system, the network possible issues, where a port is already in use for the other peer.
Mbed TLS Support