I am trying use MBED with LWIP on a embedded device. I have managed to get the code compiled and can run it without issues. My embedded device is going to be a server and a windows program the client. I have created a small C# program to test the connection. I have also created a self signed certificate and key that I have placed in a header file. The function altcp_tls_create_config_server_privkey_cert
is used with the header data.
If I start the client running then it does a TCP handshake, then I can see the client hello and then the server hello is sent back. But then nothing happens. I am wondering if for some reason the certifcate authentication is failing? I also can see in Wireshark that the server hello has an “ignored unknown record” issue. Not sure if that is an issue or not and what could be causing it. Any help would be appreciated. Thanks
It seems like the issue may be down to the MSS of the TCP. (its set to 1460) But reading up about TLS it seems that the payload size could be up to 16K. But there seems to be options to reduce this value. I have tried setting the following defines to 1024 bytes
MBEDTLS_SSL_MAX_CONTENT_LEN
MBEDTLS_SSL_IN_CONTENT_LEN
MBEDTLS_SSL_OUT_CONTENT_LEN
but it doesnt seem to make any difference to the size of the server hello payload (1456 bytes).
Is this the correct way to do things?