[Dovecot] deliver and root user
On RHEL5, dovecot 1.0.7, I have set up sendmail to use `deliver` for my local mda. It keeps giving me this error for the root user though: Jul 12 12:51:29 mail sendmail[4105]: o699225f001348: to=r...@localhost.localdomain, ctladdr=r...@localhost.localdomain (0/0), delay=3+08:49:26, xdelay=00:00:00, mailer=local, pri=7502879, dsn=4.0.0, stat=Deferred: local mailer (/usr/libexec/dovecot/deliver) exited with EX_TEMPFAIL I've tried to `chmod +s /usr/libexec/dovecot/deliver`, which I read might fix some of those issues, but it didn't. Anyways, here are the important changes I made in my config files for using `deliver`: == sendmail.mc == ... dnl ## Should I modify this?? define(`PROCMAIL_MAILER_PATH', `/usr/bin/procmail')dnl ... dnl ## Should I have localhost.localdomain here? It currently is not. LOCAL_DOMAIN(`mydomain.com') ... FEATURE(`local_procmail', `/usr/libexec/dovecot/deliver',`/usr/libexec/dovecot/deliver -d $u') MODIFY_MAILER_FLAGS(`LOCAL', `-f') ... MAILER(smtp) MAILER(procmail) MAILER(local) == END == == dovecot.conf == ... protocol lda { postmaster_address = postmas...@mydomain.com hostname = mydomain.com } == END == Any ideas, or do you need more information? -- Thanks, Brad Landis
Re: [Dovecot] deliver and root user
On Mon, Jul 12, 2010 at 1:56 PM, Bradlee Landis bradleelan...@gmail.com wrote: On RHEL5, dovecot 1.0.7, I have set up sendmail to use `deliver` for my local mda. It keeps giving me this error for the root user though: Jul 12 12:51:29 mail sendmail[4105]: o699225f001348: to=r...@localhost.localdomain, ctladdr=r...@localhost.localdomain (0/0), delay=3+08:49:26, xdelay=00:00:00, mailer=local, pri=7502879, dsn=4.0.0, stat=Deferred: local mailer (/usr/libexec/dovecot/deliver) exited with EX_TEMPFAIL I've tried to `chmod +s /usr/libexec/dovecot/deliver`, which I read might fix some of those issues, but it didn't. Anyways, here are the important changes I made in my config files for using `deliver`: == sendmail.mc == ... dnl ## Should I modify this?? define(`PROCMAIL_MAILER_PATH', `/usr/bin/procmail')dnl ... dnl ## Should I have localhost.localdomain here? It currently is not. LOCAL_DOMAIN(`mydomain.com') ... FEATURE(`local_procmail', `/usr/libexec/dovecot/deliver',`/usr/libexec/dovecot/deliver -d $u') MODIFY_MAILER_FLAGS(`LOCAL', `-f') ... MAILER(smtp) MAILER(procmail) MAILER(local) == END == == dovecot.conf == ... protocol lda { postmaster_address = postmas...@mydomain.com hostname = mydomain.com } == END == Oh, I guess I should include this: Jul 12 13:53:52 mail deliver(root): userdb(root) returned 0 as uid Jul 12 13:53:52 mail deliver(root): userdb(root) returned 0 as gid Jul 12 13:53:52 mail deliver(root): userdb(root) didn't return uid And we have the logging turned up, so here is more information: Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 0: fl=0x0, mode=20666: CHR: dev=0/17, ino=1637, nlink=1, u/gid=0/0, size=0 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 1: fl=0x1, mode=20666: CHR: dev=0/17, ino=1637, nlink=1, u/gid=0/0, size=0 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 2: fl=0x1, mode=20666: CHR: dev=0/17, ino=1637, nlink=1, u/gid=0/0, size=0 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 3: fl=0x2, mode=140777: SOCK localhost-[[UNIX: /dev/log]] Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 4: fl=0x2, mode=100600: dev=8/1, ino=1633942, nlink=1, u/gid=0/51, size=1075 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 5: fl=0x0, mode=100600: dev=8/1, ino=1634639, nlink=1, u/gid=0/51, size=720 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 6: fl=0x8000, mode=100640: dev=8/1, ino=1569144, nlink=1, u/gid=0/0, size=12288 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 7: fl=0x8000, mode=100640: dev=8/1, ino=1569144, nlink=1, u/gid=0/0, size=12288 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 8: fl=0x8000, mode=100640: dev=8/1, ino=1569143, nlink=1, u/gid=0/51, size=12288 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 9: fl=0x8000, mode=100640: dev=8/1, ino=1569143, nlink=1, u/gid=0/51, size=12288 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 11: fl=0x1, mode=10600: FIFO: dev=0/6, ino=17279, nlink=1, u/gid=0/51, size=0 Jul 12 13:53:52 mail sendmail[4710]: o699mBRP001608: 12: fl=0x0, mode=10600: FIFO: dev=0/6, ino=17280, nlink=1, u/gid=0/51, size=0 -- Thanks, Brad Landis
Re: [Dovecot] deliver and root user
On Mon, 2010-07-12 at 13:56 -0500, Bradlee Landis wrote: On RHEL5, dovecot 1.0.7, I have set up sendmail to use `deliver` for my local mda. It keeps giving me this error for the root user though: Don't deliver mails to root. Forward them to some other user.
Re: [Dovecot] deliver and root user
Mandag 12. juli 2010 20.56.52 skrev Bradlee Landis : On RHEL5, dovecot 1.0.7, I have set up sendmail to use `deliver` for my local mda. It keeps giving me this error for the root user though: Jul 12 12:51:29 mail sendmail[4105]: o699225f001348: to=r...@localhost.localdomain, ctladdr=r...@localhost.localdomain (0/0), delay=3+08:49:26, xdelay=00:00:00, mailer=local, pri=7502879, dsn=4.0.0, stat=Deferred: local mailer (/usr/libexec/dovecot/deliver) exited with EX_TEMPFAIL I've tried to `chmod +s /usr/libexec/dovecot/deliver`, which I read might fix some of those issues, but it didn't. Anyways, here are the important changes I made in my config files for using `deliver`: == sendmail.mc == ... dnl ## Should I modify this?? define(`PROCMAIL_MAILER_PATH', `/usr/bin/procmail')dnl ... dnl ## Should I have localhost.localdomain here? It currently is not. LOCAL_DOMAIN(`mydomain.com') ... FEATURE(`local_procmail', `/usr/libexec/dovecot/deliver',`/usr/libexec/dovecot/deliver -d $u') MODIFY_MAILER_FLAGS(`LOCAL', `-f') ... MAILER(smtp) MAILER(procmail) MAILER(local) == END == == dovecot.conf == ... protocol lda { postmaster_address = postmas...@mydomain.com hostname = mydomain.com } == END == Any ideas, or do you need more information? Hi, Just a thought, but do you really want mail for root to be handled directly? You can alias it in /etc/aliases or similar like this; root: bradleelan...@gmail.com Then run the command newaliases to update alias table. I've not used sendmail for years, but that's how I'd do it for postfix. Regards, Arne -- Arne K. Haaje | www.drlinux.no T: 69 51 15 52 | M: 92 88 44 66
Re: [Dovecot] deliver and root user
Timo Sirainen t...@iki.fi wrote: On Mon, 2010-07-12 at 13:56 -0500, Bradlee Landis wrote: On RHEL5, dovecot 1.0.7, I have set up sendmail to use `deliver` for my local mda. It keeps giving me this error for the root user though: Don't deliver mails to root. Forward them to some other user. Standard recommendation (for sendmail and other MTA) is to create alias for root. Sendmail procedure: In /etc/mail/asises files add: root: some-non-privileged-user and run newaliases command to recompile aliases file. -- [plen: Andrew] Andrzej Adam Filip : a...@onet.eu I'm not afraid of dying, I just don't want to be there when it happens. -- Woody Allen
Re: [Dovecot] deliver and root user
On Mon, Jul 12, 2010 at 2:39 PM, Andrzej Adam Filip a...@onet.eu wrote: Timo Sirainen t...@iki.fi wrote: On Mon, 2010-07-12 at 13:56 -0500, Bradlee Landis wrote: On RHEL5, dovecot 1.0.7, I have set up sendmail to use `deliver` for my local mda. It keeps giving me this error for the root user though: Don't deliver mails to root. Forward them to some other user. Standard recommendation (for sendmail and other MTA) is to create alias for root. Sendmail procedure: In /etc/mail/asises files add: root: some-non-privileged-user and run newaliases command to recompile aliases file. Hm, ok, but it worked with procmail. Since we never used to check it anyways, I might just send it to /dev/null :) (P.S. Sorry arnaj for sending you the email to you directly before... they should fix the mailing list to do this automatically IMO.) -- Thanks, Brad Landis
[Dovecot] deliver to root
Hi, we use dovecot 1.1.11 on a RH Server with sendmail. Local delivery is done with deliver: Mlocal, P=/usr/local/libexec/dovecot/deliver, F=lsDFMAw5:/|@qSPfhn9, S=EnvFromL/HdrFromL, R=EnvToL/HdrToL, T=DNS/RFC822/X-Unix, A=deliver -d $u This setup works without issues for us, but mail to root has a problem with deliver: deliver(root): Mar 04 16:31:31 Error: userdb(root) returned 0 as uid deliver(root): Mar 04 16:31:31 Error: userdb(root) returned 0 as gid deliver(root): Mar 04 16:31:31 Error: User root is missing UID (set mail_uid) Is it generally not possible to use deliver to deliver mail to root? Thanks Philipp
Re: [Dovecot] deliver to root
* Philipp Kolmann kolm...@zid.tuwien.ac.at [2009-03-04 17:02]: This setup works without issues for us, but mail to root has a problem with deliver: Not an answer to your exact question, but usually, it's recommended to forward mail for root to another user, for instance in /etc/aliases. -- Vegard Svanberg veg...@svanberg.no [*tak...@irc (EFnet)]
Re: [Dovecot] deliver to root
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wed, 4 Mar 2009, Philipp Kolmann wrote: deliver(root): Mar 04 16:31:31 Error: userdb(root) returned 0 as uid deliver(root): Mar 04 16:31:31 Error: userdb(root) returned 0 as gid deliver(root): Mar 04 16:31:31 Error: User root is missing UID (set mail_uid) This is part of my dovecot.conf: # Valid UID range for users, defaults to 500 and above. This is mostly # to make sure that users can't log in as daemons or other system users. # Note that denying root logins is hardcoded to dovecot binary and can't # be done even if first_valid_uid is set to 0. #first_valid_uid = 500 #last_valid_uid = 0 Bye, - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.6 (GNU/Linux) iQEVAwUBSa9213WSIuGy1ktrAQKdZAf+L9hjgQ7PlcOw7nK8B1BZ2EqbaU/enze3 4FHDoMIHACnPO53lseICfANDG9VW4JonS4dr0b9TYVl7gkfMvsFX3MShRBZaxEyZ MWYjDzZL0o9kim3/B9oqcvWMMC2tl0B6JtLx8aoK4TFNgWtLHgEEHdzA8/1oDVPj nkerWRkRC4VeMZli6jBLaqNU4gqH9t5Cc+8s9NZ3mJ73csJG1TcQbaS98zyWwGLc OEjpPlM7h5LD9jsB6pLNYRQroRu0duNs8PuSMCNBoBnJX1Jboa6HUB6wfAFK/DSd Z2hCMjhe8ktKWBdYMbwuNL2HdY1xa4dstyQ0X+lhs07sdaXdk2xOhA== =bpfk -END PGP SIGNATURE-
Re: [Dovecot] deliver to root
Steffen Kaiser skdove...@smail.inf.fh-brs.de wrote: On Wed, 4 Mar 2009, Philipp Kolmann wrote: deliver(root): Mar 04 16:31:31 Error: userdb(root) returned 0 as uid deliver(root): Mar 04 16:31:31 Error: userdb(root) returned 0 as gid deliver(root): Mar 04 16:31:31 Error: User root is missing UID (set mail_uid) This is part of my dovecot.conf: # Valid UID range for users, defaults to 500 and above. This is mostly # to make sure that users can't log in as daemons or other system users. # Note that denying root logins is hardcoded to dovecot binary and can't # be done even if first_valid_uid is set to 0. #first_valid_uid = 500 #last_valid_uid = 0 Bye, Anyway, standard security practise is to define alias (in aliases file) to redirect deliveries to normal user. -- [plen: Andrew] Andrzej Adam Filip : a...@onet.eu I have five dollars for each of you. -- Bernhard Goetz