Re: Are capabilities worthwhile?



On Wed, 27 Sep 2006 06:42:00 +0000, Bob Smith wrote:

My approach has been to have the daemons started
in rc.sysinit drop capabilities as part of their
other steps to become a daemon, and to then have
the bottom of rc.sysinit drop capabilities for
the kernel by setting /proc/sys/kernel/cap-bound.

My hope had been that once the appliance was
fully booted, it would be a little more secure
from network attacks.

It should be. However to which extend will greatly depend on what
privileges are kept ( for instance in case of 'bind to a lo-port'
successful attacks might gain the ability to spoof a login service, such
as telnet or ssh ... ).

Another aproch might be for fork, drop to a restricted account in one
process and comunicate over some rpc means, such as a socketpair with a
(the) still privileged process (which ofcource may well be able to drop
some stuff too. I think to remenber 'vsftpd' does this).

In case its (commented) code you want to look at, named might help:
http://stuff.mit.edu/afs/dev/source/src-current/third/bind/bin/named/unix/os.c

-Menno.

.



Relevant Pages

  • [PATCH 1/1] capabilities: oom_kill: dont set PF_SUPERPRIV for oom check
    ... Subject: [PATCH 1/1] capabilities: oom_kill: don't set PF_SUPERPRIV for oom check ... With 64-bit capabilities came an inadvertent change such ... that the check for a privileged process, ...
    (Linux-Kernel)
  • Re: what are: universal auto code generators?
    ... or by indicating that they are willing to learn. ... >don't have those capabilities but they're willing to consider you ... the bottom line is - I think I did well on the interview - now I just ...
    (comp.arch.embedded)
  • Re: For Christine Dabney...
    ... Damsel in dis Dress wrote: ... "I am an agnostic only to the extent that I am agnostic about fairies at the bottom of the garden." ...
    (rec.food.cooking)
  • Re: RBR - expletives!
    ... > Well here's what they say in their audio.ini file at the bottom. ... > reason why it's not doable. ... Doable, perhaps, but beyond my capabilities... ... Prev by Date: ...
    (rec.autos.simulators)