mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2025-05-08 17:12:13 +00:00
Move PSA_PRE_1_0_KEY_DERIVATION to crypto_struct.h
We want to make the PRF context structure depend on this flag, but crypto_extra.h is included after crypto_struct.h and having the option at its original place would not affect crypto_struct.h.
This commit is contained in:
parent
083036af64
commit
e3e8166cdd
|
@ -224,16 +224,6 @@ void mbedtls_psa_get_stats( mbedtls_psa_stats_t *stats );
|
||||||
psa_status_t mbedtls_psa_inject_entropy(const unsigned char *seed,
|
psa_status_t mbedtls_psa_inject_entropy(const unsigned char *seed,
|
||||||
size_t seed_size);
|
size_t seed_size);
|
||||||
|
|
||||||
/*
|
|
||||||
* If this option is not turned on, then the function `psa_key_derivation()`
|
|
||||||
* is removed.
|
|
||||||
*
|
|
||||||
* The sole purpose of this option is to make the transition to the new API
|
|
||||||
* smoother. Once the transition is complete it can and should be removed
|
|
||||||
* along with the old API and its implementation.
|
|
||||||
*/
|
|
||||||
#define PSA_PRE_1_0_KEY_DERIVATION
|
|
||||||
|
|
||||||
#if defined(PSA_PRE_1_0_KEY_DERIVATION)
|
#if defined(PSA_PRE_1_0_KEY_DERIVATION)
|
||||||
/** Set up a key derivation operation.
|
/** Set up a key derivation operation.
|
||||||
*
|
*
|
||||||
|
|
|
@ -191,6 +191,17 @@ typedef struct
|
||||||
} psa_hkdf_key_derivation_t;
|
} psa_hkdf_key_derivation_t;
|
||||||
#endif /* MBEDTLS_MD_C */
|
#endif /* MBEDTLS_MD_C */
|
||||||
|
|
||||||
|
/*
|
||||||
|
* If this option is not turned on, then the function `psa_key_derivation()`
|
||||||
|
* is removed. And the new psa_tls12_prf_key_derivation_t context is used along
|
||||||
|
* with the corresponding new API.
|
||||||
|
*
|
||||||
|
* The sole purpose of this option is to make the transition to the new API
|
||||||
|
* smoother. Once the transition is complete it can and should be removed
|
||||||
|
* along with the old API and its implementation.
|
||||||
|
*/
|
||||||
|
#define PSA_PRE_1_0_KEY_DERIVATION
|
||||||
|
|
||||||
#if defined(MBEDTLS_MD_C)
|
#if defined(MBEDTLS_MD_C)
|
||||||
typedef struct psa_tls12_prf_key_derivation_s
|
typedef struct psa_tls12_prf_key_derivation_s
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue