Hi, On Wed, Aug 26, 2009 at 04:45:39PM +0200, Carl Fredrik Hammar wrote:
> + err = EACCES; > + euid = geteuid (); > + for (i = 0; i < euids_len; i++) > + if (euids[i] == euid || euids[i] == 0) > + err = 0; This is not sufficient: privileges of the module are not escalated only if the sender has access to *all* our user IDs, not just the current one. Also, there is no point going on with the loop once you found what you are looking for :-) BTW, I wonder whether it's necessary to special-case root on the receiver's side: in theory, a sender having root privileges can fabricate any IDs the receiver wants to see. Not sure whether this approach is preferable though: it is more flexible -- but also requires a more complicated protocol, and I think it's less consistent with the root handling in other parts of the Hurd... -antrik-