Re: RSA_generate_key KEY_LENGTH

2013-01-17 Thread Pankracy
Annie pisze:
 On 14.01.2013 22:55, Dave Thompson wrote:
 
   
 Yes, but. By default (i.e. not using an engine, which 
 may impose limits) you can generate an RSA keypair of 
 practically any size you like.
 

 Hi Dave, you can try, but ...
 OpenSSL will give you not always the keysize back that you requested ;-)
 try e.g.

 openssl genrsa 1

 OpenSSL returns not a 1-bit key, but

 -BEGIN RSA PRIVATE KEY-
 MCQCAQACAwEYTgIDAQABAgJMawIDAIwnAgECAgJMawIBAAICRhQ=
 -END RSA PRIVATE KEY-

 which is a 17-bit key with even(!) modulus.

 Regards,
 Ann.
   
if I use 1024*3 length of key I get different size?
On Key_gen not openssl comand line
__
OpenSSL Project http://www.openssl.org
Development Mailing List   openssl-dev@openssl.org
Automated List Manager   majord...@openssl.org


RSA_generate_key KEY_LENGTH

2013-01-13 Thread Pankracy
How long is key_length (int) in RSA_generate_key ?
Can I put here a 1000,1001,1002 etc or
(1024*3) or other values?

I use if(RSA_check_key (keypair) = 0) with key_length 50 and I can't
get any error. This is possible?
__
OpenSSL Project http://www.openssl.org
Development Mailing List   openssl-dev@openssl.org
Automated List Manager   majord...@openssl.org