mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-29 11:41:15 +03:00
Revert "Add pk_rsa_set_padding() and rsa_set_padding()"
This reverts commit b4fae579e8
.
Conflicts:
library/pk.c
tests/suites/test_suite_pk.data
tests/suites/test_suite_pk.function
This commit is contained in:
16
library/pk.c
16
library/pk.c
@ -108,22 +108,6 @@ int pk_init_ctx( pk_context *ctx, const pk_info_t *info )
|
||||
return( 0 );
|
||||
}
|
||||
|
||||
#if defined(POLARSSL_RSA_C)
|
||||
/*
|
||||
* Set RSA padding
|
||||
*/
|
||||
int pk_rsa_set_padding( pk_context *ctx, int padding, int hash_id )
|
||||
{
|
||||
if( ctx == NULL || ctx->pk_info == NULL ||
|
||||
ctx->pk_info->type != POLARSSL_PK_RSA )
|
||||
return( POLARSSL_ERR_PK_BAD_INPUT_DATA );
|
||||
|
||||
rsa_set_padding( pk_rsa( *ctx ), padding, hash_id );
|
||||
|
||||
return( 0 );
|
||||
}
|
||||
#endif /* POLARSSL_RSA_C */
|
||||
|
||||
/*
|
||||
* Initialize an RSA-alt context
|
||||
*/
|
||||
|
@ -60,17 +60,6 @@ void rsa_init( rsa_context *ctx,
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* Set padding method after initialisation
|
||||
*/
|
||||
void rsa_set_padding( rsa_context *ctx,
|
||||
int padding,
|
||||
int hash_id)
|
||||
{
|
||||
ctx->padding = padding;
|
||||
ctx->hash_id = hash_id;
|
||||
}
|
||||
|
||||
#if defined(POLARSSL_GENPRIME)
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user