I use Mbedtls_ecp_gen_keypair to generate a pair of public private keys, and use the Mbedtls_ecp_point_write_binary function (format=MBEDTLS_ECP_PF_COMPRESSED) derived the public key as: 0348F8DB4C4F1D76F7FF445B840BCA1194D53C7BBA1AE466ADAA2C592CDB7E3DBC, as the public key of the server;
When the client calculates the shared key, it prompts mbedtls_err_ecp_feature_unavailable when the server public key is imported using Mbedtls_ecp_point_read_binary;
Looking at the function implementation, you find that the following checks do not pass:
if (Buf!= 0x04)
See this API only supports the non-compressed format(fisrt byte is 0x04) not support compressed format(fisrt byte is 0x02 or 0x03) of the public key.
how to import this public key, thank you!