mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-23 02:55:41 +01:00
Revert "config: Remove TLS and NET options"
This reverts commit 1c66e48670
.
Conflicts:
* include/mbedtls/check_config.h:
* MBEDTLS_SSL_PROTO_SSL3: there has been an addition (of
MBEDTLS_SHA512_NO_SHA384) at the place where it was removed. Re-add it
after (alphabetical order).
* MBEDTLS_ENABLE_WEAK_CIPHERSUITES: there has been an addition (of
MBEDTLS_CTR_DRBG_USE_128_BIT_KEY) at the place where it was removed.
Re-add it after (alphabetical order).
* MBEDTLS_SSL_ALL_ALERT_MESSAGES: there has been an addition (of
MBEDTLS_SHA512_SMALLER) at the place where it was removed. Re-add it
after (alphabetical order).
* include/mbedtls/config.h:
* MBEDTLS_ENABLE_WEAK_CIPHERSUITES: there has been an addition (of
MBEDTLS_CTR_DRBG_USE_128_BIT_KEY) at the place where it was removed.
Re-add it after (alphabetical order).
* MBEDTLS_SSL_ALL_ALERT_MESSAGES: there has been an addition (of
MBEDTLS_SHA512_SMALLER) at the place where it was removed. Re-add it
after (alphabetical order).
* library/version_features.c: re-generate by running
scripts/generate_features.pl.
* programs/test/query_config.c: re-generate by running
scripts/generate_query_config.pl.
* scripts/config.pl: this file has been replaced by config.py. Port
the reversed changes to config.py:
* Revert removing three symbols from the list of symbols to
exclude from full.
* Revert removing one symbol (MBEDTLS_NET_C) from the list of symbols
to exclude from baremetal.
* scripts/footprint.sh:
* Re-add the line to unset MBEDTLS_NET_C, but with config.py instead of
config.pl.
* tests/scripts/all.sh:
* component_test_no_platform: re-add the line to unset MBEDTLS_NET_C, but
with config.py instead of config.pl.
* component_build_arm_none_eabi_gcc,
component_build_arm_none_eabi_gcc_no_udbl_division,
component_build_arm_none_eabi_gcc_no_64bit_multiplication,
component_build_armcc: these components now use the baremetal
configuration, so they do not need to turn off MBEDTLS_NET_C explicitly.
This commit is contained in:
parent
252e391cca
commit
4e1174967a
@ -1,8 +1,8 @@
|
|||||||
This directory contains example configuration files.
|
This directory contains example configuration files.
|
||||||
|
|
||||||
The examples are generally focused on a particular usage case (eg, support for
|
The examples are generally focused on a particular usage case (eg, support for
|
||||||
a restricted number of TLS ciphersuites) and aim at minimizing resource usage
|
a restricted number of ciphersuites) and aim at minimizing resource usage for
|
||||||
for this target. They can be used as a basis for custom configurations.
|
this target. They can be used as a basis for custom configurations.
|
||||||
|
|
||||||
These files are complete replacements for the default config.h. To use one of
|
These files are complete replacements for the default config.h. To use one of
|
||||||
them, you can pick one of the following methods:
|
them, you can pick one of the following methods:
|
||||||
|
@ -41,6 +41,7 @@
|
|||||||
/* mbed TLS feature support */
|
/* mbed TLS feature support */
|
||||||
#define MBEDTLS_CIPHER_MODE_CBC
|
#define MBEDTLS_CIPHER_MODE_CBC
|
||||||
#define MBEDTLS_CIPHER_PADDING_PKCS7
|
#define MBEDTLS_CIPHER_PADDING_PKCS7
|
||||||
|
#define MBEDTLS_REMOVE_ARC4_CIPHERSUITES
|
||||||
#define MBEDTLS_ECP_DP_SECP256R1_ENABLED
|
#define MBEDTLS_ECP_DP_SECP256R1_ENABLED
|
||||||
#define MBEDTLS_ECP_DP_SECP384R1_ENABLED
|
#define MBEDTLS_ECP_DP_SECP384R1_ENABLED
|
||||||
#define MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
#define MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -22,8 +22,7 @@
|
|||||||
* This file is part of mbed TLS (https://tls.mbed.org)
|
* This file is part of mbed TLS (https://tls.mbed.org)
|
||||||
*/
|
*/
|
||||||
/*
|
/*
|
||||||
* Minimal configuration for the crypto required for TLS NSA Suite B Profile
|
* Minimal configuration for TLS NSA Suite B Profile (RFC 6460)
|
||||||
* (RFC 6460)
|
|
||||||
*
|
*
|
||||||
* Distinguishing features:
|
* Distinguishing features:
|
||||||
* - no RSA or classic DH, fully based on ECC
|
* - no RSA or classic DH, fully based on ECC
|
||||||
@ -46,6 +45,8 @@
|
|||||||
/* mbed TLS feature support */
|
/* mbed TLS feature support */
|
||||||
#define MBEDTLS_ECP_DP_SECP256R1_ENABLED
|
#define MBEDTLS_ECP_DP_SECP256R1_ENABLED
|
||||||
#define MBEDTLS_ECP_DP_SECP384R1_ENABLED
|
#define MBEDTLS_ECP_DP_SECP384R1_ENABLED
|
||||||
|
#define MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||||
|
#define MBEDTLS_SSL_PROTO_TLS1_2
|
||||||
|
|
||||||
/* mbed TLS modules */
|
/* mbed TLS modules */
|
||||||
#define MBEDTLS_AES_C
|
#define MBEDTLS_AES_C
|
||||||
@ -66,6 +67,9 @@
|
|||||||
#define MBEDTLS_PK_PARSE_C
|
#define MBEDTLS_PK_PARSE_C
|
||||||
#define MBEDTLS_SHA256_C
|
#define MBEDTLS_SHA256_C
|
||||||
#define MBEDTLS_SHA512_C
|
#define MBEDTLS_SHA512_C
|
||||||
|
#define MBEDTLS_SSL_CLI_C
|
||||||
|
#define MBEDTLS_SSL_SRV_C
|
||||||
|
#define MBEDTLS_SSL_TLS_C
|
||||||
#define MBEDTLS_X509_CRT_PARSE_C
|
#define MBEDTLS_X509_CRT_PARSE_C
|
||||||
#define MBEDTLS_X509_USE_C
|
#define MBEDTLS_X509_USE_C
|
||||||
|
|
||||||
@ -95,6 +99,19 @@
|
|||||||
*/
|
*/
|
||||||
#define MBEDTLS_ENTROPY_MAX_SOURCES 2
|
#define MBEDTLS_ENTROPY_MAX_SOURCES 2
|
||||||
|
|
||||||
|
/* Save ROM and a few bytes of RAM by specifying our own ciphersuite list */
|
||||||
|
#define MBEDTLS_SSL_CIPHERSUITES \
|
||||||
|
MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384, \
|
||||||
|
MBEDTLS_TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Save RAM at the expense of interoperability: do this only if you control
|
||||||
|
* both ends of the connection! (See coments in "mbedtls/ssl.h".)
|
||||||
|
* The minimum size here depends on the certificate chain used as well as the
|
||||||
|
* typical size of records.
|
||||||
|
*/
|
||||||
|
#define MBEDTLS_SSL_MAX_CONTENT_LEN 1024
|
||||||
|
|
||||||
#include "mbedtls/check_config.h"
|
#include "mbedtls/check_config.h"
|
||||||
|
|
||||||
#endif /* MBEDTLS_CONFIG_H */
|
#endif /* MBEDTLS_CONFIG_H */
|
||||||
|
@ -57,8 +57,9 @@
|
|||||||
#endif
|
#endif
|
||||||
#endif /* _WIN32 */
|
#endif /* _WIN32 */
|
||||||
|
|
||||||
#if defined(TARGET_LIKE_MBED) && defined(MBEDTLS_TIMING_C)
|
#if defined(TARGET_LIKE_MBED) && \
|
||||||
#error "The TIMING module is not available for mbed OS - please use the timing functions provided by Mbed OS"
|
( defined(MBEDTLS_NET_C) || defined(MBEDTLS_TIMING_C) )
|
||||||
|
#error "The NET and TIMING modules are not available for mbed OS - please use the network and timing functions provided by mbed OS"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(MBEDTLS_DEPRECATED_WARNING) && \
|
#if defined(MBEDTLS_DEPRECATED_WARNING) && \
|
||||||
@ -82,6 +83,10 @@
|
|||||||
#error "MBEDTLS_DHM_C defined, but not all prerequisites"
|
#error "MBEDTLS_DHM_C defined, but not all prerequisites"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT) && !defined(MBEDTLS_SSL_TRUNCATED_HMAC)
|
||||||
|
#error "MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(MBEDTLS_CMAC_C) && \
|
#if defined(MBEDTLS_CMAC_C) && \
|
||||||
!defined(MBEDTLS_AES_C) && !defined(MBEDTLS_DES_C)
|
!defined(MBEDTLS_AES_C) && !defined(MBEDTLS_DES_C)
|
||||||
#error "MBEDTLS_CMAC_C defined, but not all prerequisites"
|
#error "MBEDTLS_CMAC_C defined, but not all prerequisites"
|
||||||
@ -232,6 +237,69 @@
|
|||||||
#error "MBEDTLS_HMAC_DRBG_C defined, but not all prerequisites"
|
#error "MBEDTLS_HMAC_DRBG_C defined, but not all prerequisites"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_ECDH_C) || !defined(MBEDTLS_X509_CRT_PARSE_C) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_ECDH_C) || !defined(MBEDTLS_X509_CRT_PARSE_C) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED) && !defined(MBEDTLS_DHM_C)
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED) && \
|
||||||
|
!defined(MBEDTLS_ECDH_C)
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_DHM_C) || !defined(MBEDTLS_RSA_C) || \
|
||||||
|
!defined(MBEDTLS_X509_CRT_PARSE_C) || !defined(MBEDTLS_PKCS1_V15) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_ECDH_C) || !defined(MBEDTLS_RSA_C) || \
|
||||||
|
!defined(MBEDTLS_X509_CRT_PARSE_C) || !defined(MBEDTLS_PKCS1_V15) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_ECDH_C) || !defined(MBEDTLS_ECDSA_C) || \
|
||||||
|
!defined(MBEDTLS_X509_CRT_PARSE_C) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_RSA_C) || !defined(MBEDTLS_X509_CRT_PARSE_C) || \
|
||||||
|
!defined(MBEDTLS_PKCS1_V15) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_RSA_C) || !defined(MBEDTLS_X509_CRT_PARSE_C) || \
|
||||||
|
!defined(MBEDTLS_PKCS1_V15) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_RSA_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED) && \
|
||||||
|
( !defined(MBEDTLS_ECJPAKE_C) || !defined(MBEDTLS_SHA256_C) || \
|
||||||
|
!defined(MBEDTLS_ECP_DP_SECP256R1_ENABLED) )
|
||||||
|
#error "MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE__WITH_CERT__ENABLED) && \
|
||||||
|
!defined(MBEDTLS_SSL_KEEP_PEER_CERTIFICATE) && \
|
||||||
|
( !defined(MBEDTLS_SHA256_C) && \
|
||||||
|
!defined(MBEDTLS_SHA512_C) && \
|
||||||
|
!defined(MBEDTLS_SHA1_C) )
|
||||||
|
#error "!MBEDTLS_SSL_KEEP_PEER_CERTIFICATE requires MBEDTLS_SHA512_C, MBEDTLS_SHA256_C or MBEDTLS_SHA1_C"
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) && \
|
#if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) && \
|
||||||
( !defined(MBEDTLS_PLATFORM_C) || !defined(MBEDTLS_PLATFORM_MEMORY) )
|
( !defined(MBEDTLS_PLATFORM_C) || !defined(MBEDTLS_PLATFORM_MEMORY) )
|
||||||
#error "MBEDTLS_MEMORY_BUFFER_ALLOC_C defined, but not all prerequisites"
|
#error "MBEDTLS_MEMORY_BUFFER_ALLOC_C defined, but not all prerequisites"
|
||||||
@ -523,6 +591,114 @@
|
|||||||
#error "MBEDTLS_SHA512_NO_SHA384 defined without MBEDTLS_SHA512_C"
|
#error "MBEDTLS_SHA512_NO_SHA384 defined without MBEDTLS_SHA512_C"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_SSL3) && ( !defined(MBEDTLS_MD5_C) || \
|
||||||
|
!defined(MBEDTLS_SHA1_C) )
|
||||||
|
#error "MBEDTLS_SSL_PROTO_SSL3 defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1) && ( !defined(MBEDTLS_MD5_C) || \
|
||||||
|
!defined(MBEDTLS_SHA1_C) )
|
||||||
|
#error "MBEDTLS_SSL_PROTO_TLS1 defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1_1) && ( !defined(MBEDTLS_MD5_C) || \
|
||||||
|
!defined(MBEDTLS_SHA1_C) )
|
||||||
|
#error "MBEDTLS_SSL_PROTO_TLS1_1 defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1_2) && ( !defined(MBEDTLS_SHA1_C) && \
|
||||||
|
!defined(MBEDTLS_SHA256_C) && !defined(MBEDTLS_SHA512_C) )
|
||||||
|
#error "MBEDTLS_SSL_PROTO_TLS1_2 defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_DTLS) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_1) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
||||||
|
#error "MBEDTLS_SSL_PROTO_DTLS defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_CLI_C) && !defined(MBEDTLS_SSL_TLS_C)
|
||||||
|
#error "MBEDTLS_SSL_CLI_C defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TLS_C) && ( !defined(MBEDTLS_CIPHER_C) || \
|
||||||
|
!defined(MBEDTLS_MD_C) )
|
||||||
|
#error "MBEDTLS_SSL_TLS_C defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_SRV_C) && !defined(MBEDTLS_SSL_TLS_C)
|
||||||
|
#error "MBEDTLS_SSL_SRV_C defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TLS_C) && (!defined(MBEDTLS_SSL_PROTO_SSL3) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1) && !defined(MBEDTLS_SSL_PROTO_TLS1_1) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_2))
|
||||||
|
#error "MBEDTLS_SSL_TLS_C defined, but no protocols are active"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TLS_C) && (defined(MBEDTLS_SSL_PROTO_SSL3) && \
|
||||||
|
defined(MBEDTLS_SSL_PROTO_TLS1_1) && !defined(MBEDTLS_SSL_PROTO_TLS1))
|
||||||
|
#error "Illegal protocol selection"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TLS_C) && (defined(MBEDTLS_SSL_PROTO_TLS1) && \
|
||||||
|
defined(MBEDTLS_SSL_PROTO_TLS1_2) && !defined(MBEDTLS_SSL_PROTO_TLS1_1))
|
||||||
|
#error "Illegal protocol selection"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TLS_C) && (defined(MBEDTLS_SSL_PROTO_SSL3) && \
|
||||||
|
defined(MBEDTLS_SSL_PROTO_TLS1_2) && (!defined(MBEDTLS_SSL_PROTO_TLS1) || \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_1)))
|
||||||
|
#error "Illegal protocol selection"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_HELLO_VERIFY) && !defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||||
|
#error "MBEDTLS_SSL_DTLS_HELLO_VERIFY defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE) && \
|
||||||
|
!defined(MBEDTLS_SSL_DTLS_HELLO_VERIFY)
|
||||||
|
#error "MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_ANTI_REPLAY) && \
|
||||||
|
( !defined(MBEDTLS_SSL_TLS_C) || !defined(MBEDTLS_SSL_PROTO_DTLS) )
|
||||||
|
#error "MBEDTLS_SSL_DTLS_ANTI_REPLAY defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_BADMAC_LIMIT) && \
|
||||||
|
( !defined(MBEDTLS_SSL_TLS_C) || !defined(MBEDTLS_SSL_PROTO_DTLS) )
|
||||||
|
#error "MBEDTLS_SSL_DTLS_BADMAC_LIMIT defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_ENCRYPT_THEN_MAC) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_1) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
||||||
|
#error "MBEDTLS_SSL_ENCRYPT_THEN_MAC defined, but not all prerequsites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_EXTENDED_MASTER_SECRET) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_1) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
||||||
|
#error "MBEDTLS_SSL_EXTENDED_MASTER_SECRET defined, but not all prerequsites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TICKET_C) && !defined(MBEDTLS_CIPHER_C)
|
||||||
|
#error "MBEDTLS_SSL_TICKET_C defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_CBC_RECORD_SPLITTING) && \
|
||||||
|
!defined(MBEDTLS_SSL_PROTO_SSL3) && !defined(MBEDTLS_SSL_PROTO_TLS1)
|
||||||
|
#error "MBEDTLS_SSL_CBC_RECORD_SPLITTING defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_SERVER_NAME_INDICATION) && \
|
||||||
|
!defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||||
|
#error "MBEDTLS_SSL_SERVER_NAME_INDICATION defined, but not all prerequisites"
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(MBEDTLS_THREADING_PTHREAD)
|
#if defined(MBEDTLS_THREADING_PTHREAD)
|
||||||
#if !defined(MBEDTLS_THREADING_C) || defined(MBEDTLS_THREADING_IMPL)
|
#if !defined(MBEDTLS_THREADING_C) || defined(MBEDTLS_THREADING_IMPL)
|
||||||
#error "MBEDTLS_THREADING_PTHREAD defined, but not all prerequisites"
|
#error "MBEDTLS_THREADING_PTHREAD defined, but not all prerequisites"
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -303,6 +303,15 @@ static const char * const features[] = {
|
|||||||
#if defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY)
|
#if defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY)
|
||||||
"MBEDTLS_CTR_DRBG_USE_128_BIT_KEY",
|
"MBEDTLS_CTR_DRBG_USE_128_BIT_KEY",
|
||||||
#endif /* MBEDTLS_CTR_DRBG_USE_128_BIT_KEY */
|
#endif /* MBEDTLS_CTR_DRBG_USE_128_BIT_KEY */
|
||||||
|
#if defined(MBEDTLS_ENABLE_WEAK_CIPHERSUITES)
|
||||||
|
"MBEDTLS_ENABLE_WEAK_CIPHERSUITES",
|
||||||
|
#endif /* MBEDTLS_ENABLE_WEAK_CIPHERSUITES */
|
||||||
|
#if defined(MBEDTLS_REMOVE_ARC4_CIPHERSUITES)
|
||||||
|
"MBEDTLS_REMOVE_ARC4_CIPHERSUITES",
|
||||||
|
#endif /* MBEDTLS_REMOVE_ARC4_CIPHERSUITES */
|
||||||
|
#if defined(MBEDTLS_REMOVE_3DES_CIPHERSUITES)
|
||||||
|
"MBEDTLS_REMOVE_3DES_CIPHERSUITES",
|
||||||
|
#endif /* MBEDTLS_REMOVE_3DES_CIPHERSUITES */
|
||||||
#if defined(MBEDTLS_ECP_DP_SECP192R1_ENABLED)
|
#if defined(MBEDTLS_ECP_DP_SECP192R1_ENABLED)
|
||||||
"MBEDTLS_ECP_DP_SECP192R1_ENABLED",
|
"MBEDTLS_ECP_DP_SECP192R1_ENABLED",
|
||||||
#endif /* MBEDTLS_ECP_DP_SECP192R1_ENABLED */
|
#endif /* MBEDTLS_ECP_DP_SECP192R1_ENABLED */
|
||||||
@ -354,6 +363,39 @@ static const char * const features[] = {
|
|||||||
#if defined(MBEDTLS_ECDSA_DETERMINISTIC)
|
#if defined(MBEDTLS_ECDSA_DETERMINISTIC)
|
||||||
"MBEDTLS_ECDSA_DETERMINISTIC",
|
"MBEDTLS_ECDSA_DETERMINISTIC",
|
||||||
#endif /* MBEDTLS_ECDSA_DETERMINISTIC */
|
#endif /* MBEDTLS_ECDSA_DETERMINISTIC */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_PSK_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_PSK_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_PSK_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_RSA_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_RSA_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED */
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED)
|
||||||
|
"MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED",
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED */
|
||||||
#if defined(MBEDTLS_PK_PARSE_EC_EXTENDED)
|
#if defined(MBEDTLS_PK_PARSE_EC_EXTENDED)
|
||||||
"MBEDTLS_PK_PARSE_EC_EXTENDED",
|
"MBEDTLS_PK_PARSE_EC_EXTENDED",
|
||||||
#endif /* MBEDTLS_PK_PARSE_EC_EXTENDED */
|
#endif /* MBEDTLS_PK_PARSE_EC_EXTENDED */
|
||||||
@ -417,6 +459,90 @@ static const char * const features[] = {
|
|||||||
#if defined(MBEDTLS_SHA512_NO_SHA384)
|
#if defined(MBEDTLS_SHA512_NO_SHA384)
|
||||||
"MBEDTLS_SHA512_NO_SHA384",
|
"MBEDTLS_SHA512_NO_SHA384",
|
||||||
#endif /* MBEDTLS_SHA512_NO_SHA384 */
|
#endif /* MBEDTLS_SHA512_NO_SHA384 */
|
||||||
|
#if defined(MBEDTLS_SSL_ALL_ALERT_MESSAGES)
|
||||||
|
"MBEDTLS_SSL_ALL_ALERT_MESSAGES",
|
||||||
|
#endif /* MBEDTLS_SSL_ALL_ALERT_MESSAGES */
|
||||||
|
#if defined(MBEDTLS_SSL_ASYNC_PRIVATE)
|
||||||
|
"MBEDTLS_SSL_ASYNC_PRIVATE",
|
||||||
|
#endif /* MBEDTLS_SSL_ASYNC_PRIVATE */
|
||||||
|
#if defined(MBEDTLS_SSL_DEBUG_ALL)
|
||||||
|
"MBEDTLS_SSL_DEBUG_ALL",
|
||||||
|
#endif /* MBEDTLS_SSL_DEBUG_ALL */
|
||||||
|
#if defined(MBEDTLS_SSL_ENCRYPT_THEN_MAC)
|
||||||
|
"MBEDTLS_SSL_ENCRYPT_THEN_MAC",
|
||||||
|
#endif /* MBEDTLS_SSL_ENCRYPT_THEN_MAC */
|
||||||
|
#if defined(MBEDTLS_SSL_EXTENDED_MASTER_SECRET)
|
||||||
|
"MBEDTLS_SSL_EXTENDED_MASTER_SECRET",
|
||||||
|
#endif /* MBEDTLS_SSL_EXTENDED_MASTER_SECRET */
|
||||||
|
#if defined(MBEDTLS_SSL_FALLBACK_SCSV)
|
||||||
|
"MBEDTLS_SSL_FALLBACK_SCSV",
|
||||||
|
#endif /* MBEDTLS_SSL_FALLBACK_SCSV */
|
||||||
|
#if defined(MBEDTLS_SSL_KEEP_PEER_CERTIFICATE)
|
||||||
|
"MBEDTLS_SSL_KEEP_PEER_CERTIFICATE",
|
||||||
|
#endif /* MBEDTLS_SSL_KEEP_PEER_CERTIFICATE */
|
||||||
|
#if defined(MBEDTLS_SSL_HW_RECORD_ACCEL)
|
||||||
|
"MBEDTLS_SSL_HW_RECORD_ACCEL",
|
||||||
|
#endif /* MBEDTLS_SSL_HW_RECORD_ACCEL */
|
||||||
|
#if defined(MBEDTLS_SSL_CBC_RECORD_SPLITTING)
|
||||||
|
"MBEDTLS_SSL_CBC_RECORD_SPLITTING",
|
||||||
|
#endif /* MBEDTLS_SSL_CBC_RECORD_SPLITTING */
|
||||||
|
#if defined(MBEDTLS_SSL_RENEGOTIATION)
|
||||||
|
"MBEDTLS_SSL_RENEGOTIATION",
|
||||||
|
#endif /* MBEDTLS_SSL_RENEGOTIATION */
|
||||||
|
#if defined(MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO)
|
||||||
|
"MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO",
|
||||||
|
#endif /* MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO */
|
||||||
|
#if defined(MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE)
|
||||||
|
"MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE",
|
||||||
|
#endif /* MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE */
|
||||||
|
#if defined(MBEDTLS_SSL_MAX_FRAGMENT_LENGTH)
|
||||||
|
"MBEDTLS_SSL_MAX_FRAGMENT_LENGTH",
|
||||||
|
#endif /* MBEDTLS_SSL_MAX_FRAGMENT_LENGTH */
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_SSL3)
|
||||||
|
"MBEDTLS_SSL_PROTO_SSL3",
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_SSL3 */
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1)
|
||||||
|
"MBEDTLS_SSL_PROTO_TLS1",
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_TLS1 */
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1_1)
|
||||||
|
"MBEDTLS_SSL_PROTO_TLS1_1",
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_TLS1_1 */
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
||||||
|
"MBEDTLS_SSL_PROTO_TLS1_2",
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_TLS1_2 */
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||||
|
"MBEDTLS_SSL_PROTO_DTLS",
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_DTLS */
|
||||||
|
#if defined(MBEDTLS_SSL_ALPN)
|
||||||
|
"MBEDTLS_SSL_ALPN",
|
||||||
|
#endif /* MBEDTLS_SSL_ALPN */
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_ANTI_REPLAY)
|
||||||
|
"MBEDTLS_SSL_DTLS_ANTI_REPLAY",
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_ANTI_REPLAY */
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_HELLO_VERIFY)
|
||||||
|
"MBEDTLS_SSL_DTLS_HELLO_VERIFY",
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_HELLO_VERIFY */
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE)
|
||||||
|
"MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE",
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE */
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_BADMAC_LIMIT)
|
||||||
|
"MBEDTLS_SSL_DTLS_BADMAC_LIMIT",
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_BADMAC_LIMIT */
|
||||||
|
#if defined(MBEDTLS_SSL_SESSION_TICKETS)
|
||||||
|
"MBEDTLS_SSL_SESSION_TICKETS",
|
||||||
|
#endif /* MBEDTLS_SSL_SESSION_TICKETS */
|
||||||
|
#if defined(MBEDTLS_SSL_EXPORT_KEYS)
|
||||||
|
"MBEDTLS_SSL_EXPORT_KEYS",
|
||||||
|
#endif /* MBEDTLS_SSL_EXPORT_KEYS */
|
||||||
|
#if defined(MBEDTLS_SSL_SERVER_NAME_INDICATION)
|
||||||
|
"MBEDTLS_SSL_SERVER_NAME_INDICATION",
|
||||||
|
#endif /* MBEDTLS_SSL_SERVER_NAME_INDICATION */
|
||||||
|
#if defined(MBEDTLS_SSL_TRUNCATED_HMAC)
|
||||||
|
"MBEDTLS_SSL_TRUNCATED_HMAC",
|
||||||
|
#endif /* MBEDTLS_SSL_TRUNCATED_HMAC */
|
||||||
|
#if defined(MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT)
|
||||||
|
"MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT",
|
||||||
|
#endif /* MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT */
|
||||||
#if defined(MBEDTLS_THREADING_ALT)
|
#if defined(MBEDTLS_THREADING_ALT)
|
||||||
"MBEDTLS_THREADING_ALT",
|
"MBEDTLS_THREADING_ALT",
|
||||||
#endif /* MBEDTLS_THREADING_ALT */
|
#endif /* MBEDTLS_THREADING_ALT */
|
||||||
@ -447,6 +573,9 @@ static const char * const features[] = {
|
|||||||
#if defined(MBEDTLS_X509_RSASSA_PSS_SUPPORT)
|
#if defined(MBEDTLS_X509_RSASSA_PSS_SUPPORT)
|
||||||
"MBEDTLS_X509_RSASSA_PSS_SUPPORT",
|
"MBEDTLS_X509_RSASSA_PSS_SUPPORT",
|
||||||
#endif /* MBEDTLS_X509_RSASSA_PSS_SUPPORT */
|
#endif /* MBEDTLS_X509_RSASSA_PSS_SUPPORT */
|
||||||
|
#if defined(MBEDTLS_ZLIB_SUPPORT)
|
||||||
|
"MBEDTLS_ZLIB_SUPPORT",
|
||||||
|
#endif /* MBEDTLS_ZLIB_SUPPORT */
|
||||||
#if defined(MBEDTLS_AESNI_C)
|
#if defined(MBEDTLS_AESNI_C)
|
||||||
"MBEDTLS_AESNI_C",
|
"MBEDTLS_AESNI_C",
|
||||||
#endif /* MBEDTLS_AESNI_C */
|
#endif /* MBEDTLS_AESNI_C */
|
||||||
@ -498,6 +627,9 @@ static const char * const features[] = {
|
|||||||
#if defined(MBEDTLS_CTR_DRBG_C)
|
#if defined(MBEDTLS_CTR_DRBG_C)
|
||||||
"MBEDTLS_CTR_DRBG_C",
|
"MBEDTLS_CTR_DRBG_C",
|
||||||
#endif /* MBEDTLS_CTR_DRBG_C */
|
#endif /* MBEDTLS_CTR_DRBG_C */
|
||||||
|
#if defined(MBEDTLS_DEBUG_C)
|
||||||
|
"MBEDTLS_DEBUG_C",
|
||||||
|
#endif /* MBEDTLS_DEBUG_C */
|
||||||
#if defined(MBEDTLS_DES_C)
|
#if defined(MBEDTLS_DES_C)
|
||||||
"MBEDTLS_DES_C",
|
"MBEDTLS_DES_C",
|
||||||
#endif /* MBEDTLS_DES_C */
|
#endif /* MBEDTLS_DES_C */
|
||||||
@ -552,6 +684,9 @@ static const char * const features[] = {
|
|||||||
#if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C)
|
#if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C)
|
||||||
"MBEDTLS_MEMORY_BUFFER_ALLOC_C",
|
"MBEDTLS_MEMORY_BUFFER_ALLOC_C",
|
||||||
#endif /* MBEDTLS_MEMORY_BUFFER_ALLOC_C */
|
#endif /* MBEDTLS_MEMORY_BUFFER_ALLOC_C */
|
||||||
|
#if defined(MBEDTLS_NET_C)
|
||||||
|
"MBEDTLS_NET_C",
|
||||||
|
#endif /* MBEDTLS_NET_C */
|
||||||
#if defined(MBEDTLS_OID_C)
|
#if defined(MBEDTLS_OID_C)
|
||||||
"MBEDTLS_OID_C",
|
"MBEDTLS_OID_C",
|
||||||
#endif /* MBEDTLS_OID_C */
|
#endif /* MBEDTLS_OID_C */
|
||||||
@ -615,6 +750,24 @@ static const char * const features[] = {
|
|||||||
#if defined(MBEDTLS_SHA512_C)
|
#if defined(MBEDTLS_SHA512_C)
|
||||||
"MBEDTLS_SHA512_C",
|
"MBEDTLS_SHA512_C",
|
||||||
#endif /* MBEDTLS_SHA512_C */
|
#endif /* MBEDTLS_SHA512_C */
|
||||||
|
#if defined(MBEDTLS_SSL_CACHE_C)
|
||||||
|
"MBEDTLS_SSL_CACHE_C",
|
||||||
|
#endif /* MBEDTLS_SSL_CACHE_C */
|
||||||
|
#if defined(MBEDTLS_SSL_COOKIE_C)
|
||||||
|
"MBEDTLS_SSL_COOKIE_C",
|
||||||
|
#endif /* MBEDTLS_SSL_COOKIE_C */
|
||||||
|
#if defined(MBEDTLS_SSL_TICKET_C)
|
||||||
|
"MBEDTLS_SSL_TICKET_C",
|
||||||
|
#endif /* MBEDTLS_SSL_TICKET_C */
|
||||||
|
#if defined(MBEDTLS_SSL_CLI_C)
|
||||||
|
"MBEDTLS_SSL_CLI_C",
|
||||||
|
#endif /* MBEDTLS_SSL_CLI_C */
|
||||||
|
#if defined(MBEDTLS_SSL_SRV_C)
|
||||||
|
"MBEDTLS_SSL_SRV_C",
|
||||||
|
#endif /* MBEDTLS_SSL_SRV_C */
|
||||||
|
#if defined(MBEDTLS_SSL_TLS_C)
|
||||||
|
"MBEDTLS_SSL_TLS_C",
|
||||||
|
#endif /* MBEDTLS_SSL_TLS_C */
|
||||||
#if defined(MBEDTLS_THREADING_C)
|
#if defined(MBEDTLS_THREADING_C)
|
||||||
"MBEDTLS_THREADING_C",
|
"MBEDTLS_THREADING_C",
|
||||||
#endif /* MBEDTLS_THREADING_C */
|
#endif /* MBEDTLS_THREADING_C */
|
||||||
|
@ -850,6 +850,30 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_CTR_DRBG_USE_128_BIT_KEY */
|
#endif /* MBEDTLS_CTR_DRBG_USE_128_BIT_KEY */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_ENABLE_WEAK_CIPHERSUITES)
|
||||||
|
if( strcmp( "MBEDTLS_ENABLE_WEAK_CIPHERSUITES", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_ENABLE_WEAK_CIPHERSUITES );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_ENABLE_WEAK_CIPHERSUITES */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_REMOVE_ARC4_CIPHERSUITES)
|
||||||
|
if( strcmp( "MBEDTLS_REMOVE_ARC4_CIPHERSUITES", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_REMOVE_ARC4_CIPHERSUITES );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_REMOVE_ARC4_CIPHERSUITES */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_REMOVE_3DES_CIPHERSUITES)
|
||||||
|
if( strcmp( "MBEDTLS_REMOVE_3DES_CIPHERSUITES", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_REMOVE_3DES_CIPHERSUITES );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_REMOVE_3DES_CIPHERSUITES */
|
||||||
|
|
||||||
#if defined(MBEDTLS_ECP_DP_SECP192R1_ENABLED)
|
#if defined(MBEDTLS_ECP_DP_SECP192R1_ENABLED)
|
||||||
if( strcmp( "MBEDTLS_ECP_DP_SECP192R1_ENABLED", config ) == 0 )
|
if( strcmp( "MBEDTLS_ECP_DP_SECP192R1_ENABLED", config ) == 0 )
|
||||||
{
|
{
|
||||||
@ -986,6 +1010,94 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_ECDSA_DETERMINISTIC */
|
#endif /* MBEDTLS_ECDSA_DETERMINISTIC */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_PSK_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_PSK_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_PSK_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_PSK_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_RSA_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_RSA_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_RSA_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED)
|
||||||
|
if( strcmp( "MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED */
|
||||||
|
|
||||||
#if defined(MBEDTLS_PK_PARSE_EC_EXTENDED)
|
#if defined(MBEDTLS_PK_PARSE_EC_EXTENDED)
|
||||||
if( strcmp( "MBEDTLS_PK_PARSE_EC_EXTENDED", config ) == 0 )
|
if( strcmp( "MBEDTLS_PK_PARSE_EC_EXTENDED", config ) == 0 )
|
||||||
{
|
{
|
||||||
@ -1154,6 +1266,230 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_SHA512_NO_SHA384 */
|
#endif /* MBEDTLS_SHA512_NO_SHA384 */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_ALL_ALERT_MESSAGES)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_ALL_ALERT_MESSAGES", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_ALL_ALERT_MESSAGES );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_ALL_ALERT_MESSAGES */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_ASYNC_PRIVATE)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_ASYNC_PRIVATE", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_ASYNC_PRIVATE );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_ASYNC_PRIVATE */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DEBUG_ALL)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_DEBUG_ALL", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_DEBUG_ALL );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_DEBUG_ALL */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_ENCRYPT_THEN_MAC)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_ENCRYPT_THEN_MAC", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_ENCRYPT_THEN_MAC );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_ENCRYPT_THEN_MAC */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_EXTENDED_MASTER_SECRET)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_EXTENDED_MASTER_SECRET", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_EXTENDED_MASTER_SECRET );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_EXTENDED_MASTER_SECRET */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_FALLBACK_SCSV)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_FALLBACK_SCSV", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_FALLBACK_SCSV );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_FALLBACK_SCSV */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_KEEP_PEER_CERTIFICATE)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_KEEP_PEER_CERTIFICATE", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_KEEP_PEER_CERTIFICATE );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_KEEP_PEER_CERTIFICATE */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_HW_RECORD_ACCEL)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_HW_RECORD_ACCEL", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_HW_RECORD_ACCEL );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_HW_RECORD_ACCEL */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_CBC_RECORD_SPLITTING)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_CBC_RECORD_SPLITTING", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_CBC_RECORD_SPLITTING );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_CBC_RECORD_SPLITTING */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_RENEGOTIATION)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_RENEGOTIATION", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_RENEGOTIATION );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_RENEGOTIATION */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_SRV_RESPECT_CLIENT_PREFERENCE */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_MAX_FRAGMENT_LENGTH)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_MAX_FRAGMENT_LENGTH", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_MAX_FRAGMENT_LENGTH );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_MAX_FRAGMENT_LENGTH */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_SSL3)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_PROTO_SSL3", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_PROTO_SSL3 );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_SSL3 */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_PROTO_TLS1", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_PROTO_TLS1 );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_TLS1 */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1_1)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_PROTO_TLS1_1", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_PROTO_TLS1_1 );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_TLS1_1 */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_PROTO_TLS1_2", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_PROTO_TLS1_2 );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_TLS1_2 */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_PROTO_DTLS", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_PROTO_DTLS );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_PROTO_DTLS */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_ALPN)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_ALPN", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_ALPN );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_ALPN */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_ANTI_REPLAY)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_DTLS_ANTI_REPLAY", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_DTLS_ANTI_REPLAY );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_ANTI_REPLAY */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_HELLO_VERIFY)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_DTLS_HELLO_VERIFY", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_DTLS_HELLO_VERIFY );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_HELLO_VERIFY */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_BADMAC_LIMIT)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_DTLS_BADMAC_LIMIT", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_DTLS_BADMAC_LIMIT );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_BADMAC_LIMIT */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_SESSION_TICKETS)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_SESSION_TICKETS", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_SESSION_TICKETS );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_SESSION_TICKETS */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_EXPORT_KEYS)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_EXPORT_KEYS", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_EXPORT_KEYS );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_EXPORT_KEYS */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_SERVER_NAME_INDICATION)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_SERVER_NAME_INDICATION", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_SERVER_NAME_INDICATION );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_SERVER_NAME_INDICATION */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TRUNCATED_HMAC)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_TRUNCATED_HMAC", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_TRUNCATED_HMAC );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_TRUNCATED_HMAC */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_TRUNCATED_HMAC_COMPAT */
|
||||||
|
|
||||||
#if defined(MBEDTLS_THREADING_ALT)
|
#if defined(MBEDTLS_THREADING_ALT)
|
||||||
if( strcmp( "MBEDTLS_THREADING_ALT", config ) == 0 )
|
if( strcmp( "MBEDTLS_THREADING_ALT", config ) == 0 )
|
||||||
{
|
{
|
||||||
@ -1234,6 +1570,14 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_X509_RSASSA_PSS_SUPPORT */
|
#endif /* MBEDTLS_X509_RSASSA_PSS_SUPPORT */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_ZLIB_SUPPORT)
|
||||||
|
if( strcmp( "MBEDTLS_ZLIB_SUPPORT", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_ZLIB_SUPPORT );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_ZLIB_SUPPORT */
|
||||||
|
|
||||||
#if defined(MBEDTLS_AESNI_C)
|
#if defined(MBEDTLS_AESNI_C)
|
||||||
if( strcmp( "MBEDTLS_AESNI_C", config ) == 0 )
|
if( strcmp( "MBEDTLS_AESNI_C", config ) == 0 )
|
||||||
{
|
{
|
||||||
@ -1370,6 +1714,14 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_CTR_DRBG_C */
|
#endif /* MBEDTLS_CTR_DRBG_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_DEBUG_C)
|
||||||
|
if( strcmp( "MBEDTLS_DEBUG_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_DEBUG_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_DEBUG_C */
|
||||||
|
|
||||||
#if defined(MBEDTLS_DES_C)
|
#if defined(MBEDTLS_DES_C)
|
||||||
if( strcmp( "MBEDTLS_DES_C", config ) == 0 )
|
if( strcmp( "MBEDTLS_DES_C", config ) == 0 )
|
||||||
{
|
{
|
||||||
@ -1514,6 +1866,14 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_MEMORY_BUFFER_ALLOC_C */
|
#endif /* MBEDTLS_MEMORY_BUFFER_ALLOC_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_NET_C)
|
||||||
|
if( strcmp( "MBEDTLS_NET_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_NET_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_NET_C */
|
||||||
|
|
||||||
#if defined(MBEDTLS_OID_C)
|
#if defined(MBEDTLS_OID_C)
|
||||||
if( strcmp( "MBEDTLS_OID_C", config ) == 0 )
|
if( strcmp( "MBEDTLS_OID_C", config ) == 0 )
|
||||||
{
|
{
|
||||||
@ -1682,6 +2042,54 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_SHA512_C */
|
#endif /* MBEDTLS_SHA512_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_CACHE_C)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_CACHE_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_CACHE_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_CACHE_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_COOKIE_C)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_COOKIE_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_COOKIE_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_COOKIE_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TICKET_C)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_TICKET_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_TICKET_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_TICKET_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_CLI_C)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_CLI_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_CLI_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_CLI_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_SRV_C)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_SRV_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_SRV_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_SRV_C */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_TLS_C)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_TLS_C", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_TLS_C );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_TLS_C */
|
||||||
|
|
||||||
#if defined(MBEDTLS_THREADING_C)
|
#if defined(MBEDTLS_THREADING_C)
|
||||||
if( strcmp( "MBEDTLS_THREADING_C", config ) == 0 )
|
if( strcmp( "MBEDTLS_THREADING_C", config ) == 0 )
|
||||||
{
|
{
|
||||||
@ -2106,6 +2514,110 @@ int query_config( const char *config )
|
|||||||
}
|
}
|
||||||
#endif /* MBEDTLS_PLATFORM_NV_SEED_WRITE_MACRO */
|
#endif /* MBEDTLS_PLATFORM_NV_SEED_WRITE_MACRO */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_CACHE_DEFAULT_TIMEOUT)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_CACHE_DEFAULT_TIMEOUT", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_CACHE_DEFAULT_TIMEOUT );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_CACHE_DEFAULT_TIMEOUT */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_CACHE_DEFAULT_MAX_ENTRIES)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_CACHE_DEFAULT_MAX_ENTRIES", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_CACHE_DEFAULT_MAX_ENTRIES );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_CACHE_DEFAULT_MAX_ENTRIES */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_MAX_CONTENT_LEN)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_MAX_CONTENT_LEN", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_MAX_CONTENT_LEN );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_MAX_CONTENT_LEN */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_IN_CONTENT_LEN)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_IN_CONTENT_LEN", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_IN_CONTENT_LEN );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_IN_CONTENT_LEN */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_OUT_CONTENT_LEN)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_OUT_CONTENT_LEN", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_OUT_CONTENT_LEN );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_OUT_CONTENT_LEN */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DTLS_MAX_BUFFERING)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_DTLS_MAX_BUFFERING", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_DTLS_MAX_BUFFERING );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_DTLS_MAX_BUFFERING */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_DEFAULT_TICKET_LIFETIME)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_DEFAULT_TICKET_LIFETIME", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_DEFAULT_TICKET_LIFETIME );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_DEFAULT_TICKET_LIFETIME */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_PSK_MAX_LEN)
|
||||||
|
if( strcmp( "MBEDTLS_PSK_MAX_LEN", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_PSK_MAX_LEN );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_PSK_MAX_LEN */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_SSL_COOKIE_TIMEOUT)
|
||||||
|
if( strcmp( "MBEDTLS_SSL_COOKIE_TIMEOUT", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_SSL_COOKIE_TIMEOUT );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_SSL_COOKIE_TIMEOUT */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_X509_MAX_INTERMEDIATE_CA)
|
||||||
|
if( strcmp( "MBEDTLS_X509_MAX_INTERMEDIATE_CA", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_X509_MAX_INTERMEDIATE_CA );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_X509_MAX_INTERMEDIATE_CA */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_X509_MAX_FILE_PATH_LEN)
|
||||||
|
if( strcmp( "MBEDTLS_X509_MAX_FILE_PATH_LEN", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_X509_MAX_FILE_PATH_LEN );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_X509_MAX_FILE_PATH_LEN */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_CERTIFICATES)
|
||||||
|
if( strcmp( "MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_CERTIFICATES", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_CERTIFICATES );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_CERTIFICATES */
|
||||||
|
|
||||||
|
#if defined(MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_KEY_EXCHANGE)
|
||||||
|
if( strcmp( "MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_KEY_EXCHANGE", config ) == 0 )
|
||||||
|
{
|
||||||
|
MACRO_EXPANSION_TO_STR( MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_KEY_EXCHANGE );
|
||||||
|
return( 0 );
|
||||||
|
}
|
||||||
|
#endif /* MBEDTLS_TLS_DEFAULT_ALLOW_SHA1_IN_KEY_EXCHANGE */
|
||||||
|
|
||||||
#if defined(MBEDTLS_PLATFORM_ZEROIZE_ALT)
|
#if defined(MBEDTLS_PLATFORM_ZEROIZE_ALT)
|
||||||
if( strcmp( "MBEDTLS_PLATFORM_ZEROIZE_ALT", config ) == 0 )
|
if( strcmp( "MBEDTLS_PLATFORM_ZEROIZE_ALT", config ) == 0 )
|
||||||
{
|
{
|
||||||
|
@ -183,11 +183,15 @@ def include_in_full(name):
|
|||||||
'MBEDTLS_PSA_CRYPTO_SE_C',
|
'MBEDTLS_PSA_CRYPTO_SE_C',
|
||||||
'MBEDTLS_PSA_CRYPTO_SPM',
|
'MBEDTLS_PSA_CRYPTO_SPM',
|
||||||
'MBEDTLS_PSA_INJECT_ENTROPY',
|
'MBEDTLS_PSA_INJECT_ENTROPY',
|
||||||
|
'MBEDTLS_REMOVE_ARC4_CIPHERSUITES',
|
||||||
|
'MBEDTLS_REMOVE_3DES_CIPHERSUITES',
|
||||||
|
'MBEDTLS_SSL_HW_RECORD_ACCEL',
|
||||||
'MBEDTLS_RSA_NO_CRT',
|
'MBEDTLS_RSA_NO_CRT',
|
||||||
'MBEDTLS_SHA512_NO_SHA384',
|
'MBEDTLS_SHA512_NO_SHA384',
|
||||||
'MBEDTLS_TEST_NULL_ENTROPY',
|
'MBEDTLS_TEST_NULL_ENTROPY',
|
||||||
'MBEDTLS_X509_ALLOW_EXTENSIONS_NON_V3',
|
'MBEDTLS_X509_ALLOW_EXTENSIONS_NON_V3',
|
||||||
'MBEDTLS_X509_ALLOW_UNSUPPORTED_CRITICAL_EXTENSION',
|
'MBEDTLS_X509_ALLOW_UNSUPPORTED_CRITICAL_EXTENSION',
|
||||||
|
'MBEDTLS_ZLIB_SUPPORT',
|
||||||
]:
|
]:
|
||||||
return False
|
return False
|
||||||
if name.endswith('_ALT'):
|
if name.endswith('_ALT'):
|
||||||
@ -209,6 +213,7 @@ def keep_in_baremetal(name):
|
|||||||
'MBEDTLS_HAVEGE_C',
|
'MBEDTLS_HAVEGE_C',
|
||||||
'MBEDTLS_HAVE_TIME',
|
'MBEDTLS_HAVE_TIME',
|
||||||
'MBEDTLS_HAVE_TIME_DATE',
|
'MBEDTLS_HAVE_TIME_DATE',
|
||||||
|
'MBEDTLS_NET_C',
|
||||||
'MBEDTLS_PLATFORM_FPRINTF_ALT',
|
'MBEDTLS_PLATFORM_FPRINTF_ALT',
|
||||||
'MBEDTLS_PLATFORM_TIME_ALT',
|
'MBEDTLS_PLATFORM_TIME_ALT',
|
||||||
'MBEDTLS_PSA_CRYPTO_SE_C',
|
'MBEDTLS_PSA_CRYPTO_SE_C',
|
||||||
|
@ -62,6 +62,7 @@ doit()
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
{
|
{
|
||||||
|
scripts/config.py unset MBEDTLS_NET_C || true
|
||||||
scripts/config.py unset MBEDTLS_TIMING_C || true
|
scripts/config.py unset MBEDTLS_TIMING_C || true
|
||||||
scripts/config.py unset MBEDTLS_FS_IO || true
|
scripts/config.py unset MBEDTLS_FS_IO || true
|
||||||
scripts/config.py --force set MBEDTLS_NO_PLATFORM_ENTROPY || true
|
scripts/config.py --force set MBEDTLS_NO_PLATFORM_ENTROPY || true
|
||||||
|
@ -805,6 +805,7 @@ component_test_no_platform () {
|
|||||||
msg "build: full config except platform/fsio/net, make, gcc, C99" # ~ 30s
|
msg "build: full config except platform/fsio/net, make, gcc, C99" # ~ 30s
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset MBEDTLS_PLATFORM_C
|
scripts/config.py unset MBEDTLS_PLATFORM_C
|
||||||
|
scripts/config.py unset MBEDTLS_NET_C
|
||||||
scripts/config.py unset MBEDTLS_PLATFORM_MEMORY
|
scripts/config.py unset MBEDTLS_PLATFORM_MEMORY
|
||||||
scripts/config.py unset MBEDTLS_PLATFORM_PRINTF_ALT
|
scripts/config.py unset MBEDTLS_PLATFORM_PRINTF_ALT
|
||||||
scripts/config.py unset MBEDTLS_PLATFORM_FPRINTF_ALT
|
scripts/config.py unset MBEDTLS_PLATFORM_FPRINTF_ALT
|
||||||
|
@ -35,14 +35,26 @@ my $config_h = 'include/mbedtls/config.h';
|
|||||||
# Some algorithms can't be disabled on their own as others depend on them, so
|
# Some algorithms can't be disabled on their own as others depend on them, so
|
||||||
# we list those reverse-dependencies here to keep check_config.h happy.
|
# we list those reverse-dependencies here to keep check_config.h happy.
|
||||||
my %algs = (
|
my %algs = (
|
||||||
'MBEDTLS_ECDSA_C' => [],
|
'MBEDTLS_ECDSA_C' => ['MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED'],
|
||||||
'MBEDTLS_ECP_C' => ['MBEDTLS_ECDSA_C',
|
'MBEDTLS_ECP_C' => ['MBEDTLS_ECDSA_C',
|
||||||
'MBEDTLS_ECDH_C',
|
'MBEDTLS_ECDH_C',
|
||||||
'MBEDTLS_ECJPAKE_C'],
|
'MBEDTLS_ECJPAKE_C',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED'],
|
||||||
'MBEDTLS_X509_RSASSA_PSS_SUPPORT' => [],
|
'MBEDTLS_X509_RSASSA_PSS_SUPPORT' => [],
|
||||||
'MBEDTLS_PKCS1_V21' => ['MBEDTLS_X509_RSASSA_PSS_SUPPORT'],
|
'MBEDTLS_PKCS1_V21' => ['MBEDTLS_X509_RSASSA_PSS_SUPPORT'],
|
||||||
'MBEDTLS_PKCS1_V15' => [],
|
'MBEDTLS_PKCS1_V15' => ['MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED',
|
||||||
'MBEDTLS_RSA_C' => ['MBEDTLS_X509_RSASSA_PSS_SUPPORT'],
|
'MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_RSA_ENABLED'],
|
||||||
|
'MBEDTLS_RSA_C' => ['MBEDTLS_X509_RSASSA_PSS_SUPPORT',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED',
|
||||||
|
'MBEDTLS_KEY_EXCHANGE_RSA_ENABLED'],
|
||||||
);
|
);
|
||||||
|
|
||||||
system( "cp $config_h $config_h.bak" ) and die;
|
system( "cp $config_h $config_h.bak" ) and die;
|
||||||
|
Loading…
Reference in New Issue
Block a user