Rename key_length in cipher_info
diff --git a/include/mbedtls/cipher.h b/include/mbedtls/cipher.h
index 46b82ca..9f42f0e 100644
--- a/include/mbedtls/cipher.h
+++ b/include/mbedtls/cipher.h
@@ -191,7 +191,7 @@
/** Cipher key length, in bits (default length for variable sized ciphers)
* (Includes parity bits for ciphers like DES) */
- unsigned int key_length;
+ unsigned int key_bitlen;
/** Name of the cipher */
const char * name;
@@ -219,7 +219,7 @@
const mbedtls_cipher_info_t *cipher_info;
/** Key length to use */
- int key_length;
+ int key_bitlen;
/** Operation that the context's key has been initialised for */
mbedtls_operation_t operation;
@@ -420,7 +420,7 @@
if( NULL == ctx || NULL == ctx->cipher_info )
return MBEDTLS_KEY_LENGTH_NONE;
- return ctx->cipher_info->key_length;
+ return ctx->cipher_info->key_bitlen;
}
/**
diff --git a/include/mbedtls/cipher_internal.h b/include/mbedtls/cipher_internal.h
index 9cab3bb..587e3ea 100644
--- a/include/mbedtls/cipher_internal.h
+++ b/include/mbedtls/cipher_internal.h
@@ -79,11 +79,11 @@
/** Set key for encryption purposes */
int (*setkey_enc_func)( void *ctx, const unsigned char *key,
- unsigned int key_length );
+ unsigned int key_bitlen );
/** Set key for decryption purposes */
int (*setkey_dec_func)( void *ctx, const unsigned char *key,
- unsigned int key_length);
+ unsigned int key_bitlen);
/** Allocate a new context */
void * (*ctx_alloc_func)( void );
diff --git a/include/mbedtls/pkcs5.h b/include/mbedtls/pkcs5.h
index 9bbdde6..cfd42a2 100644
--- a/include/mbedtls/pkcs5.h
+++ b/include/mbedtls/pkcs5.h
@@ -71,7 +71,7 @@
* \param salt Salt to use when generating key
* \param slen Length of salt
* \param iteration_count Iteration count
- * \param key_length Length of generated key
+ * \param key_length Length of generated key in bytes
* \param output Generated key. Must be at least as big as key_length
*
* \returns 0 on success, or a MBEDTLS_ERR_XXX code if verification fails.