diff options
author | jdp <jdp@FreeBSD.org> | 1999-04-06 19:48:53 +0000 |
---|---|---|
committer | jdp <jdp@FreeBSD.org> | 1999-04-06 19:48:53 +0000 |
commit | 23908fa2e8fa0df30b1023cfed894f47a17cf936 (patch) | |
tree | f6e88d38179c4f10c880dc708ce0fa567a1c458b /lib/libpam/modules | |
parent | 477aac47c6143f4c1cbe16dff195daf26402d957 (diff) | |
download | FreeBSD-src-23908fa2e8fa0df30b1023cfed894f47a17cf936.zip FreeBSD-src-23908fa2e8fa0df30b1023cfed894f47a17cf936.tar.gz |
Fix bug that prevented accounts with empty passwords from logging
in.
Submitted by: Paul Traina <pst@juniper.net>
Diffstat (limited to 'lib/libpam/modules')
-rw-r--r-- | lib/libpam/modules/pam_unix/pam_unix.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libpam/modules/pam_unix/pam_unix.c b/lib/libpam/modules/pam_unix/pam_unix.c index f47ea55..b68a9d4 100644 --- a/lib/libpam/modules/pam_unix/pam_unix.c +++ b/lib/libpam/modules/pam_unix/pam_unix.c @@ -61,7 +61,7 @@ pam_sm_authenticate(pam_handle_t *pamh, int flags, int argc, return retval; if ((pwd = getpwnam(user)) != NULL) { encrypted = crypt(password, pwd->pw_passwd); - if (password[0] == '\0' && pwd->pw_passwd != '\0') + if (password[0] == '\0' && pwd->pw_passwd[0] != '\0') encrypted = ":"; retval = strcmp(encrypted, pwd->pw_passwd) == 0 ? |