summaryrefslogtreecommitdiff
path: root/session.c
diff options
context:
space:
mode:
Diffstat (limited to 'session.c')
-rw-r--r--session.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/session.c b/session.c
index 639405fec..e032de692 100644
--- a/session.c
+++ b/session.c
@@ -1551,6 +1551,10 @@ do_setusercontext(struct passwd *pw)
1551 } 1551 }
1552#endif /* HAVE_SETPCRED */ 1552#endif /* HAVE_SETPCRED */
1553 1553
1554#ifdef WITH_SELINUX
1555 ssh_selinux_setup_exec_context(pw->pw_name);
1556#endif
1557
1554 if (options.chroot_directory != NULL && 1558 if (options.chroot_directory != NULL &&
1555 strcasecmp(options.chroot_directory, "none") != 0) { 1559 strcasecmp(options.chroot_directory, "none") != 0) {
1556 tmp = tilde_expand_filename(options.chroot_directory, 1560 tmp = tilde_expand_filename(options.chroot_directory,
@@ -1575,10 +1579,6 @@ do_setusercontext(struct passwd *pw)
1575 1579
1576 if (getuid() != pw->pw_uid || geteuid() != pw->pw_uid) 1580 if (getuid() != pw->pw_uid || geteuid() != pw->pw_uid)
1577 fatal("Failed to set uids to %u.", (u_int) pw->pw_uid); 1581 fatal("Failed to set uids to %u.", (u_int) pw->pw_uid);
1578
1579#ifdef WITH_SELINUX
1580 ssh_selinux_setup_exec_context(pw->pw_name);
1581#endif
1582} 1582}
1583 1583
1584static void 1584static void