From: Dr. Stephen Henson Date: Fri, 4 Mar 2016 23:28:45 +0000 (+0000) Subject: use saner default parameters for scrypt X-Git-Tag: OpenSSL_1_1_0-pre4~352 X-Git-Url: https://git.openssl.org/gitweb/?p=openssl.git;a=commitdiff_plain;h=5fc3ee4b77a6495a3544ce3192e71af0a9d74e08;ds=sidebyside use saner default parameters for scrypt Thanks to Colin Percival for reporting this issue. Reviewed-by: Rich Salz --- diff --git a/apps/pkcs8.c b/apps/pkcs8.c index 125bf6158a..0968fef946 100644 --- a/apps/pkcs8.c +++ b/apps/pkcs8.c @@ -203,9 +203,9 @@ int pkcs8_main(int argc, char **argv) break; #ifndef OPENSSL_NO_SCRYPT case OPT_SCRYPT: - scrypt_N = 1024; + scrypt_N = 16384; scrypt_r = 8; - scrypt_p = 16; + scrypt_p = 1; if (cipher == NULL) cipher = EVP_aes_256_cbc(); break; diff --git a/doc/apps/pkcs8.pod b/doc/apps/pkcs8.pod index ec9f1d14d5..f3b20ff4b1 100644 --- a/doc/apps/pkcs8.pod +++ b/doc/apps/pkcs8.pod @@ -156,7 +156,7 @@ for all available algorithms. =item B<-scrypt> uses the B algorithm for private key encryption using default -parameters: currently N=1024, r=8 and p=16 and AES in CBC mode with a 256 bit +parameters: currently N=16384, r=8 and p=1 and AES in CBC mode with a 256 bit key. These parameters can be modified using the B<-scrypt_N>, B<-scrypt_r>, B<-scrypt_p> and B<-v2> options.