version 1.77, 2015/01/14 20:05:27 |
version 1.78, 2015/11/15 22:26:49 |
|
|
{ |
{ |
BIGNUM *challenge; |
BIGNUM *challenge; |
Key *public, *private; |
Key *public, *private; |
char buf[300], *passphrase, *comment, *authfile; |
char buf[300], *passphrase = NULL, *comment, *authfile; |
int i, perm_ok = 1, type, quit; |
int i, perm_ok = 1, type, quit; |
|
|
public = options.identity_keys[idx]; |
public = options.identity_keys[idx]; |
|
|
debug2("no passphrase given, try next key"); |
debug2("no passphrase given, try next key"); |
quit = 1; |
quit = 1; |
} |
} |
explicit_bzero(passphrase, strlen(passphrase)); |
|
free(passphrase); |
|
if (private != NULL || quit) |
if (private != NULL || quit) |
break; |
break; |
debug2("bad passphrase given, try again..."); |
debug2("bad passphrase given, try again..."); |
} |
} |
} |
} |
|
|
|
if (private != NULL) |
|
maybe_add_key_to_agent(authfile, private, comment, passphrase); |
|
|
|
if (passphrase != NULL) { |
|
explicit_bzero(passphrase, strlen(passphrase)); |
|
free(passphrase); |
|
} |
|
|
/* We no longer need the comment. */ |
/* We no longer need the comment. */ |
free(comment); |
free(comment); |
|
|