the lack of a stacking ability was deliberate (go back and read the
archives). basicly no LSM was willing to admit that they weren't the
be-all, end-all of security, so nobody was willing to consider that anyone
would ever want anything else.
one method of doing the stacking would be for the LSM to not know about
the stacking, but the kernel takes care of passing all requests through
each LSM in order (if the LSMs can be staticly compiled the order should
be able to be changed at compile time)
now, the existing policies for some LSM's may need to change, becouse
they've been assuming that they only needed to check capabilities for
UID=0, when they will now need to check them for everyone, but arguably,
this was a bug masquerading as an optimization in the first place.
which LSM gets to declare the standards?
only if the stacking mode permits this. if it always requires passing
through all the layers then this wouldn't be a problem.
Besides which, the MultiAdmin authors would probably be willing to make
the nessasary changes to their LSM to play nicely with others anyway (but
good programming practice would dictate that you don't count on it, and
arrange for the other modules to approve as well)
as things are currently written, it's not possible to stack, so there is
no order. change how things are written and you can make them safe.
the sysadmins need to be given enough rope, you don't know everything that
they are trying to do, and you don't know what other LSMs going to do. so
how can you possibly decide ahead of time what orders are safe?
no, LSM is not just for testing, LSM is an interface so that Linus doesn't
need to pick the 'one true security model' and enforce it on everyone.
it's like freedom of religion, each religion belives that they are the one
true path, but in exchange for the guarentee that they are not going to be
percecuted, they reluctantly allow all other religions equal freedom. when
religion passes from mearly strange to activly harmful (i.e. cults) you
find the edge of the freedom.
similarly, LSMs need to accept the fact that some people don't want their
flavor of security, so to avoid being thrown out entirely they need to
allow other LSMs to exist, and use the same kernel hooks, even if they
believe that the alturnatives are misguided. as long as an LSM is not
activly harmful (as opposed to mearly being snake oil) it should be
allowed.
which bits into which security features? Good, knowledgable people can't
agree on what's right.
ending the bitrot just requires accepting the LSMs into the kernel as
first-class options, it doesn't require declaring any one LSM (or even any
part of any one LSM) as being the 'one right way' to do something and
force everyone to use that way.
David Lang
-