X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Fcore%2Fexecute.c;h=d8452a666c490ae0b9cda8900fcbb839edd4644a;hp=129791294eea816d1f9e186b9dad22b76472a4f8;hb=3bb07b7680c543c982077ac075abe8badeb46ca1;hpb=8530dc4467691a893aa2e07319b18a84fec96cad diff --git a/src/core/execute.c b/src/core/execute.c index 129791294..d8452a666 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -83,7 +83,6 @@ #include "af-list.h" #include "mkdir.h" #include "apparmor-util.h" -#include "label.h" #ifdef HAVE_SECCOMP #include "seccomp-util.h" @@ -1730,22 +1729,6 @@ int exec_spawn(ExecCommand *command, goto fail_child; } } - - if (context->selinux_label_via_net && use_selinux()) { - _cleanup_free_ char *label = NULL; - - err = label_get_child_label(socket_fd, command->path, &label); - if (err < 0) { - r = EXIT_SELINUX_CONTEXT; - goto fail_child; - } - - err = setexeccon(label); - if (err < 0) { - r = EXIT_SELINUX_CONTEXT; - goto fail_child; - } - } #endif #ifdef HAVE_APPARMOR @@ -2129,8 +2112,7 @@ void exec_context_dump(ExecContext *c, FILE* f, const char *prefix) { "%sPrivateDevices: %s\n" "%sProtectHome: %s\n" "%sProtectSystem: %s\n" - "%sIgnoreSIGPIPE: %s\n" - "%sSELinuxLabelViaNet: %s\n", + "%sIgnoreSIGPIPE: %s\n", prefix, c->umask, prefix, c->working_directory ? c->working_directory : "/", prefix, c->root_directory ? c->root_directory : "/", @@ -2140,8 +2122,7 @@ void exec_context_dump(ExecContext *c, FILE* f, const char *prefix) { prefix, yes_no(c->private_devices), prefix, protect_home_to_string(c->protect_home), prefix, protect_system_to_string(c->protect_system), - prefix, yes_no(c->ignore_sigpipe), - prefix, yes_no(c->selinux_label_via_net)); + prefix, yes_no(c->ignore_sigpipe)); STRV_FOREACH(e, c->environment) fprintf(f, "%sEnvironment: %s\n", prefix, *e);