Hi,

For several years I had the combination Postix-Courier-CyrusSASL
working without any problem.

This week I've upgraded my Ubuntu 10.04 (courier-imap 4.6.0) to 12.04
(courier-imap 4.9.1).

After the upgrade I can't get IMAP to work anymore and I ran out of
suggestions to find the cause of it. Both IMAP and IMAP-SSL don't work.
But POP and POP-SSL _do_ work. Postfix does work, and the Postfix/Cyrus-SASL
combination works too. Everything but IMAP works.

In the log below you can see that IMAP authentication works (also via 
SSL), but
nothing further. For some reason the connection gets closed.

Here is what I did to analyse the problem.
* enabled DEBUG=1 in /etc/courier/authdaemonrc
* use telnet to connect to 143, use openssl to connect to 993

A brief portion of the log to show what I did (with some editing to hide 
real names)

$ telnet myserver imap
Trying a1.b1.c1.d1...
Connected to myserver.
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 UIDPLUS CHILDREN NAMESPACE 
THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE ACL ACL2=UNION 
STARTTLS] Courier-IMAP ready. Copyright 1998-2011 Double Precision, 
Inc.  See COPYING for distribution information.
0 login user password
0 NO Login failed.
0 login i...@mydomain.nl "mypass"
Connection closed by foreign host.

/var/log/mail.log
Sep 10 22:55:14 myserver imapd: Connection, ip=[::ffff:a2.b2.c2.d2]
Sep 10 22:55:19 myserver authdaemond: received auth request, 
service=imap, authtype=login
Sep 10 22:55:19 myserver authdaemond: authmysql: trying this module
Sep 10 22:55:19 myserver authdaemond: SQL query: SELECT email, password, 
"", 114, 118, "/var/mail/vhosts", 
CONCAT(SUBSTRING_INDEX(email,'@',-1),'/',SUBSTRING_INDEX(email,'@',1),'/'), 
"", "", "" FROM users WHERE email = 'user'
Sep 10 22:55:19 myserver authdaemond: zero rows returned
Sep 10 22:55:19 myserver authdaemond: no password available to compare
Sep 10 22:55:19 myserver authdaemond: authmysql: REJECT - try next module
Sep 10 22:55:19 myserver authdaemond: FAIL, all modules rejected
Sep 10 22:55:19 myserver imapd: LOGIN FAILED, user=user, 
ip=[::ffff:a2.b2.c2.d2]
Sep 10 22:55:27 myserver authdaemond: received auth request, 
service=imap, authtype=login
Sep 10 22:55:27 myserver authdaemond: authmysql: trying this module
Sep 10 22:55:27 myserver authdaemond: SQL query: SELECT email, password, 
"", 114, 118, "/var/mail/vhosts", 
CONCAT(SUBSTRING_INDEX(email,'@',-1),'/',SUBSTRING_INDEX(email,'@',1),'/'), 
"", "", "" FROM users WHERE email = 'i...@mydomain.nl'
Sep 10 22:55:27 myserver authdaemond: password matches successfully
Sep 10 22:55:27 myserver authdaemond: authmysql: sysusername=<null>, 
sysuserid=114, sysgroupid=118, homedir=/var/mail/vhosts, 
address=i...@mydomain.nl, fullname=<null>, maildir=mydomain.nl/info/, 
quota=<null>, options=<null>
Sep 10 22:55:27 myserver authdaemond: Authenticated: sysusername=<null>, 
sysuserid=114, sysgroupid=118, homedir=/var/mail/vhosts, 
address=i...@mydomain.nl, fullname=<null>, maildir=mydomain.nl/info/, 
quota=<null>, options=<null>

In other words, first I tried a non-existing user. The server replies 
promptly (well, maybe 2 seconds delay)
with "NO Login failed." (see also mail.log above)
Then I tried a valid user and a valid password. There is no reply, it 
takes several seconds
and then the connection dies. Nothing is written in the logs.

Can anyone suggest how to debug / analyse this problem?
TIA
-- Kees

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
Courier-imap mailing list
Courier-imap@lists.sourceforge.net
Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-imap

Reply via email to