NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Reverse of promoting to root: downgrade root to unprivileged



Starting some operation as common user (for example compiling/building)
before promoting to privileged (generally root) by su'ing or sudo'ing
(for example to install) is common.

But does somebody know of an established program or library that allows
to start a process as root and to automatically downgrade rights for
tasks (I mean identified chunks of whatever code) that do not require
privileges?

This can of course be written in scripting, by su'ing to
a defined unprivileged user to exec a task and wait for it before
using the result with root privileges, but I wonder if there is prior
art in this area?---or perhaps simply if root is identified but for
a task that doesn't need privileged, the program is re-exec'ed with
downgraded rights?
-- 
        Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
                     http://www.kergis.com/
                    http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C


Home | Main Index | Thread Index | Old Index