Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build fail with TLS Server session ticket enable (IDFGH-9927) #11222

Closed
3 tasks done
ndedobbeleer opened this issue Apr 18, 2023 · 1 comment
Closed
3 tasks done

Build fail with TLS Server session ticket enable (IDFGH-9927) #11222

ndedobbeleer opened this issue Apr 18, 2023 · 1 comment
Labels
Resolution: Done Issue is done internally Status: Done Issue is done internally Type: Bug bugs in IDF

Comments

@ndedobbeleer
Copy link

Answers checklist.

  • I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
  • I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
  • I have searched the issue tracker for a similar issue and not found a similar issue.

IDF version.

5.0.1

Operating System used.

Windows

How did you build your project?

Eclipse IDE

If you are using Windows, please specify command line type.

None

What is the expected behavior?

When TLS server session is enable, the projetc should build.

What is the actual behavior?

The build process finish with 16 error

Steps to reproduce.

  1. Create project from template example using template "protocols/https_server/simple"
  2. Enable tls server session ticket in sdkconfig => CONFIG_ESP_TLS_SERVER_SESSION_TICKETS=y
  3. Check if mbedtls server SLL session ticket is enable => CONFIG_MBEDTLS_SERVER_SSL_SESSION_TICKETS=y (default : yes)
  4. Build the project
  5. Build fail

Build or installation Logs.

[10/309] ccache C:\Espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin\xtensa-esp32s3-elf-gcc.exe -DMBEDTLS_CONFIG_FILE=\"mbedtls/esp_config.h\" -IC:/Espressif/frameworks/esp-idf-v5.0.1/workspace/simple/build/config -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/esp-tls-crypto -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/private_include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/newlib/platform_include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/FreeRTOS-Kernel/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/esp_additions/include/freertos -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/FreeRTOS-Kernel/portable/xtensa/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/esp_additions/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/include/soc -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/include/soc/esp32s3 -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/port/esp32s3/. -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/port/esp32s3/private_include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/heap/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/log/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/soc/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/soc/esp32s3/. -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/soc/esp32s3/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/hal/esp32s3/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/hal/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/hal/platform_port/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_rom/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_rom/include/esp32s3 -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_rom/esp32s3 -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_common/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_system/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_system/port/soc -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_system/port/include/private -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/xtensa/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/xtensa/esp32s3/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/include/apps -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/include/apps/sntp -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/lwip/src/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/port/esp32/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/port/esp32/include/arch -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/port/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/mbedtls/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/mbedtls/library -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/esp_crt_bundle/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/http_parser -mlongcalls  -fdiagnostics-color=always -ffunction-sections -fdata-sections -Wall -Werror=all -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=deprecated-declarations -Wextra -Wno-unused-parameter -Wno-sign-compare -Wno-enum-conversion -gdwarf-4 -ggdb -Og -fmacro-prefix-map=C:/Espressif/frameworks/esp-idf-v5.0.1/workspace/simple=. -fmacro-prefix-map=C:/Espressif/frameworks/esp-idf-v5.0.1=/IDF -fstrict-volatile-bitfields -Wno-error=unused-but-set-variable -fno-jump-tables -fno-tree-switch-conversion -DconfigENABLE_FREERTOS_DEBUG_OCDAWARE=1 -std=gnu17 -Wno-old-style-declaration -D_GNU_SOURCE -DIDF_VER=\"v5.0.1\" -DESP_PLATFORM -D_POSIX_READER_WRITER_LOCKS -MD -MT esp-idf/esp-tls/CMakeFiles/__idf_esp-tls.dir/esp_tls_error_capture.c.obj -MF esp-idf\esp-tls\CMakeFiles\__idf_esp-tls.dir\esp_tls_error_capture.c.obj.d -o esp-idf/esp-tls/CMakeFiles/__idf_esp-tls.dir/esp_tls_error_capture.c.obj -c C:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/esp_tls_error_capture.c
FAILED: esp-idf/esp-tls/CMakeFiles/__idf_esp-tls.dir/esp_tls_error_capture.c.obj 
ccache C:\Espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin\xtensa-esp32s3-elf-gcc.exe -DMBEDTLS_CONFIG_FILE=\"mbedtls/esp_config.h\" -IC:/Espressif/frameworks/esp-idf-v5.0.1/workspace/simple/build/config -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/esp-tls-crypto -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/private_include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/newlib/platform_include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/FreeRTOS-Kernel/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/esp_additions/include/freertos -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/FreeRTOS-Kernel/portable/xtensa/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/freertos/esp_additions/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/include/soc -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/include/soc/esp32s3 -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/port/esp32s3/. -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_hw_support/port/esp32s3/private_include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/heap/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/log/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/soc/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/soc/esp32s3/. -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/soc/esp32s3/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/hal/esp32s3/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/hal/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/hal/platform_port/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_rom/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_rom/include/esp32s3 -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_rom/esp32s3 -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_common/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_system/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_system/port/soc -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/esp_system/port/include/private -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/xtensa/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/xtensa/esp32s3/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/include/apps -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/include/apps/sntp -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/lwip/src/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/port/esp32/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/lwip/port/esp32/include/arch -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/port/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/mbedtls/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/mbedtls/library -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/mbedtls/esp_crt_bundle/include -IC:/Espressif/frameworks/esp-idf-v5.0.1/components/http_parser -mlongcalls  -fdiagnostics-color=always -ffunction-sections -fdata-sections -Wall -Werror=all -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=deprecated-declarations -Wextra -Wno-unused-parameter -Wno-sign-compare -Wno-enum-conversion -gdwarf-4 -ggdb -Og -fmacro-prefix-map=C:/Espressif/frameworks/esp-idf-v5.0.1/workspace/simple=. -fmacro-prefix-map=C:/Espressif/frameworks/esp-idf-v5.0.1=/IDF -fstrict-volatile-bitfields -Wno-error=unused-but-set-variable -fno-jump-tables -fno-tree-switch-conversion -DconfigENABLE_FREERTOS_DEBUG_OCDAWARE=1 -std=gnu17 -Wno-old-style-declaration -D_GNU_SOURCE -DIDF_VER=\"v5.0.1\" -DESP_PLATFORM -D_POSIX_READER_WRITER_LOCKS -MD -MT esp-idf/esp-tls/CMakeFiles/__idf_esp-tls.dir/esp_tls_error_capture.c.obj -MF esp-idf\esp-tls\CMakeFiles\__idf_esp-tls.dir\esp_tls_error_capture.c.obj.d -o esp-idf/esp-tls/CMakeFiles/__idf_esp-tls.dir/esp_tls_error_capture.c.obj -c C:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/esp_tls_error_capture.c
In file included from C:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/esp_tls_error_capture.c:7:
C:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/esp_tls.h:191:5: error: unknown type name 'mbedtls_entropy_context'
  191 |     mbedtls_entropy_context entropy;                                            /*!< mbedTLS entropy context structure */
      |     ^~~~~~~~~~~~~~~~~~~~~~~
C:/Espressif/frameworks/esp-idf-v5.0.1/components/esp-tls/esp_tls.h:193:5: error: unknown type name 'mbedtls_ctr_drbg_context'
  193 |     mbedtls_ctr_drbg_context ctr_drbg;                                          /*!< mbedTLS ctr drbg context structure.
      |     ^~~~~~~~~~~~~~~~~~~~~~~~

More Information.

I can work around this problem with manually add this lines in sll_ticket.h :

#include "entropy.h"
#include "ctr_drbg.h"

But it's not a permanent solution. Maybe there is something else to do?

@ndedobbeleer ndedobbeleer added the Type: Bug bugs in IDF label Apr 18, 2023
@github-actions github-actions bot changed the title Build fail with TLS Server session ticket enable Build fail with TLS Server session ticket enable (IDFGH-9927) Apr 18, 2023
@espressif-bot espressif-bot added the Status: Opened Issue is new label Apr 18, 2023
@mahavirj
Copy link
Member

This was reported in #10765 and fixed through 6692a13. Fix will be part of next 5.0.x release.

@espressif-bot espressif-bot added Resolution: Done Issue is done internally Status: Done Issue is done internally and removed Status: Opened Issue is new labels Apr 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Done Issue is done internally Status: Done Issue is done internally Type: Bug bugs in IDF
Projects
None yet
Development

No branches or pull requests

3 participants