mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-12-24 17:41:01 +03:00
- Added const-correctness to main codebase
This commit is contained in:
@@ -192,7 +192,7 @@ int rsa_gen_key( rsa_context *ctx, int nbits, int exponent );
|
||||
*
|
||||
* \return 0 if successful, or an POLARSSL_ERR_RSA_XXX error code
|
||||
*/
|
||||
int rsa_check_pubkey( rsa_context *ctx );
|
||||
int rsa_check_pubkey( const rsa_context *ctx );
|
||||
|
||||
/**
|
||||
* \brief Check a private RSA key
|
||||
@@ -201,7 +201,7 @@ int rsa_check_pubkey( rsa_context *ctx );
|
||||
*
|
||||
* \return 0 if successful, or an POLARSSL_ERR_RSA_XXX error code
|
||||
*/
|
||||
int rsa_check_privkey( rsa_context *ctx );
|
||||
int rsa_check_privkey( const rsa_context *ctx );
|
||||
|
||||
/**
|
||||
* \brief Do an RSA public key operation
|
||||
@@ -220,7 +220,7 @@ int rsa_check_privkey( rsa_context *ctx );
|
||||
* enough (eg. 128 bytes if RSA-1024 is used).
|
||||
*/
|
||||
int rsa_public( rsa_context *ctx,
|
||||
unsigned char *input,
|
||||
const unsigned char *input,
|
||||
unsigned char *output );
|
||||
|
||||
/**
|
||||
@@ -236,7 +236,7 @@ int rsa_public( rsa_context *ctx,
|
||||
* enough (eg. 128 bytes if RSA-1024 is used).
|
||||
*/
|
||||
int rsa_private( rsa_context *ctx,
|
||||
unsigned char *input,
|
||||
const unsigned char *input,
|
||||
unsigned char *output );
|
||||
|
||||
/**
|
||||
@@ -255,7 +255,7 @@ int rsa_private( rsa_context *ctx,
|
||||
*/
|
||||
int rsa_pkcs1_encrypt( rsa_context *ctx,
|
||||
int mode, int ilen,
|
||||
unsigned char *input,
|
||||
const unsigned char *input,
|
||||
unsigned char *output );
|
||||
|
||||
/**
|
||||
@@ -276,7 +276,7 @@ int rsa_pkcs1_encrypt( rsa_context *ctx,
|
||||
*/
|
||||
int rsa_pkcs1_decrypt( rsa_context *ctx,
|
||||
int mode, int *olen,
|
||||
unsigned char *input,
|
||||
const unsigned char *input,
|
||||
unsigned char *output,
|
||||
int output_max_len );
|
||||
|
||||
@@ -300,7 +300,7 @@ int rsa_pkcs1_sign( rsa_context *ctx,
|
||||
int mode,
|
||||
int hash_id,
|
||||
int hashlen,
|
||||
unsigned char *hash,
|
||||
const unsigned char *hash,
|
||||
unsigned char *sig );
|
||||
|
||||
/**
|
||||
@@ -323,7 +323,7 @@ int rsa_pkcs1_verify( rsa_context *ctx,
|
||||
int mode,
|
||||
int hash_id,
|
||||
int hashlen,
|
||||
unsigned char *hash,
|
||||
const unsigned char *hash,
|
||||
unsigned char *sig );
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user