summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/crypt.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/crypt.c b/src/crypt.c
index e574d8551a..e802f98e9a 100644
--- a/src/crypt.c
+++ b/src/crypt.c
@@ -70,8 +70,10 @@ int crypt, salt;
salt = info.salt;
- if(info.crypt==NULL) crypt = SRPSHA1_CRYPT;
- else {
+ if(info.crypt==NULL) {
+ crypt = SRPSHA1_CRYPT;
+ salt = 16;
+ } else {
if (strcasecmp( info.crypt, "bcrypt")==0) {
crypt = BLOWFISH_CRYPT;
if (salt==0) salt = 6; /* cost is 6 */