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

Changing "common.h" to "mbedcrypto_common.h" to avoid file-name collisions #38

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions 3rdparty/everest/library/Hacl_Curve25519_joined.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#define _DEFAULT_SOURCE
#endif

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED)

Expand All @@ -47,4 +47,3 @@
#include "kremlib/FStar_UInt64_FStar_UInt32_FStar_UInt16_FStar_UInt8.c"

#endif /* defined(MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED) */

3 changes: 1 addition & 2 deletions 3rdparty/everest/library/everest.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
* This file is part of Mbed TLS (https://tls.mbed.org).
*/

#include "common.h"
#include "mbedcrypto_common.h"

#include <string.h>

Expand Down Expand Up @@ -99,4 +99,3 @@ int mbedtls_everest_calc_secret( mbedtls_ecdh_context_everest *ctx, size_t *olen
}

#endif /* MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED */

2 changes: 1 addition & 1 deletion 3rdparty/everest/library/x25519.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
* This file is part of Mbed TLS (https://tls.mbed.org)
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ECDH_C) && defined(MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED)

Expand Down
2 changes: 1 addition & 1 deletion include/library/bignum_mod.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
#ifndef MBEDTLS_BIGNUM_MOD_H
#define MBEDTLS_BIGNUM_MOD_H

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C)
#include "mbedtls/bignum.h"
Expand Down
2 changes: 1 addition & 1 deletion include/library/constant_time_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#include <stddef.h>

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C)
#include "mbedtls/bignum.h"
Expand Down
2 changes: 1 addition & 1 deletion include/library/constant_time_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include <stdint.h>
#include <stddef.h>

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C)
#include "mbedtls/bignum.h"
Expand Down
2 changes: 1 addition & 1 deletion include/library/md_psa.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#ifndef MBEDTLS_MD_PSA_H
#define MBEDTLS_MD_PSA_H

#include "common.h"
#include "mbedcrypto_common.h"

#include "mbedtls/md.h"
#include "psa/crypto.h"
Expand Down
2 changes: 1 addition & 1 deletion include/library/psa_crypto_driver_wrappers.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@


/* BEGIN-common headers */
#include "common.h"
#include "mbedcrypto_common.h"
#include "psa_crypto_aead.h"
#include "psa_crypto_cipher.h"
#include "psa_crypto_core.h"
Expand Down
2 changes: 1 addition & 1 deletion include/library/psa_crypto_invasive.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include "psa/build_info.h"

#include "psa/crypto.h"
#include "common.h"
#include "mbedcrypto_common.h"

#include "mbedtls/entropy.h"

Expand Down
2 changes: 1 addition & 1 deletion library/aes.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* http://csrc.nist.gov/publications/fips/fips197/fips-197.pdf
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_AES_C)

Expand Down
2 changes: 1 addition & 1 deletion library/aesce.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
#endif /* defined(__clang__) && (__clang_major__ >= 4) */

#include <string.h>
#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_AESCE_C)

Expand Down
2 changes: 1 addition & 1 deletion library/aesce.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#define MBEDTLS_AESCE_H

#include "mbedtls/build_info.h"
#include "common.h"
#include "mbedcrypto_common.h"

#include "mbedtls/aes.h"

Expand Down
2 changes: 1 addition & 1 deletion library/aesni.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* [CLMUL-WP] https://www.intel.com/content/www/us/en/develop/download/intel-carry-less-multiplication-instruction-and-its-usage-for-computing-the-gcm-mode.html
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_AESNI_C)

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion library/aria.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* [2] https://tools.ietf.org/html/rfc5794
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ARIA_C)

Expand Down
2 changes: 1 addition & 1 deletion library/asn1parse.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ASN1_PARSE_C) || defined(MBEDTLS_X509_CREATE_C) || \
defined(MBEDTLS_PSA_UTIL_HAVE_ECDSA)
Expand Down
2 changes: 1 addition & 1 deletion library/asn1write.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ASN1_WRITE_C) || defined(MBEDTLS_X509_USE_C) || \
defined(MBEDTLS_PSA_UTIL_HAVE_ECDSA)
Expand Down
2 changes: 1 addition & 1 deletion library/base64.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

#include <limits.h>

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BASE64_C)

Expand Down
2 changes: 1 addition & 1 deletion library/base64_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#ifndef MBEDTLS_BASE64_INTERNAL
#define MBEDTLS_BASE64_INTERNAL

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_TEST_HOOKS)

Expand Down
2 changes: 1 addition & 1 deletion library/bignum.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
*
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C)

Expand Down
2 changes: 1 addition & 1 deletion library/bignum_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C)

Expand Down
2 changes: 1 addition & 1 deletion library/bignum_core.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
#ifndef MBEDTLS_BIGNUM_CORE_H
#define MBEDTLS_BIGNUM_CORE_H

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C)
#include "mbedtls/bignum.h"
Expand Down
2 changes: 1 addition & 1 deletion library/bignum_mod.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C) && defined(MBEDTLS_ECP_WITH_MPI_UINT)

Expand Down
2 changes: 1 addition & 1 deletion library/bignum_mod_raw.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C) && defined(MBEDTLS_ECP_WITH_MPI_UINT)

Expand Down
2 changes: 1 addition & 1 deletion library/bignum_mod_raw.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
#ifndef MBEDTLS_BIGNUM_MOD_RAW_H
#define MBEDTLS_BIGNUM_MOD_RAW_H

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BIGNUM_C)
#include "mbedtls/bignum.h"
Expand Down
2 changes: 1 addition & 1 deletion library/bignum_mod_raw_invasive.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#ifndef MBEDTLS_BIGNUM_MOD_RAW_INVASIVE_H
#define MBEDTLS_BIGNUM_MOD_RAW_INVASIVE_H

#include "common.h"
#include "mbedcrypto_common.h"
#include "mbedtls/bignum.h"
#include "bignum_mod.h"

Expand Down
2 changes: 1 addition & 1 deletion library/block_cipher.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_BLOCK_CIPHER_SOME_PSA)
#include "psa/crypto.h"
Expand Down
2 changes: 1 addition & 1 deletion library/camellia.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* http://info.isl.ntt.co.jp/crypt/eng/camellia/dl/01espec.pdf
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CAMELLIA_C)

Expand Down
2 changes: 1 addition & 1 deletion library/ccm.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* RFC 5116 "An Interface and Algorithms for Authenticated Encryption"
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CCM_C)

Expand Down
2 changes: 1 addition & 1 deletion library/chacha20.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CHACHA20_C)

Expand Down
2 changes: 1 addition & 1 deletion library/chachapoly.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Copyright The Mbed TLS Contributors
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/
#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CHACHAPOLY_C)

Expand Down
2 changes: 1 addition & 1 deletion library/cipher.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CIPHER_C)

Expand Down
2 changes: 1 addition & 1 deletion library/cipher_wrap.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CIPHER_C)

Expand Down
2 changes: 1 addition & 1 deletion library/cmac.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
*
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CMAC_C)

Expand Down
2 changes: 1 addition & 1 deletion library/constant_time.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#include <stdint.h>
#include <limits.h>

#include "common.h"
#include "mbedcrypto_common.h"
#include "constant_time_internal.h"
#include "mbedtls/constant_time.h"
#include "mbedtls/error.h"
Expand Down
2 changes: 1 addition & 1 deletion library/ctr.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#ifndef MBEDTLS_CTR_H
#define MBEDTLS_CTR_H

#include "common.h"
#include "mbedcrypto_common.h"

/**
* \brief Increment a big-endian 16-byte value.
Expand Down
2 changes: 1 addition & 1 deletion library/ctr_drbg.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-90r.pdf
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_CTR_DRBG_C)

Expand Down
2 changes: 1 addition & 1 deletion library/debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_DEBUG_C)

Expand Down
2 changes: 1 addition & 1 deletion library/des.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* http://csrc.nist.gov/publications/fips/fips46-3/fips46-3.pdf
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_DES_C)

Expand Down
2 changes: 1 addition & 1 deletion library/dhm.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_DHM_C)

Expand Down
2 changes: 1 addition & 1 deletion library/ecdh.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* RFC 4492
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ECDH_C)

Expand Down
2 changes: 1 addition & 1 deletion library/ecdsa.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* SEC1 https://www.secg.org/sec1-v2.pdf
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ECDSA_C)

Expand Down
2 changes: 1 addition & 1 deletion library/ecjpake.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* available to members of the Thread Group http://threadgroup.org/
*/

#include "common.h"
#include "mbedcrypto_common.h"

#if defined(MBEDTLS_ECJPAKE_C)

Expand Down
2 changes: 1 addition & 1 deletion library/ecp.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
* <http://eprint.iacr.org/2004/342.pdf>
*/

#include "common.h"
#include "mbedcrypto_common.h"

/**
* \brief Function level alternative implementation.
Expand Down
Loading