Blame openssh-5.8p1-sftpcontext.patch
|
Jan F |
8fe150 |
diff -up openssh-5.8p1/session.c.sftpcontext openssh-5.8p1/session.c
|
|
Jan F |
7f6509 |
--- openssh-5.8p1/session.c.sftpcontext 2011-04-01 11:22:26.988648474 +0200
|
|
Jan F |
7f6509 |
+++ openssh-5.8p1/session.c 2011-04-01 11:31:49.127665411 +0200
|
|
Jan F |
7f6509 |
@@ -831,6 +831,10 @@ do_exec(Session *s, const char *command)
|
|
Jan F |
7f6509 |
if (s->command != NULL)
|
|
Jan F |
7f6509 |
s->command_handle = PRIVSEP(audit_run_command(s->command));
|
|
Jan F |
7f6509 |
#endif
|
|
Jan F |
8fe150 |
+#ifdef WITH_SELINUX
|
|
Jan F |
7f6509 |
+debug(">>> %d:%d %s ~ %d", getuid(), geteuid(), s->command, IS_INTERNAL_SFTP(s->command));
|
|
Jan F |
7f6509 |
+// ssh_selinux_change_context("sftpd_t");
|
|
Jan F |
8fe150 |
+#endif
|
|
Jan F |
7f6509 |
if (s->ttyfd != -1)
|
|
Jan F |
7f6509 |
ret = do_exec_pty(s, command);
|
|
Jan F |
7f6509 |
else
|
|
Jan F |
7f6509 |
@@ -1780,9 +1784,6 @@ do_child(Session *s, const char *command
|
|
Jan F |
8fe150 |
argv[i] = NULL;
|
|
Jan F |
8fe150 |
optind = optreset = 1;
|
|
Jan F |
8fe150 |
__progname = argv[0];
|
|
Jan F |
8fe150 |
-#ifdef WITH_SELINUX
|
|
Jan F |
8fe150 |
- ssh_selinux_change_context("sftpd_t");
|
|
Jan F |
8fe150 |
-#endif
|
|
Jan F |
8fe150 |
exit(sftp_server_main(i, argv, s->pw));
|
|
Jan F |
8fe150 |
}
|
|
Jan F |
8fe150 |
|