diff options
author | Kevin Steves <stevesk@pobox.com> | 2002-03-22 20:43:05 +0000 |
---|---|---|
committer | Kevin Steves <stevesk@pobox.com> | 2002-03-22 20:43:05 +0000 |
commit | 205cc1ef461d0c6996dc3757e52e229b5053274b (patch) | |
tree | e587c1178897b898957ae39e0357008322563778 | |
parent | 1adb12077974ba849984df5fd81e3c1bca327a25 (diff) |
- (stevesk) [auth2.c] merge cleanup/sync
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | auth2.c | 8 |
2 files changed, 5 insertions, 6 deletions
@@ -4,6 +4,7 @@ | |||
4 | - (stevesk) configure and cpp __FUNCTION__ gymnastics to handle nielsisms | 4 | - (stevesk) configure and cpp __FUNCTION__ gymnastics to handle nielsisms |
5 | - (stevesk) [monitor_fdpass.c] support for access rights style file | 5 | - (stevesk) [monitor_fdpass.c] support for access rights style file |
6 | descriptor passing | 6 | descriptor passing |
7 | - (stevesk) [auth2.c] merge cleanup/sync | ||
7 | 8 | ||
8 | 20020321 | 9 | 20020321 |
9 | - (bal) OpenBSD CVS Sync | 10 | - (bal) OpenBSD CVS Sync |
@@ -7998,4 +7999,4 @@ | |||
7998 | - Wrote replacements for strlcpy and mkdtemp | 7999 | - Wrote replacements for strlcpy and mkdtemp |
7999 | - Released 1.0pre1 | 8000 | - Released 1.0pre1 |
8000 | 8001 | ||
8001 | $Id: ChangeLog,v 1.1970 2002/03/22 19:32:53 stevesk Exp $ | 8002 | $Id: ChangeLog,v 1.1971 2002/03/22 20:43:05 stevesk Exp $ |
@@ -184,14 +184,12 @@ input_userauth_request(int type, u_int32_t seq, void *ctxt) | |||
184 | 184 | ||
185 | if (authctxt->attempt++ == 0) { | 185 | if (authctxt->attempt++ == 0) { |
186 | /* setup auth context */ | 186 | /* setup auth context */ |
187 | struct passwd *pw = NULL; | 187 | authctxt->pw = PRIVSEP(getpwnamallow(user)); |
188 | pw = PRIVSEP(getpwnamallow(user)); | 188 | if (authctxt->pw && strcmp(service, "ssh-connection")==0) { |
189 | if (pw && strcmp(service, "ssh-connection")==0) { | ||
190 | authctxt->pw = pwcopy(pw); | ||
191 | authctxt->valid = 1; | 189 | authctxt->valid = 1; |
192 | debug2("input_userauth_request: setting up authctxt for %s", user); | 190 | debug2("input_userauth_request: setting up authctxt for %s", user); |
193 | #ifdef USE_PAM | 191 | #ifdef USE_PAM |
194 | start_pam(pw->pw_name); | 192 | start_pam(authctxt->pw->pw_name); |
195 | #endif | 193 | #endif |
196 | } else { | 194 | } else { |
197 | log("input_userauth_request: illegal user %s", user); | 195 | log("input_userauth_request: illegal user %s", user); |