Re: [Dovecot] Problem with Dovecot LDA / Postfix
Thanks.
The log is really useful ;-)
deliver(info@lda.net4all.ch): Fatal: Running as root isn't permitted
So it's not possible acutally to use LDA to deliver mail with different UID/GID
So I need the change all the owner for my mail storage ... update the DB and restart the service ... it's bad !!! I need a lots of downtime to change the owner of 80Go data storage.
So beafore that, I need to test the dovecot-sieve plugin from CVS. Next month a lot of my customer are in holiday and the need auto responders ;-)
I try the dovecot-sieve plugin from the CVS and I have this error when i start make (configure as no error):
libsieve.a(script.o)(.text+0xa23): In function sieve_script_load': /usr/src/dovecot-sieve/src/libsieve/script.c:435: undefined reference to
map_refresh'
libsieve.a(script.o)(.text+0xaf0): In function sieve_script_unload': /usr/src/dovecot-sieve/src/libsieve/script.c:462: undefined reference to
map_free'
libsieve.a(sieve.o)(.text+0x1e6e): In function verify_flag': /usr/src/dovecot-sieve/src/libsieve/sieve.y:951: undefined reference to
imparse_isatom'
collect2: ld returned 1 exit status
make[3]: *** [sievec] Erreur 1
make[3]: Leaving directory /usr/src/dovecot-sieve/src/libsieve' make[2]: *** [all-recursive] Erreur 1 make[2]: Leaving directory
/usr/src/dovecot-sieve/src'
make[1]: *** [all-recursive] Erreur 1
make[1]: Leaving directory `/usr/src/dovecot-sieve'
make: *** [all-recursive-am] Erreur 2
I have the same error last week when I try to build dovecot-lda with sieve script support from the CVS.
I use Debian Sarge. I think the macro imparse_isatom is from the cyrus-imapd project. I try to install cyrus-dec and cyrus21-dev with apt-get ... but always the same error.
Do you have a idea ?
Le vendredi 16 juin 2006 à 10:44 -0400, My BSD a écrit :
-- Dominique Feyer Administrateur Système Ch. de la Colline 5bis CH-1007 Lausanne dfeyer@net4all.ch
On Fri, 2006-06-16 at 16:57 +0200, Dominique Feyer wrote:
Unless your mails are owned by root user, that's not really the problem. Rather it looks like your userdb query returns user's UID as 0. I guess I'll have to add some extra code to give nicer error message in that case.
Timo Sirainen wrote:
Nope, here's the output after an upgrade to beta9: Jun 18 15:18:23 [dovecot] auth(default): master out: USER_1_postmaster@obfusc8.org_uid=10006_gid=10001_home=/users/obfusc8.org/postmaster Jun 18 15:18:23 [dovecot] auth(default): Jun 18 15:18:23 [deliver(postmaster@obfusc8.org)] uid: (null), gid: 10001, chroot: (null) Jun 18 15:18:23 [deliver(postmaster@obfusc8.org)] Running as root isn't permitted The attached patch solves the problem --- src/deliver/auth-client.c.orig 2006-06-11 21:37:10.000000000 +1000 +++ src/deliver/auth-client.c 2006-06-18 15:24:19.000000000 +1000 @@ -49,7 +49,9 @@ for (tmp = t_strsplit(args, "\t"); *tmp != NULL; tmp++) { if (strncmp(*tmp, "uid=", 4) == 0) { - if (conn->euid != strtoul(*tmp + 3, NULL, 10)) { + uid_t uid = strtoul(*tmp + 4, NULL, 10); + + if (conn->euid == 0 || geteuid() != uid) { env_put(t_strconcat("RESTRICT_SETUID=", *tmp + 4, NULL)); }
userdb query return correct UID/GID, I test this before. The log show the correct UID/GID.
I have "Fatal: Running as root isn't permitted" only if I had setuid bit to deliver.
I use pgsql for userdb
Le vendredi 16 juin 2006 à 21:17 +0300, Timo Sirainen a écrit :
-- Dominique Feyer Administrateur Système Ch. de la Colline 5bis CH-1007 Lausanne dfeyer@net4all.ch
participants (3)
-
Dominique Feyer
-
Peter Fern
-
Timo Sirainen