Fixup: Minor style corrections around use of TinyCrypt

This commit is contained in:
Hanno Becker 2019-08-20 13:04:30 +01:00
parent e8f1448306
commit ad353f289b
2 changed files with 10 additions and 5 deletions

View file

@ -552,10 +552,13 @@ static int uecc_eckey_verify_wrap( void *ctx, mbedtls_md_type_t md_alg,
((void) md_alg);
p = (unsigned char*) sig;
if( (ret = extract_ecdsa_sig( &p, sig + sig_len, signature, NUM_ECC_BYTES ) ) != 0 )
ret = extract_ecdsa_sig( &p, sig + sig_len, signature, NUM_ECC_BYTES );
if( ret != 0 )
return( ret );
if( (ret = uECC_verify( (uint8_t *) ctx, hash, (unsigned) hash_len, signature, uecc_curve ) ) != 0 )
ret = uECC_verify( (uint8_t *) ctx, hash,
(unsigned) hash_len, signature, uecc_curve );
if( ret != 0 )
return( MBEDTLS_ERR_PK_SIG_LEN_MISMATCH );
return( ret );