Rename mbedtls_pk_signature_size to mbedtls_pk_get_signature_size

Add more descriptive comments and return value description
This commit is contained in:
Unknown
2018-02-06 03:20:30 -05:00
parent 60b25f0529
commit d0d0602ea5
4 changed files with 10 additions and 8 deletions

View File

@@ -475,7 +475,7 @@ int mbedtls_pk_sign( mbedtls_pk_context *ctx, mbedtls_md_type_t md_alg,
*
* \return Maximum size in bytes of a signature made with this key.
*/
size_t mbedtls_pk_signature_size( const mbedtls_pk_context *ctx );
size_t mbedtls_pk_get_signature_size( const mbedtls_pk_context *ctx );
/**
* \brief Decrypt message (including padding if relevant).

View File

@@ -120,9 +120,11 @@ struct mbedtls_pk_info_t
* usage restrictions into account. */
int (*can_do)( const void * ctx, mbedtls_pk_type_t type );
/** Signature size
/** Upper bound of the signature length
*
* mbedtls_pk_signature_size() returns this value.
* mbedtls_pk_get_signature_size() returns this value.
*
* In case of an error, or an unsupported key type, 0 should be returned.
*
* Opaque implementations may omit this method if they do not support
* signature. */