From 2f51befc0f395527a1342d103791ccd365b2ddb5 Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Mon, 20 Apr 2009 08:42:42 +0000 Subject: [PATCH] Add functions without any passphrase. git-svn-id: svn+ssh://svn.berlios.de/svnroot/repos/libssh/trunk@565 7dcaeef0-15fb-0310-b436-a5af3365683c --- libssh/keyfiles.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/libssh/keyfiles.c b/libssh/keyfiles.c index fef78339..f66d4356 100644 --- a/libssh/keyfiles.c +++ b/libssh/keyfiles.c @@ -639,10 +639,7 @@ PRIVATE_KEY *privatekey_from_file(SSH_SESSION *session, const char *filename, valid = read_dsa_privatekey(file, &dsa, auth_cb, auth_ud, "Passphrase for private key:"); } else { /* authcb */ - /* FIXME implement simple passphrase function? */ - ssh_log(session, SSH_LOG_RARE, - "No passphrase or authtentication callback specified."); - return NULL; + valid = read_dsa_privatekey(file, &dsa, NULL, NULL, NULL); } /* authcb */ } else { /* passphrase */ valid = read_dsa_privatekey(file, &dsa, NULL, @@ -683,10 +680,7 @@ PRIVATE_KEY *privatekey_from_file(SSH_SESSION *session, const char *filename, valid = read_rsa_privatekey(file, &rsa, auth_cb, auth_ud, "Passphrase for private key:"); } else { /* authcb */ - /* FIXME implement simple passphrase function? */ - ssh_log(session, SSH_LOG_RARE, - "No passphrase or authtentication callback specified."); - return NULL; + valid = read_rsa_privatekey(file, &rsa, NULL, NULL, NULL); } /* authcb */ } else { /* passphrase */ valid = read_rsa_privatekey(file, &rsa, NULL,