mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2025-01-24 23:41:10 +00:00
Improve psa_rsa_decode_md_type()
Remove a case that cannot be triggered as PSA_ALG_SIGN_GET_HASH always returns 0 for raw algorithms. Signed-off-by: Janos Follath <janos.follath@arm.com>
This commit is contained in:
parent
0e89dafbab
commit
03daae6894
|
@ -368,11 +368,6 @@ static psa_status_t psa_rsa_decode_md_type( psa_algorithm_t alg,
|
||||||
if( mbedtls_md_get_size( md_info ) != hash_length )
|
if( mbedtls_md_get_size( md_info ) != hash_length )
|
||||||
return( PSA_ERROR_INVALID_ARGUMENT );
|
return( PSA_ERROR_INVALID_ARGUMENT );
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
if( hash_alg != 0 )
|
|
||||||
return( PSA_ERROR_INVALID_ARGUMENT );
|
|
||||||
}
|
|
||||||
|
|
||||||
return( PSA_SUCCESS );
|
return( PSA_SUCCESS );
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue