Fwd: Re: [DSE-User] selinux and /sbin/init INIT_PROG feature

Erich Schubert erich at debian.org
Thu Jan 12 23:55:39 UTC 2006


Hello Thomas,
I like the postfix restriction. A potential pitfall I see is that the
re-execed init might change its name, or the user might have booted with
init=/sbin/init.other right away - is the postfixed name then
init.other.foo or init.foo? But I guess you could hardcode /sbin/init...

The regular selinux mailinglist might be better for this kind of
question btw. - it's not really debian specific, but should be handled
the same cross-distribution. Maybe even "cross init", since there are
other inits around.
Minit for example has the ability to re-exec itself, too; and also a way
of handing over the status to the new instance (minit does a much more
extensive status monitoring than init, it has some dependency handling
and can respawn "dynamic" services, too. (which is a pain with the
current init, and my biggest issue with it...)

A complete init rewrite might actually offer other benefits for SELinux
users.
For example with minit, you'll never start a service using
some /etc/init.d/foo init script; but there is a fifo to talk to the
init daemon, and you can (usually using the msvc tool) tell init to
spawn a new service.
That way, the spawned service will not have any filedescriptors or
whatever from the starting shell open, and the access to the fifo can be
controlled very easily using both traditional unix permissions and
SELinux labels.

best regards,
Erich Schubert
-- 
     erich@(vitavonni.de|debian.org)    --    GPG Key ID: 4B3A135C    (o_
  There is no branch of mathematics, however abstract, which may not  //\
 some day be applied to phenomena of the real world. --- Lobatchevsky V_/_
     Die eigentliche Aufgabe eines Freundes ist, dir beizustehen,
     wenn du im Unrecht bist. Jedermann ist auf deiner Seite, wenn
                   du im Recht bist. --- Mark Twain




More information about the Selinux-user mailing list