Skip to content

Commit d8f0b37

Browse files
committed
ssl: replace remaining occurrence of pk_can_do with pk_get_key_type
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
1 parent 9eb5b2a commit d8f0b37

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/ssl_tls.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8782,7 +8782,7 @@ int mbedtls_ssl_verify_certificate(mbedtls_ssl_context *ssl,
87828782
#if defined(MBEDTLS_SSL_PROTO_TLS1_2) && \
87838783
defined(PSA_WANT_KEY_TYPE_ECC_PUBLIC_KEY)
87848784
if (ssl->tls_version == MBEDTLS_SSL_VERSION_TLS1_2 &&
8785-
mbedtls_pk_can_do(&chain->pk, MBEDTLS_PK_ECKEY)) {
8785+
PSA_KEY_TYPE_IS_ECC(mbedtls_pk_get_type(&chain->pk))) {
87868786
if (mbedtls_ssl_check_curve(ssl, mbedtls_pk_get_ec_group_id(&chain->pk)) != 0) {
87878787
MBEDTLS_SSL_DEBUG_MSG(1, ("bad certificate (EC key curve)"));
87888788
ssl->session_negotiate->verify_result |= MBEDTLS_X509_BADCERT_BAD_KEY;

0 commit comments

Comments
 (0)