From 7706b6e13512e91b1b7a80431af128052667b9d7 Mon Sep 17 00:00:00 2001 From: Frank Mertens Date: Tue, 3 Sep 2024 19:56:00 +0200 Subject: [PATCH] Added a Kconfig switch to enabled/disable wolfSSL debugging more easily --- CMakeLists.txt | 4 ++++ Kconfig | 7 +++++++ 2 files changed, 11 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6be9451..d258bf9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -150,3 +150,7 @@ idf_component_register( ) target_compile_definitions(${COMPONENT_LIB} PUBLIC WOLFSSL_USER_SETTINGS) + +if(CONFIG_WOLFSSL_DEBUGGING) + target_compile_definitions(${COMPONENT_LIB} PUBLIC DEBUG_WOLFSSL) +endif() diff --git a/Kconfig b/Kconfig index 416607c..a59c335 100644 --- a/Kconfig +++ b/Kconfig @@ -23,4 +23,11 @@ menu "wolfSSL" Note: This option enables mandatory OCSP certificate status checking using OCSP stapling version 1 or 2. The TLS server the client is connecting to must support either of the two TLS extensions. + config WOLFSSL_DEBUGGING + bool "Enable wolfSSL debugging" + default n + help + Enable wolfSSL debugging. Once debugging is enabled sections of code between wolfSSL_Debugging_ON() and + wolfSSL_Debugging_OFF() will generate detailed debug messages. + endmenu # wolfSSL