1a8e1175bSopenharmony_ci/** 2a8e1175bSopenharmony_ci * \file psa/crypto_adjust_config_synonyms.h 3a8e1175bSopenharmony_ci * \brief Adjust PSA configuration: enable quasi-synonyms 4a8e1175bSopenharmony_ci * 5a8e1175bSopenharmony_ci * When two features require almost the same code, we automatically enable 6a8e1175bSopenharmony_ci * both when either one is requested, to reduce the combinatorics of 7a8e1175bSopenharmony_ci * possible configurations. 8a8e1175bSopenharmony_ci */ 9a8e1175bSopenharmony_ci/* 10a8e1175bSopenharmony_ci * Copyright The Mbed TLS Contributors 11a8e1175bSopenharmony_ci * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 12a8e1175bSopenharmony_ci */ 13a8e1175bSopenharmony_ci 14a8e1175bSopenharmony_ci#ifndef PSA_CRYPTO_ADJUST_CONFIG_SYNONYMS_H 15a8e1175bSopenharmony_ci#define PSA_CRYPTO_ADJUST_CONFIG_SYNONYMS_H 16a8e1175bSopenharmony_ci 17a8e1175bSopenharmony_ci/****************************************************************/ 18a8e1175bSopenharmony_ci/* De facto synonyms */ 19a8e1175bSopenharmony_ci/****************************************************************/ 20a8e1175bSopenharmony_ci 21a8e1175bSopenharmony_ci#if defined(PSA_WANT_ALG_ECDSA_ANY) && !defined(PSA_WANT_ALG_ECDSA) 22a8e1175bSopenharmony_ci#define PSA_WANT_ALG_ECDSA PSA_WANT_ALG_ECDSA_ANY 23a8e1175bSopenharmony_ci#elif !defined(PSA_WANT_ALG_ECDSA_ANY) && defined(PSA_WANT_ALG_ECDSA) 24a8e1175bSopenharmony_ci#define PSA_WANT_ALG_ECDSA_ANY PSA_WANT_ALG_ECDSA 25a8e1175bSopenharmony_ci#endif 26a8e1175bSopenharmony_ci 27a8e1175bSopenharmony_ci#if defined(PSA_WANT_ALG_RSA_PKCS1V15_SIGN_RAW) && !defined(PSA_WANT_ALG_RSA_PKCS1V15_SIGN) 28a8e1175bSopenharmony_ci#define PSA_WANT_ALG_RSA_PKCS1V15_SIGN PSA_WANT_ALG_RSA_PKCS1V15_SIGN_RAW 29a8e1175bSopenharmony_ci#elif !defined(PSA_WANT_ALG_RSA_PKCS1V15_SIGN_RAW) && defined(PSA_WANT_ALG_RSA_PKCS1V15_SIGN) 30a8e1175bSopenharmony_ci#define PSA_WANT_ALG_RSA_PKCS1V15_SIGN_RAW PSA_WANT_ALG_RSA_PKCS1V15_SIGN 31a8e1175bSopenharmony_ci#endif 32a8e1175bSopenharmony_ci 33a8e1175bSopenharmony_ci#if defined(PSA_WANT_ALG_RSA_PSS_ANY_SALT) && !defined(PSA_WANT_ALG_RSA_PSS) 34a8e1175bSopenharmony_ci#define PSA_WANT_ALG_RSA_PSS PSA_WANT_ALG_RSA_PSS_ANY_SALT 35a8e1175bSopenharmony_ci#elif !defined(PSA_WANT_ALG_RSA_PSS_ANY_SALT) && defined(PSA_WANT_ALG_RSA_PSS) 36a8e1175bSopenharmony_ci#define PSA_WANT_ALG_RSA_PSS_ANY_SALT PSA_WANT_ALG_RSA_PSS 37a8e1175bSopenharmony_ci#endif 38a8e1175bSopenharmony_ci 39a8e1175bSopenharmony_ci#endif /* PSA_CRYPTO_ADJUST_CONFIG_SYNONYMS_H */ 40