mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-30 22:43:08 +03:00
Fix RSASSA-PSS example programs
This commit is contained in:
@ -58,14 +58,22 @@ void rsa_init( rsa_context *ctx,
|
||||
{
|
||||
memset( ctx, 0, sizeof( rsa_context ) );
|
||||
|
||||
ctx->padding = padding;
|
||||
ctx->hash_id = hash_id;
|
||||
rsa_set_padding( ctx, padding, hash_id );
|
||||
|
||||
#if defined(POLARSSL_THREADING_C)
|
||||
polarssl_mutex_init( &ctx->mutex );
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* Set padding for an existing RSA context
|
||||
*/
|
||||
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