sslmakefilecmaketls1.3wolfssl

WolfSSL: Resume Session failure due to configuration issue of build (cmake)


I am using an Ubuntu 20.04 machine along with the CLion IDE 2020.3.2 and I want to create an app using WolfSSL which would need the TLS1.3 implementation of it.

Using CLion, I cloned the official repository https://github.com/wolfSSL/wolfssl.git. CLion automatically built the project and I was able to run all the \wolfssl\examples perfectly. Thus, the resumption session does not work. I run both Server/Client with these arguments: client/server -v 4 -r And I am getting this output from the client side: didn't reuse session id!!! which I can verify from Wireshark that there was no resumption made but just another handshake.

At another build I did, where instead of cmake ( which is the default of CLion ) I used make I manged to run properly the resumption but for that I had to add in the configuration before the build this command: ./configure --enable-all which "Enables all wolfSSL features, excluding SSL v3".

What is the equivalent command of --enable-all I should use in my Cmake configuration ? Or what should I do so I can achieve properly the resumption?

I tried -DWOLFSSL_ALL -DENABLE_ALL and others but did not managed to do it. I tried including many of them separately to find which is the one that enables the resumption but nothing yet.


Solution

  • The specific wolfSSL option for enabling TLS sessions is HAVE_SESSION_TICKET.

    There is not currently an equivalent macro for the ./configure --enable-all option, but you can use the "user_settings" method to get close: https://github.com/wolfSSL/wolfssl/tree/master/examples/configs

    Here is an example that configures most of the library options: https://github.com/wolfSSL/wolfssl/blob/master/examples/configs/user_settings_all.h