wernervdm at topbilling.com
2006-Jul-04 21:29 UTC
[Dovecot] Dovecot authentication issue with postgresql
Good day, I am having trouble getting dovecot to authenticate using postgresql. For some reason, it fails on a PAM error, although I have specified pgsql as authentication? Here my setups: dovecot.conf: -- snip-- (not sure if you need teh rest) auth = digest_md5 auth_mechanisms = plain digest-md5 auth_userdb = pgsql /etc/dovecot-pgsql.conf auth_passdb = pgsql /etc/dovecot-pgsql.conf auth_user = root dovecot-pgsql.conf: connect = host=localhost dbname=postfix user=postfix password=postfix default_pass_scheme = MD5 password_query = SELECT password FROM mailbox WHERE username = '%u' user_query = SELECT '/var/spool/vmail/'||maildir AS home, uid, gid FROM mailbox WHERE username = '%u' I get an authentication error trying to log in. It queries the database for the password, but it does not seem to query for user? Logs: dovecot: dovecot-auth: Jul 05 05:14:41 Info: PAM: pam_authenticate(chrisj at topbilling.com) failed: Authentication failure messages: Jul 5 05:14:39 tophat dovecot(pam_unix)[2928]: check pass; user unknown Jul 5 05:14:39 tophat dovecot(pam_unix)[2928]: authentication failure; logname= uid=0 euid=0 tty= ruser= rhost Any help will be greatly appreciated - the passwords are created using postfixadmin - I presume it is in MD5 format. Kind regards Werner
Timo Sirainen
2006-Jul-04 21:38 UTC
[Dovecot] Dovecot authentication issue with postgresql
On Jul 5, 2006, at 12:29 AM, wernervdm at topbilling.com wrote:> Good day, > > I am having trouble getting dovecot to authenticate using postgresql. > For some reason, it fails on a PAM error, although I have specified > pgsql > as authentication?....> auth_userdb = pgsql /etc/dovecot-pgsql.conf > auth_passdb = pgsql /etc/dovecot-pgsql.confDovecot doesn't try to use PAM unless you have it configured in config file, so either you have auth_passdb = pam elsewhere in the file, or you're modifying the wrong file. In any case, I'd suggest you don't even try to use Dovecot 0.99.x versions. They're ancient and unsupported in case of problems. -------------- next part -------------- A non-text attachment was scrubbed... Name: PGP.sig Type: application/pgp-signature Size: 186 bytes Desc: This is a digitally signed message part URL: <http://dovecot.org/pipermail/dovecot/attachments/20060705/3e89841c/attachment.bin>