Tuesday, November 3, 2009

Can't Connect to Cyrus Sieve

So I’m trying to use sieveshell on a cyrus imap server. It just tells me it can’t connect. The logs are very not helpful:




Nov 3 19:39:50 li9-96 cyrus/master[2167]: about to exec /usr/lib/cyrus/bin/timsieved
Nov 3 19:39:50 li9-96 cyrus/sieve[2167]: executed
Nov 3 19:39:50 li9-96 cyrus/sieve[2167]: accepted connection
Nov 3 19:39:54 li9-96 cyrus/master[2160]: process 2167 exited, status 0


I try to telnet and it works:




jason@renfield:/etc$ nc localhost 2000
"IMPLEMENTATION" "Cyrus timsieved v2.2.13-Debian-2.2.13-14+lenny3"
"SIEVE" "fileinto reject envelope vacation imapflags notify subaddress relational comparator-i;ascii-numeric regex"
"STARTTLS"
OK
LOGOUT
OK "Logout Complete"


A lot of looking and I find this: http://linux.derkeiler.com/Mailing-Lists/Debian/2004-02/3871.html but I’m already set to PLAIN. In fact my configs, versions, and OS are exactly the same on this system as on another system where sieve is working fine.



Eventually I notice this connecting to my working box:




jason@hatchery:/etc$ nc localhost 2000
"IMPLEMENTATION" "Cyrus timsieved v2.2.13-Debian-2.2.13-14+lenny3"
"SASL" "NTLM LOGIN PLAIN DIGEST-MD5 CRAM-MD5"
"SIEVE" "fileinto reject envelope vacation imapflags notify subaddress relational comparator-i;ascii-numeric regex"
"STARTTLS"
OK
LOGOUT
OK "Logout Complete"


There’s an extra line in there, beginning with “SASL”. The other guy had a SASL problem. I had already check to make sure I have the same cyrus packages but I didn’t check sasl packages. I finally find that I’m missing libsasl2-modules. Install that, restart cyrus and saslauthd (probably didn’t need to restart both), and everything works.



It would have been nice if sieveshell said, “I can’t connect because there’s no SASL mechanisms”.

No comments:

Post a Comment