service: Start services normally when seccomp is disabled
authorMichal Sojka <sojkam1@fel.cvut.cz>
Fri, 3 Nov 2017 21:31:41 +0000 (22:31 +0100)
committerJohn Crispin <john@phrozen.org>
Mon, 6 Nov 2017 07:33:08 +0000 (08:33 +0100)
commitb39c362c6d1c6a0515e12f14f808c6fc79d5ec2d
treee5dfcc989dc42b3b0ff2dcd7a149681406cebd88
parent3ba6b45c59b4f6df6ba16124ae41f0bb8cd47223
service: Start services normally when seccomp is disabled

When service init file declares seccomp support (procd_set_param seccomp),
but procd is compiled without seccomp support, the service should be
started normally, because seccomp-trace and utrace are not available.

Older procd versions decided about whether to start a service in
seccomp sandbox or not based on existence of seccomp whitelist in the
filesystem. This was recently removed (c8faedc "Do not disable seccomp
when configuration is not found", 2017-09-12) because it could be easy
for attackers to disable seccomp support. This changes is a follow-up
to the mentioned commit. With it, procd decides about whether to use
seccomp sandbox based only on compile-time configuration.

Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
Tested-by: Hans Dedecker <dedeckeh@gmail.com>
CMakeLists.txt
service/instance.c