[BACK]Return to genrsa.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / openssl

Diff for /src/usr.bin/openssl/genrsa.c between version 1.15 and 1.16

version 1.15, 2019/07/14 03:30:46 version 1.16, 2019/07/16 12:50:30
Line 305 
Line 305 
                 goto err;                  goto err;
         }          }
   
         if ((numbits != NULL) && ((sscanf(numbits, "%d", &num) == 0) || (num < 0))) {          if ((numbits != NULL) &&
               ((sscanf(numbits, "%d", &num) == 0) || (num < 0))) {
                 genrsa_usage();                  genrsa_usage();
                 goto err;                  goto err;
         }          }
   
         if (!app_passwd(bio_err, NULL, genrsa_config.passargout, NULL, &passout)) {          if (!app_passwd(bio_err, NULL, genrsa_config.passargout, NULL,
               &passout)) {
                 BIO_printf(bio_err, "Error getting password\n");                  BIO_printf(bio_err, "Error getting password\n");
                 goto err;                  goto err;
         }          }
Line 330 
Line 332 
         if (!rsa)          if (!rsa)
                 goto err;                  goto err;
   
         if (!BN_set_word(bn, genrsa_config.f4) || !RSA_generate_key_ex(rsa, num, bn, &cb))          if (!BN_set_word(bn, genrsa_config.f4) ||
               !RSA_generate_key_ex(rsa, num, bn, &cb))
                 goto err;                  goto err;
   
         /*          /*
Line 350 
Line 353 
                 PW_CB_DATA cb_data;                  PW_CB_DATA cb_data;
                 cb_data.password = passout;                  cb_data.password = passout;
                 cb_data.prompt_info = genrsa_config.outfile;                  cb_data.prompt_info = genrsa_config.outfile;
                 if (!PEM_write_bio_RSAPrivateKey(out, rsa, genrsa_config.enc, NULL, 0,                  if (!PEM_write_bio_RSAPrivateKey(out, rsa, genrsa_config.enc,
                         password_callback, &cb_data))                      NULL, 0, password_callback, &cb_data))
                         goto err;                          goto err;
         }          }
   

Legend:
Removed from v.1.15  
changed lines
  Added in v.1.16