mbedtls: MBEDTLS_PRIVATE & MBEDTLS_ALLOW_PRIVATE_ACCESS-related cleanup

This commit is contained in:
Laukik Hase
2022-09-15 12:42:12 +05:30
parent b7ae23856a
commit d7eb2c7b4e
8 changed files with 77 additions and 55 deletions

View File

@@ -9,15 +9,19 @@
#include <stddef.h>
#include <string.h>
#include <stdbool.h>
/* ToDo - Remove this once appropriate solution is available.
We need to define this for the file as ssl_misc.h uses private structures from mbedtls,
which are undefined if the following flag is not defined */
/* Many APIs in the file make use of this flag instead of `MBEDTLS_PRIVATE` */
/* ToDo - Replace them with proper getter-setter once they are added */
/* TODO: Remove this once the appropriate solution is found
*
* ssl_misc.h header uses private elements from
* mbedtls, which become undefined if the following flag
* is not defined
*/
#define MBEDTLS_ALLOW_PRIVATE_ACCESS
// located at mbedtls/library/ssl_misc.h
#include "ssl_misc.h"
#include "mbedtls/ssl.h"
#include "ssl_misc.h" // located at mbedtls/library/ssl_misc.h
#include "mbedtls/platform.h"
#include "esp_log.h"