From: Peter Avalos Date: Wed, 11 Jul 2012 09:32:52 +0000 (-0700) Subject: pam_ssh: Fix segfault with SSH 1 keys. X-Git-Tag: v3.2.0~612 X-Git-Url: http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff_plain/9067f1156c0d79090899ba20bd32e0d450028e6e pam_ssh: Fix segfault with SSH 1 keys. Obtained-from: FreeBSD --- diff --git a/lib/pam_module/pam_ssh/pam_ssh.c b/lib/pam_module/pam_ssh/pam_ssh.c index 954fb32..70a8a9a 100644 --- a/lib/pam_module/pam_ssh/pam_ssh.c +++ b/lib/pam_module/pam_ssh/pam_ssh.c @@ -32,7 +32,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libpam/modules/pam_ssh/pam_ssh.c,v 1.49 2011/11/20 15:18:49 des Exp $ + * $FreeBSD: src/lib/libpam/modules/pam_ssh/pam_ssh.c,v 1.50 2012/05/26 17:03:45 des Exp $ */ #include @@ -111,7 +111,7 @@ pam_ssh_load_key(const char *dir, const char *kfn, const char *passphrase, * with an empty passphrase, and if the key is not encrypted, * accept only an empty passphrase. */ - key = key_load_private(fn, NULL, &comment); + key = key_load_private(fn, "", &comment); if (key != NULL && !(*passphrase == '\0' && nullok)) { key_free(key); return (NULL);