Re: [Exim] exim logging to stderr and not logfiles when run …

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Philip Hazel
Datum:  
To: Enrico Zini
CC: exim-users
Betreff: Re: [Exim] exim logging to stderr and not logfiles when run with -C
On Mon, 17 Dec 2001, Enrico Zini wrote:

> It is correct that EXIM_UID build in the binary is different to the
> exim_user set in the config file, but I don't need root privileges with
> the secondary configuration,


The problem is that, with EXIM_UID different to exim_user, there is
confusion when Exim is starting up as to which is *the* Exim uid. What
happens is that, when -C/-D is used, Exim drops its privilege before
reading the run time configuration, because it must do that when the
caller is not root or the Exim uid - and because it hasn't read the
configuration, it is checking EXIM_UID as the Exim uid. Then it reads
the configuration and discovers that a different exim_user is set, which
means that the previous test might have been wrong - hence the message.

> Anyway, if there's no way to tell it that the current situation is fine,
> I'm recompiling it with the other settings and installing just the
> "exim" new binary as /usr/sbin/exim_bulk. I don't really like this
> setup, since the secondary exim will have to be upgraded manually from
> now on and will not be taken care of by the Debian package management
> system, but if it's the only clean way... :(


There is another way. Create a very small program that just execs Exim,
passing on all the arguments it is given. Make this program setuid to
some unprivileged account (i.e. not either of the Exim uids, and not
root). Then call this program instead of Exim. This will ensure that
when Exim is called with -C/-D, it is called by a user that Exim knows
for sure is not the Exim user (because it is neither EXIM_UID nor
exim_user). So it will be happy about dropping its privilege and not
complain.

--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.