Skip to main content
DCtech
Associate III
Aug 9, 2021 5:44 AM UTC
Question

LWIP + TLS on non RTOS

I want to use TLS on lwip using modbus tcp applications. But when I choose the mbedtls on CubeMx, I couldnt select lwip. If I use the Freertos, than I can selecect both of them. But I dont want to use FreeRTOS how can I use lwip-tls together ? In the lwip website https://www.nongnu.org/lwip/2_1_x/group__altcp__tls.html I found the raw api tls documents. Is it possible to use together and how can I use together ?

This topic has been closed for replies.

6 replies

DCtech
DCtechAuthor
Associate III
Aug 9, 2021 12:44 PM UTC

Is there any answer about this?

Wood.Andy
Associate III
Oct 8, 2022 3:01 PM UTC

I would like an answer to this too...

I think I will submit a support ticket ;)

Piranha
Principal III
Oct 9, 2022 12:27 AM UTC

The real solution is to stop clicking broken bloatware generators and start developing code.

https://community.st.com/s/question/0D50X0000BOtfhnSQB/how-to-make-ethernet-and-lwip-working-on-stm32

Wood.Andy
Associate III
Oct 9, 2022 10:40 AM UTC

I know that - I started off writing 6800 assembler and things have just gone downhill since then - but I stupidly thought with the respected LWIP code being involved they might have got it right this time...

I do normally 'roll my own' but TLS is far outside my comfort zone and was wanting to get alttcp _tls to work.

Piranha
Principal III
Oct 9, 2022 11:42 AM UTC

Nobody said that you must roll your own IP stack or cryptography library. Take the lwIP and Mbed TLS and just use those.

https://www.nongnu.org/lwip/2_1_x/group__altcp__api.html

"The TLS layer is not directly implemented by lwIP, but a port to mbedTLS is provided."

You don't even have to develop a port to Mbed TLS. So just integrate lwIP into your platform and that's it.

Wood.Andy
Associate III
Oct 16, 2022 12:46 PM UTC