mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-29 20:04:18 +01:00
Fixup: Rename mbedtls_uecc_pk -> mbedtls_pk_uecc
This is in line with the naming of the analogous function mbedtls_pk_ec used for legacy ECC PK contexts.
This commit is contained in:
parent
8cf2f5e466
commit
da77971ec8
@ -173,7 +173,7 @@ static inline mbedtls_rsa_context *mbedtls_pk_rsa( const mbedtls_pk_context pk )
|
|||||||
#endif /* MBEDTLS_RSA_C */
|
#endif /* MBEDTLS_RSA_C */
|
||||||
|
|
||||||
#if defined(MBEDTLS_USE_TINYCRYPT)
|
#if defined(MBEDTLS_USE_TINYCRYPT)
|
||||||
static inline mbedtls_uecc_keypair *mbedtls_uecc_pk( const mbedtls_pk_context pk )
|
static inline mbedtls_uecc_keypair *mbedtls_pk_uecc( const mbedtls_pk_context pk )
|
||||||
{
|
{
|
||||||
return( (mbedtls_uecc_keypair *) (pk).pk_ctx );
|
return( (mbedtls_uecc_keypair *) (pk).pk_ctx );
|
||||||
}
|
}
|
||||||
|
@ -1211,7 +1211,7 @@ static int pk_parse_key_pkcs8_unencrypted_der(
|
|||||||
if( pk_alg == MBEDTLS_PK_ECKEY )
|
if( pk_alg == MBEDTLS_PK_ECKEY )
|
||||||
{
|
{
|
||||||
if( ( ret = pk_use_ecparams( ¶ms ) ) != 0 ||
|
if( ( ret = pk_use_ecparams( ¶ms ) ) != 0 ||
|
||||||
( ret = pk_parse_key_sec1_der( mbedtls_uecc_pk( *pk ), p, len ) ) != 0)
|
( ret = pk_parse_key_sec1_der( mbedtls_pk_uecc( *pk ), p, len ) ) != 0)
|
||||||
{
|
{
|
||||||
return( ret );
|
return( ret );
|
||||||
}
|
}
|
||||||
@ -1433,7 +1433,7 @@ int mbedtls_pk_parse_key( mbedtls_pk_context *pk,
|
|||||||
|
|
||||||
#if defined(MBEDTLS_USE_TINYCRYPT)
|
#if defined(MBEDTLS_USE_TINYCRYPT)
|
||||||
if( ( ret = mbedtls_pk_setup( pk, pk_info ) ) != 0 ||
|
if( ( ret = mbedtls_pk_setup( pk, pk_info ) ) != 0 ||
|
||||||
( ret = pk_parse_key_sec1_der( mbedtls_uecc_pk( *pk ),
|
( ret = pk_parse_key_sec1_der( mbedtls_pk_uecc( *pk ),
|
||||||
pem.buf, pem.buflen ) ) != 0 )
|
pem.buf, pem.buflen ) ) != 0 )
|
||||||
#else /* MBEDTLS_USE_TINYCRYPT */
|
#else /* MBEDTLS_USE_TINYCRYPT */
|
||||||
if( ( ret = mbedtls_pk_setup( pk, pk_info ) ) != 0 ||
|
if( ( ret = mbedtls_pk_setup( pk, pk_info ) ) != 0 ||
|
||||||
@ -1563,7 +1563,7 @@ int mbedtls_pk_parse_key( mbedtls_pk_context *pk,
|
|||||||
#if defined(MBEDTLS_USE_TINYCRYPT)
|
#if defined(MBEDTLS_USE_TINYCRYPT)
|
||||||
pk_info = mbedtls_pk_info_from_type( MBEDTLS_PK_ECKEY );
|
pk_info = mbedtls_pk_info_from_type( MBEDTLS_PK_ECKEY );
|
||||||
if( mbedtls_pk_setup( pk, pk_info ) == 0 &&
|
if( mbedtls_pk_setup( pk, pk_info ) == 0 &&
|
||||||
pk_parse_key_sec1_der( mbedtls_uecc_pk( *pk),
|
pk_parse_key_sec1_der( mbedtls_pk_uecc( *pk),
|
||||||
key, keylen) == 0)
|
key, keylen) == 0)
|
||||||
{
|
{
|
||||||
return( 0 );
|
return( 0 );
|
||||||
|
Loading…
Reference in New Issue
Block a user