@@ -1339,6 +1339,10 @@ int mbedtls_ecp_read_key(mbedtls_ecp_group_id grp_id, mbedtls_ecp_keypair *key,
1339
1339
* See the description of the \p buflen parameter for
1340
1340
* how to calculate the nominal length.
1341
1341
*
1342
+ * \note If the private key was not set in \p key,
1343
+ * the output is unspecified. Future versions
1344
+ * may return an error in that case.
1345
+ *
1342
1346
* \param key The private key.
1343
1347
* \param buf The output buffer for containing the binary representation
1344
1348
* of the key.
@@ -1369,6 +1373,10 @@ int mbedtls_ecp_write_key(mbedtls_ecp_keypair *key,
1369
1373
/**
1370
1374
* \brief This function exports an elliptic curve public key.
1371
1375
*
1376
+ * \note If the public key was not set in \p key,
1377
+ * the output is unspecified. Future versions
1378
+ * may return an error in that case.
1379
+ *
1372
1380
* \param key The public key.
1373
1381
* \param format The point format. This must be either
1374
1382
* #MBEDTLS_ECP_PF_COMPRESSED or #MBEDTLS_ECP_PF_UNCOMPRESSED.
@@ -1451,6 +1459,10 @@ mbedtls_ecp_group_id mbedtls_ecp_keypair_get_group_id(
1451
1459
* Each of the output parameters can be a null pointer
1452
1460
* if you do not need that parameter.
1453
1461
*
1462
+ * \note If the private key or the public key was not set in \p key,
1463
+ * the corresponding output is unspecified. Future versions
1464
+ * may return an error in that case.
1465
+ *
1454
1466
* \param key The key pair to export from.
1455
1467
* \param grp Slot for exported ECP group.
1456
1468
* It must either be null or point to an initialized ECP group.
0 commit comments