diff --git a/init/init.c b/init/init.c index 864fc6c85..365726c91 100644 --- a/init/init.c +++ b/init/init.c @@ -221,6 +221,9 @@ void service_start(struct service *svc, const char *dynamic_args) } rc = security_compute_create(mycon, fcon, string_to_security_class("process"), &scon); + if (rc == 0 && !strcmp(scon, mycon)) { + ERROR("Warning! Service %s needs a SELinux domain defined; please fix!\n", svc->name); + } freecon(mycon); freecon(fcon); if (rc < 0) {