]> andersk Git - openssh.git/blobdiff - session.c
- (dtucker) [auth-pam.c monitor.c session.c sshd.c] Bug #926: Move
[openssh.git] / session.c
index 3eba513de62d96a1afc1ee222d5f4b9ff545b795..f5eaa815caa980c8442f4e74f142198ee890acb6 100644 (file)
--- a/session.c
+++ b/session.c
@@ -428,11 +428,6 @@ do_exec_no_pty(Session *s, const char *command)
 
        session_proctitle(s);
 
-#if defined(USE_PAM)
-       if (options.use_pam && !use_privsep)
-               do_pam_setcred(1);
-#endif /* USE_PAM */
-
        /* Fork the child. */
        if ((pid = fork()) == 0) {
                is_child = 1;
@@ -563,14 +558,6 @@ do_exec_pty(Session *s, const char *command)
        ptyfd = s->ptyfd;
        ttyfd = s->ttyfd;
 
-#if defined(USE_PAM)
-       if (options.use_pam) {
-               do_pam_set_tty(s->tty);
-               if (!use_privsep)
-                       do_pam_setcred(1);
-       }
-#endif
-
        /* Fork the child. */
        if ((pid = fork()) == 0) {
                is_child = 1;
@@ -1373,16 +1360,8 @@ do_setusercontext(struct passwd *pw)
 # ifdef __bsdi__
                setpgid(0, 0);
 # endif
-#ifdef GSSAPI
-               if (options.gss_authentication) {
-                       temporarily_use_uid(pw);
-                       ssh_gssapi_storecreds();
-                       restore_uid();
-               }
-#endif
 # ifdef USE_PAM
                if (options.use_pam) {
-                       do_pam_session();
                        do_pam_setcred(use_privsep);
                }
 # endif /* USE_PAM */
@@ -1410,13 +1389,6 @@ do_setusercontext(struct passwd *pw)
                        exit(1);
                }
                endgrent();
-# ifdef GSSAPI
-               if (options.gss_authentication) {
-                       temporarily_use_uid(pw);
-                       ssh_gssapi_storecreds();
-                       restore_uid();
-               }
-# endif
 # ifdef USE_PAM
                /*
                 * PAM credentials may take the form of supplementary groups.
@@ -1424,7 +1396,6 @@ do_setusercontext(struct passwd *pw)
                 * Reestablish them here.
                 */
                if (options.use_pam) {
-                       do_pam_session();
                        do_pam_setcred(use_privsep);
                }
 # endif /* USE_PAM */
This page took 0.032362 seconds and 4 git commands to generate.