Blame openssh-5.8p1-sftpcontext.patch
|
Jan F |
8fe150 |
diff -up openssh-5.8p1/session.c.sftpcontext openssh-5.8p1/session.c
|
|
Jan F |
8bc65c |
--- openssh-5.8p1/session.c.sftpcontext 2011-04-05 19:46:53.674654050 +0200
|
|
Jan F |
8bc65c |
+++ openssh-5.8p1/session.c 2011-04-05 19:48:32.942658237 +0200
|
|
Jan F |
8bc65c |
@@ -1520,6 +1520,10 @@ do_setusercontext(struct passwd *pw)
|
|
Jan F |
8bc65c |
free(chroot_path);
|
|
Jan F |
8bc65c |
}
|
|
Jan F |
8bc65c |
|
|
Jan F |
8fe150 |
+#ifdef WITH_SELINUX
|
|
Jan F |
8bc65c |
+ ssh_selinux_change_context("sshd_sftpd_t");
|
|
Jan F |
8fe150 |
+#endif
|
|
Jan F |
8bc65c |
+
|
|
Jan F |
8bc65c |
#ifdef HAVE_LOGIN_CAP
|
|
Jan F |
8bc65c |
if (setusercontext(lc, pw, pw->pw_uid, LOGIN_SETUSER) < 0) {
|
|
Jan F |
8bc65c |
perror("unable to set user context (setuser)");
|