mirror of
https://github.com/polhenarejos/pico-keys-sdk
synced 2026-05-28 09:01:24 +02:00
Use ecp keypair calc public instead.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
@@ -883,7 +883,7 @@ void rest_check_and_load_credentials(void) {
|
||||
if (ret != 0) goto out;
|
||||
mbedtls_ecp_read_key(MBEDTLS_ECP_DP_SECP256R1, mbedtls_pk_ec(key), file, file_len);
|
||||
mbedtls_ecp_check_privkey(&mbedtls_pk_ec(key)->grp, &mbedtls_pk_ec(key)->d);
|
||||
mbedtls_ecp_mul(&mbedtls_pk_ec(key)->grp, &mbedtls_pk_ec(key)->Q, &mbedtls_pk_ec(key)->d, &mbedtls_pk_ec(key)->grp.G, random_fill_iterator, NULL);
|
||||
mbedtls_ecp_keypair_calc_public(&mbedtls_pk_ec(key), random_fill_iterator, NULL);
|
||||
mbedtls_ecp_check_pubkey(&mbedtls_pk_ec(key)->grp, &mbedtls_pk_ec(key)->Q);
|
||||
|
||||
mbedtls_x509write_crt_set_md_alg(&crt, MBEDTLS_MD_SHA256);
|
||||
|
||||
Reference in New Issue
Block a user