rsa_check_pubkey() now allows an E up to N
This commit is contained in:
parent
0f90d7d2b5
commit
24f37ccaed
3 changed files with 9 additions and 2 deletions
|
@ -168,7 +168,7 @@ int rsa_check_pubkey( const rsa_context *ctx )
|
|||
return( POLARSSL_ERR_RSA_KEY_CHECK_FAILED );
|
||||
|
||||
if( mpi_msb( &ctx->E ) < 2 ||
|
||||
mpi_msb( &ctx->E ) > 64 )
|
||||
mpi_cmp_mpi( &ctx->E, &ctx->N ) >= 0 )
|
||||
return( POLARSSL_ERR_RSA_KEY_CHECK_FAILED );
|
||||
|
||||
return( 0 );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue