mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-12-06 12:00:59 +03:00
Merge pull request #10523 from mpg/rm-ecdh
Remove some useless private includes
This commit is contained in:
@@ -11,7 +11,9 @@
|
|||||||
#define MBEDTLS_ERROR_H
|
#define MBEDTLS_ERROR_H
|
||||||
|
|
||||||
#include "mbedtls/build_info.h"
|
#include "mbedtls/build_info.h"
|
||||||
#include "mbedtls/private/error_common.h"
|
#include "mbedtls/private/error_common.h" // for MBEDTLS_ERROR_ADD + see below
|
||||||
|
// MBEDTLS_ERR_PLATFORM_HW_ACCEL_FAILED
|
||||||
|
// MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED
|
||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
|
||||||
|
|||||||
@@ -14,9 +14,6 @@
|
|||||||
|
|
||||||
#include "mbedtls/build_info.h"
|
#include "mbedtls/build_info.h"
|
||||||
|
|
||||||
#include "mbedtls/private/bignum.h"
|
|
||||||
#include "mbedtls/private/ecp.h"
|
|
||||||
|
|
||||||
#include "mbedtls/ssl_ciphersuites.h"
|
#include "mbedtls/ssl_ciphersuites.h"
|
||||||
|
|
||||||
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||||
@@ -26,10 +23,6 @@
|
|||||||
|
|
||||||
#include "mbedtls/md.h"
|
#include "mbedtls/md.h"
|
||||||
|
|
||||||
#if defined(MBEDTLS_KEY_EXCHANGE_SOME_ECDH_OR_ECDHE_ANY_ENABLED)
|
|
||||||
#include "mbedtls/private/ecdh.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(MBEDTLS_HAVE_TIME)
|
#if defined(MBEDTLS_HAVE_TIME)
|
||||||
#include "mbedtls/platform_time.h"
|
#include "mbedtls/platform_time.h"
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -14,7 +14,6 @@
|
|||||||
#include "mbedtls/build_info.h"
|
#include "mbedtls/build_info.h"
|
||||||
|
|
||||||
#include "mbedtls/pk.h"
|
#include "mbedtls/pk.h"
|
||||||
#include "mbedtls/private/cipher.h"
|
|
||||||
#include "mbedtls/md.h"
|
#include "mbedtls/md.h"
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
|||||||
@@ -15,7 +15,6 @@
|
|||||||
|
|
||||||
#include "mbedtls/x509.h"
|
#include "mbedtls/x509.h"
|
||||||
#include "mbedtls/x509_crl.h"
|
#include "mbedtls/x509_crl.h"
|
||||||
#include "mbedtls/private/bignum.h"
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \addtogroup x509_module
|
* \addtogroup x509_module
|
||||||
|
|||||||
@@ -11,9 +11,6 @@
|
|||||||
#define MBEDTLS_SSL_CIPHERSUITES_INTERNAL_H
|
#define MBEDTLS_SSL_CIPHERSUITES_INTERNAL_H
|
||||||
|
|
||||||
#include "mbedtls/pk.h"
|
#include "mbedtls/pk.h"
|
||||||
#if defined(MBEDTLS_PK_HAVE_PRIVATE_HEADER)
|
|
||||||
#include <mbedtls/private/pk_private.h>
|
|
||||||
#endif /* MBEDTLS_PK_HAVE_PRIVATE_HEADER */
|
|
||||||
|
|
||||||
#if defined(MBEDTLS_PK_C)
|
#if defined(MBEDTLS_PK_C)
|
||||||
mbedtls_pk_sigalg_t mbedtls_ssl_get_ciphersuite_sig_pk_alg(const mbedtls_ssl_ciphersuite_t *info);
|
mbedtls_pk_sigalg_t mbedtls_ssl_get_ciphersuite_sig_pk_alg(const mbedtls_ssl_ciphersuite_t *info);
|
||||||
|
|||||||
@@ -19,35 +19,13 @@
|
|||||||
#include "mbedtls/debug.h"
|
#include "mbedtls/debug.h"
|
||||||
#include "debug_internal.h"
|
#include "debug_internal.h"
|
||||||
|
|
||||||
#include "mbedtls/private/cipher.h"
|
|
||||||
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
#include "psa_util_internal.h"
|
#include "psa_util_internal.h" // for mbedtls_error_pair_t, psa_status_to_mbedtls
|
||||||
extern const mbedtls_error_pair_t psa_to_ssl_errors[7];
|
extern const mbedtls_error_pair_t psa_to_ssl_errors[7];
|
||||||
|
|
||||||
#if defined(PSA_WANT_ALG_MD5)
|
|
||||||
#include "mbedtls/private/md5.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(PSA_WANT_ALG_SHA_1)
|
|
||||||
#include "mbedtls/private/sha1.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(PSA_WANT_ALG_SHA_256)
|
|
||||||
#include "mbedtls/private/sha256.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(PSA_WANT_ALG_SHA_512)
|
|
||||||
#include "mbedtls/private/sha512.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "mbedtls/pk.h"
|
#include "mbedtls/pk.h"
|
||||||
#if defined(MBEDTLS_PK_HAVE_PRIVATE_HEADER)
|
|
||||||
#include <mbedtls/private/pk_private.h>
|
|
||||||
#endif /* MBEDTLS_PK_HAVE_PRIVATE_HEADER */
|
|
||||||
#include "ssl_ciphersuites_internal.h"
|
#include "ssl_ciphersuites_internal.h"
|
||||||
#include "x509_internal.h"
|
#include "x509_internal.h"
|
||||||
#include "pk_internal.h"
|
|
||||||
|
|
||||||
/* Shorthand for restartable ECC */
|
/* Shorthand for restartable ECC */
|
||||||
#if defined(MBEDTLS_ECP_RESTARTABLE) && \
|
#if defined(MBEDTLS_ECP_RESTARTABLE) && \
|
||||||
|
|||||||
@@ -21,12 +21,11 @@
|
|||||||
#include "mbedtls/error.h"
|
#include "mbedtls/error.h"
|
||||||
#include "mbedtls/platform_util.h"
|
#include "mbedtls/platform_util.h"
|
||||||
#include "mbedtls/version.h"
|
#include "mbedtls/version.h"
|
||||||
#include "constant_time_internal.h"
|
#include "constant_time_internal.h" // for internal mbedtls_ct_xxx functions
|
||||||
#include "mbedtls/constant_time.h"
|
#include "mbedtls/constant_time.h"
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include "psa_util_internal.h"
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
|
|
||||||
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||||
|
|||||||
@@ -29,8 +29,7 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include "mbedtls/psa_util.h"
|
#include "mbedtls/psa_util.h"
|
||||||
#include "md_psa.h"
|
#include "md_psa.h" // for mbedtls_md_error_from_psa()
|
||||||
#include "psa_util_internal.h"
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
|
|
||||||
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||||
|
|||||||
@@ -17,7 +17,6 @@
|
|||||||
#include "mbedtls/error.h"
|
#include "mbedtls/error.h"
|
||||||
#include "mbedtls/constant_time.h"
|
#include "mbedtls/constant_time.h"
|
||||||
|
|
||||||
#include "psa_util_internal.h"
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED)
|
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED)
|
||||||
/* Define a local translating function to save code size by not using too many
|
/* Define a local translating function to save code size by not using too many
|
||||||
|
|||||||
@@ -15,7 +15,6 @@
|
|||||||
#include "debug_internal.h"
|
#include "debug_internal.h"
|
||||||
#include "mbedtls/error.h"
|
#include "mbedtls/error.h"
|
||||||
#include "mbedtls/platform_util.h"
|
#include "mbedtls/platform_util.h"
|
||||||
#include "constant_time_internal.h"
|
|
||||||
#include "mbedtls/constant_time.h"
|
#include "mbedtls/constant_time.h"
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
@@ -32,10 +31,6 @@ static int local_err_translation(psa_status_t status)
|
|||||||
#define PSA_TO_MBEDTLS_ERR(status) local_err_translation(status)
|
#define PSA_TO_MBEDTLS_ERR(status) local_err_translation(status)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(MBEDTLS_ECP_C)
|
|
||||||
#include "mbedtls/private/ecp.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(MBEDTLS_HAVE_TIME)
|
#if defined(MBEDTLS_HAVE_TIME)
|
||||||
#include "mbedtls/platform_time.h"
|
#include "mbedtls/platform_time.h"
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -24,7 +24,6 @@
|
|||||||
#include "ssl_debug_helpers.h"
|
#include "ssl_debug_helpers.h"
|
||||||
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
#include "psa_util_internal.h"
|
|
||||||
|
|
||||||
#if defined(MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_SOME_EPHEMERAL_ENABLED)
|
#if defined(MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_SOME_EPHEMERAL_ENABLED)
|
||||||
/* Define a local translating function to save code size by not using too many
|
/* Define a local translating function to save code size by not using too many
|
||||||
|
|||||||
@@ -35,9 +35,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
#include "psa_util_internal.h"
|
|
||||||
#include "mbedtls/psa_util.h"
|
#include "mbedtls/psa_util.h"
|
||||||
#include "pk_internal.h"
|
|
||||||
|
|
||||||
#include "mbedtls/platform.h"
|
#include "mbedtls/platform.h"
|
||||||
|
|
||||||
|
|||||||
@@ -16,11 +16,8 @@
|
|||||||
|
|
||||||
#include "mbedtls/x509.h"
|
#include "mbedtls/x509.h"
|
||||||
#include "mbedtls/asn1.h"
|
#include "mbedtls/asn1.h"
|
||||||
#include "pk_internal.h"
|
|
||||||
|
|
||||||
#if defined(MBEDTLS_RSA_C)
|
#include "pk_internal.h" // for a lot of things, including in SSL
|
||||||
#include "mbedtls/private/rsa.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int mbedtls_x509_get_name(unsigned char **p, const unsigned char *end,
|
int mbedtls_x509_get_name(unsigned char **p, const unsigned char *end,
|
||||||
mbedtls_x509_name *cur);
|
mbedtls_x509_name *cur);
|
||||||
|
|||||||
@@ -13,9 +13,6 @@
|
|||||||
|
|
||||||
#include "mbedtls/asn1.h"
|
#include "mbedtls/asn1.h"
|
||||||
#include "mbedtls/pk.h"
|
#include "mbedtls/pk.h"
|
||||||
#if defined(MBEDTLS_PK_HAVE_PRIVATE_HEADER)
|
|
||||||
#include <mbedtls/private/pk_private.h>
|
|
||||||
#endif /* MBEDTLS_PK_HAVE_PRIVATE_HEADER */
|
|
||||||
#include "mbedtls/x509.h"
|
#include "mbedtls/x509.h"
|
||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
|||||||
@@ -24,7 +24,6 @@
|
|||||||
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
#include "mbedtls/psa_util.h"
|
#include "mbedtls/psa_util.h"
|
||||||
#include "md_psa.h"
|
|
||||||
|
|
||||||
#define CHECK_OVERFLOW_ADD(a, b) \
|
#define CHECK_OVERFLOW_ADD(a, b) \
|
||||||
do \
|
do \
|
||||||
|
|||||||
@@ -32,7 +32,6 @@
|
|||||||
#endif /* MBEDTLS_PEM_WRITE_C */
|
#endif /* MBEDTLS_PEM_WRITE_C */
|
||||||
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
#include "psa_util_internal.h"
|
|
||||||
#include "mbedtls/psa_util.h"
|
#include "mbedtls/psa_util.h"
|
||||||
|
|
||||||
void mbedtls_x509write_crt_init(mbedtls_x509write_cert *ctx)
|
void mbedtls_x509write_crt_init(mbedtls_x509write_cert *ctx)
|
||||||
|
|||||||
@@ -22,7 +22,6 @@
|
|||||||
#include "mbedtls/platform_util.h"
|
#include "mbedtls/platform_util.h"
|
||||||
|
|
||||||
#include "psa/crypto.h"
|
#include "psa/crypto.h"
|
||||||
#include "psa_util_internal.h"
|
|
||||||
#include "mbedtls/psa_util.h"
|
#include "mbedtls/psa_util.h"
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|||||||
Reference in New Issue
Block a user