summaryrefslogtreecommitdiff
path: root/auth2.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2003-08-25 13:08:49 +1000
committerDamien Miller <djm@mindrot.org>2003-08-25 13:08:49 +1000
commit1f499fd3688d034daf787859044ede73767b6141 (patch)
tree0fec594fff3ac5fb6cc4faab19924e047db10207 /auth2.c
parente41bba584737f028579961ddf6669b6a768e47e7 (diff)
downloadopenssh-git-1f499fd3688d034daf787859044ede73767b6141.tar.gz
- (djm) Bug #564: Perform PAM account checks for all authentications when
UsePAM=yes; ok dtucker
Diffstat (limited to 'auth2.c')
-rw-r--r--auth2.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/auth2.c b/auth2.c
index 639bf911..e6ec8ddc 100644
--- a/auth2.c
+++ b/auth2.c
@@ -213,6 +213,11 @@ userauth_finish(Authctxt *authctxt, int authenticated, char *method)
!auth_root_allowed(method))
authenticated = 0;
+#ifdef USE_PAM
+ if (options.use_pam && authenticated && !PRIVSEP(do_pam_account()))
+ authenticated = 0;
+#endif
+
#ifdef _UNICOS
if (authenticated && cray_access_denied(authctxt->user)) {
authenticated = 0;