oops, that should not have been part of the previous commit

This commit is contained in:
sthen
2024-11-29 21:10:07 +00:00
parent 88c0873ae8
commit 2ec1a3c218
@@ -1,20 +1,12 @@
Index: conserver/group.c
--- conserver/group.c.orig
+++ conserver/group.c
@@ -753,9 +753,14 @@ CheckPass(char *pcUser, char *pcWord, FLAG empty_check
@@ -753,7 +753,7 @@ CheckPass(char *pcUser, char *pcWord, FLAG empty_check
struct spwd *spwd;
# endif
- if ((pwd = getpwnam(pcUser)) == (struct passwd *)0) {
- CONDDEBUG((1, "CheckPass(): getpwnam(%s): %s", pcUser,
+ if ((pwd = getpwnam_shadow(pcUser)) == (struct passwd *)0) {
+ CONDDEBUG((1, "CheckPass(): getpwnam_shadow(%s): %s", pcUser,
CONDDEBUG((1, "CheckPass(): getpwnam(%s): %s", pcUser,
strerror(errno)));
+ retval = AUTH_NOUSER;
+ goto finished_pass;
+ }
+ if (strcmp(pwd->pw_passwd, "*") == 0) {
+ CONDDEBUG((1, "CheckPass(): getpwnam_shadow(%s) did not return password hash; either the account's password is disabled, or _conserver is not in group _shadow", pcUser);
retval = AUTH_NOUSER;
goto finished_pass;
}